Time Nick Message 00:50 joeDoe I'm trying to set up a minetest server to offer the tutorial instead of the minetest_game. When I join the server, though, it's not the same world as when I've played the tutorial locally. I'm not sure, but I think it's the world from the minetest_game. Anyone know why I'm not getting the right world? Where do I start to look? 01:11 MTDiscord The tutorial explicitly says that it is designed to work only for single player. Technically it can start in multiplayer mode, but if you do that, it warns you when you first join that it will probably break if a second player joins. Are you sure you want to run a server given that? 01:13 MTDiscord I'm actually trying it out in multiplayer myself but haven't seen how it actually "breaks" yet... 01:14 MTDiscord It only works with the singlenode mapgen type, though, for one, so you should probably just start it in SP and then copy the world to your server to set it up in MP. 03:23 Yad sfan5: As you requested, my code is now on GitHub so it's not as difficult to debug https://github.com/OCRenkist/turbo-octo-chainsaw 03:23 Yad this was with regard to the question of vectors vs. tables 03:33 erlehmann Yad, https://github.com/OCRenkist/turbo-octo-chainsaw is 404 for me 03:38 Yad erlehmann: I've sent you an invitation now. Testing how private repos work on GitHub :) 03:38 erlehmann Yad why not make it public 03:39 Yad Avoiding being hasty I suppose. Because I can't undo that. 03:39 Yad Public repos are subject to webcrawlers, no? 03:40 Yad (And if I recall correctly, only the paid version of GitHub had private repos in the past.) 03:42 Yad Moreover it's just a very rudimentary learning exercise for me at this point, and I wouldn't want to clutter the information landscape with my crude beginnings. 03:42 Yad * erlehmann 03:42 MTDiscord Private repos are free and can be switched any time 03:43 Yad GreenXenith: Precisely! :D 03:43 MTDiscord My main point is you can undo it 03:44 Yad GreenXenith: Oh, nice. Assuming Archive.org doesn't grab it in the interim? 03:44 MTDiscord Of course 03:44 Yad GreenXenith: :D 03:44 erlehmann Yad i suggest to not name your main mod “main” 03:44 erlehmann way too common word 03:45 Yad erlehmann: Excellent suggestion. :) 03:45 Yad erlehmann: I would imagine I'll switch to a naming convention such as MineClone 2, or Loria, use, with game initials followed by an underscore followed by the mod name. 03:46 Yad erlehmann: At this point I'm just testing different functions in the Minetest Lua API 03:47 MTDiscord please dont use a games namespace 03:47 Yad Jonathon: Because it kills mod interoperability? 03:48 MTDiscord sort of 03:48 Yad erlehmann: and sfan5 requested I put the code for my vector.new(x,y,z) error on GitHub for easy reading instead of trying to explain it line-by-line in here xD 03:49 erlehmann yes good 03:49 Yad erlehmann: thanks :) 04:52 erlehmann Yad if you want truly private git repositories (where not even the server can see it) you can use GPG + git-remote-gcrypt 04:52 erlehmann https://github.com/spwhitton/git-remote-gcrypt 05:02 Yad erlehmann: Oh! Thank you, that might be very useful in the future. :) 05:02 erlehmann Yad i mainly use it for encrypted remote backups of config files 05:02 Yad erlehmann: Nice. 05:03 erlehmann Yad but you can basically use it to share a repo on a public host (only ppl in the GPG config of the others can access it) 05:03 Yad erlehmann: Indeed. Pre-egress encryption. 05:43 Norkle ut up 06:24 Yad Norkle: oh hi 06:28 Yad I'm trying to find help topics on using VSCodium with a GitHub `personal access token` 06:32 Yad Ah looks like I simply didn't authorize enough powers to be granted to the token. 06:33 Yad I'm not familiar with which ones are required, but I still managed to leave most disabled. 15:05 gargamel !up 69.247.56.186:30003 15:05 MinetestBot 69.247.56.186:30003 is up (125ms) 15:05 gargamel Fractal Monday now with dinosaurs! 19:43 Yad What text editors/IDEs do you prefer for interfacing with GitHub repos? 19:43 Yad I'd love to put more of my work into pull requests, but it's quite a chore with the web GUI. 19:50 Jordan4ibanez Github desktop 19:51 MTDiscord git 20:19 jonadab Emacs. 20:22 dzho https://xkcd.com/378/ 20:23 MTDiscord VS Code 20:53 rubenwardy !seen VanessaE 20:53 MinetestBot rubenwardy: vanessae was last seen at 2021-09-03 21:13:13 UTC on #minetest-hub 20:58 sfan5 thats a while 20:59 Krock 4 months 21:40 MTDiscord they are semi active in there irc channel on libera 21:41 Bombo hi 21:43 Bombo how do the settings work? i'm using draconis mod, there is settingtypes.txt with 'simple_spawning (Simple Spawning) bool true' in init.lua i added this: minetest.log("action", "[MOD] Draconis simple_spawning: " .. tostring(minetest.settings:get_bool("simple_spawning"))) at the end, but it is always 'nil' 21:44 rubenwardy settingtypes is for the All Settings menu, it doesn't set defaults 21:45 Bombo ok but how do i get those settings then? 21:45 Yad dzho: Heheheh 21:46 rubenwardy that's correct, you need to provide your own defaults 21:46 rubenwardy get_bool("simple_spawning", true) 21:46 Yad Thanks for the feedback on editors, everybody :) 21:46 Yad luatic: I'm relieved someone mentioned VS Code 21:46 Yad luatic: Because yesterday I discovered (and am enjoying) VSCodium. 21:47 Yad luatic: A fully open-source implementation of what VS Code is. 21:47 Yad https://flathub.org/apps/details/com.vscodium.codium 21:47 Bombo rubenwardy: so there is no way to get a setting from 'all settings' ? 21:47 MTDiscord I have Code: OSS installed 21:48 MTDiscord Still use VS Code tho ;) 21:48 rubenwardy Bombo: when they change using All settings, get_bool will return the changed setting 21:48 rubenwardy I use Code - OSS as well 21:48 rubenwardy it's what Chromium is to Chrome 21:49 Yad luatic: If you enjoy spyware :P 21:49 MTDiscord The truth is, I've fallen in love with the VSC icon 21:50 MTDiscord Granted, I could use it for COSS 21:50 rubenwardy Yad: Code is in Manjaro/Arch repos, but VSCodium isn't 21:51 MTDiscord you code add it to the aur if it isnt already 21:51 MTDiscord , s.code/could 21:51 sfan5 vscodium is a branded prebuild of code oss 21:51 sfan5 if you have the latter you don't need the former 21:51 sfan5 prebuilt* 21:51 benrob0329 Plus some propretary bits iirc, but nothing you need 21:52 rubenwardy codium is in the AUR, but I'd rather use a community package than an AUR one 21:54 Bombo rubenwardy: ah i got it. soooooooo... then .... 21:55 Bombo how to get an int, get_int doesn't seem to exist 21:56 rubenwardy get() and then tonumber 21:56 rubenwardy tonumber(minetest.settings:get("name")) or 123 21:57 Bombo works, even without tonumber, and with tostring ;) 21:58 rubenwardy you need tonumber to make it a number, and not a string 21:58 rubenwardy Lua does have some type cohesion but in this case it makes sense to validate here 21:59 Bombo i'm hacking with //lua minetest.chat_send_player("singleplayer", "simple_spawn_rate: " .. minetest.settings:get("simple_spawn_rate")) 21:59 Bombo just want to see if it's set 22:01 Bombo ok //lua minetest.settings:set("simple_spawn_rate", 11) did work too 22:01 Bombo now let's see if there are dragons 22:16 Bombo dragooooooon! 22:16 Bombo ;) 22:19 Yad rubenwardy: Yeah VSCodium is not in the Mint repos either, that's why I use Flatpak...besides considering Flatpax more secure generally. 22:21 Bombo rubenwardy: so i can't read defaults from settingtypes.txt / gui settings 22:22 Bombo hm when are settingtypes.txt values read anyway 22:22 Yad sfan5: Ohh, excellent, thank you. 22:23 rubenwardy Bombo: in the mainmenu only 22:23 Bombo i've set //lua minetest.settings:set("simple_spawn_rate", 1) now, in the console, then looked it up in gui menu all settings, it's 1 now 22:23 Bombo so the values in settingtypes.txt are ignored completely 22:24 Bombo hmm 22:55 gaelysam Hi I have a C++ question 22:56 gaelysam I'm getting the destructor of a class called during construction 22:56 Bombo # Dragon Spawn Rate. 1 in x chance per spawn tick for a Dragon to spawn. 22:56 Bombo what's a spawn tick? 22:57 gaelysam In my tests I've added an empty constructor for MapgenBasic and I don't understand why MapgenBasic::~MapgenBasic() is called when doing "MapgenBasic mg;" 22:58 Hawk777 gaelysam: Put more of your code somewhere for us to look at? 22:58 MTDiscord Are you, like, creating an instance on the stack and then immediately exiting the function or something? 23:00 gaelysam It's what I think, that some temporary object is created, duplicated and deleted, but I don't understand why this happen by just doing "MapgenBasic mg;" 23:01 gaelysam I can put my code on a github branch but it's not easy to show cuz my changes are in several files 23:03 MTDiscord github has a pretty good diff viewer, so that might actually work pretty well... 23:04 gaelysam (and github's new logging system is bothering me again...) 23:17 gaelysam https://github.com/Gael-de-Sailly/minetest/commit/128e84b#diff-be4624c7b000e30c1dfd7240605f7b0f6414b8da1b9cdaebef53922d765d8c42R1515 23:19 Hawk777 And you’re seeing mg_temp’s destructor being called somewhere before the “return 0” on L1535? 23:19 gaelysam yea 23:19 gaelysam even before L1519 23:20 gaelysam if I uncomment L1517-18, the error does not happen (as the destructor segfaults) 23:21 gaelysam (I mean this debug LuaError does not happen) 23:21 Hawk777 Ah, and you have the prints in the MapgenBasic ctor and dtor to verify that. 23:21 gaelysam yea both 23:23 Hawk777 Well, I’m not sure, but two things you could try for debugging purposes. (1) in your printed messages, print out “this”, which will print as the pointer value (memory address) of the object. (2) implement the copy constructor and add printing to it rather than using the default, so you can see if it is being called somewhere unexpected, and so you can more properly match up dtor calls to the corresponding ctor calls. 23:24 Hawk777 Oh, never mind (2); it looks like the class is uncopyable. 23:24 Hawk777 You could also put a breakpoint in the dtor and get a backtrace to see if you can figure out why exactly it’s happening. 23:25 Yad sfan5: So is `Code - OSS` the version without Microsoft telemetry stuff or is Codium? 23:27 MTDiscord Codium is pre-packaged Code - OSS 23:27 Hawk777 gaelysam: Oh, it also looks like the MapgenBasic nullary ctor doesn’t initialize the fields. Did you add that ctor? So for a local variable (as mg_temp is), m_emerge (for example) will be uninitialized and the dtor will invoke UB when it possibly deletes it. 23:27 Yad GreenXenith: Ah yes, but is there any disadvantage to using Codium? 23:27 MTDiscord Relative to what? 23:27 rubenwardy Yad: Code - OSS is the official upstream open source version maintained by Microsoft. It doesn't have the Microsoft branding or proprietary plugins. Not 100% sure about telemetry 23:27 rubenwardy VSCodium is a fork of Code - OSS 23:28 rubenwardy so Code is Chromium, VSCode is Chrome, VSCodium is Edge/Brave/whatever 23:28 MTDiscord >This is not a fork 23:28 Yad rubenwardy: Yes I noticed the pun in the names :D 23:28 MTDiscord (vscodium discord) 23:28 gaelysam Hawk777: ah yea I'll try this printing the pointer 23:28 MTDiscord bla 23:28 MTDiscord (vscodium github*) 23:28 MTDiscord tired brain, doing 3 things at once 23:29 GreenXenith Quick announcement, post-mortem for the 2021 Minetest Game Jam can be found here https://github.com/GreenXenith/minetestgamejam/blob/master/2021/POSTMORTEM.md Goes over what went well, what didn't, and future plans. 23:30 MTDiscord Anyway, VSCodium is just a build of code - oss with community configuration 23:31 MTDiscord All telemetry is disabled 23:39 gaelysam Hawk777: yes the ctor doesn't initialize fields and it's why it is segfaulting but it's not what i am fixing now: I expect the dtor to be called at the end of the function, not on construction 23:44 gaelysam and I confirm that the object being created and destructed is at the same memory address 23:45 Hawk777 Yep, I don’t have an explanation for that. 23:46 Hawk777 Everything I was thinking about involved either an exception being thrown earlier in the construction process (e.g. in the Mapgen ctor) in which case MapgenBasic’s ctor body would not have run yet; or as a side effect of doing something with mg_temp with it not initialized properly (but you say the dtor runs before you do anything with it). So I don’t know. 23:47 Hawk777 Hm, wait, you said you verified that the dtor ran too early by uncommenting lines 1517 and 1518. But if you uncomment those lines, then of course the dtor will run right away, because “throw” unwinds the stack and runs the dtor! 23:47 Hawk777 Did you try printing something on e.g. line 1516 to check for sure? 23:50 gaelysam ah I see what you mean 23:52 gaelysam I thought "throw" was aborting very brutally but maybe it still calls the dtors 23:53 Hawk777 If it’s caught anywhere, it definitely does. 23:53 Hawk777 If it’s not caught anywhere in the entire program, I’m not sure whether it’s still allowed but not required to per language standard, or required not to (I know in GCC’s case it doesn’t). 23:54 gaelysam it works now 23:54 gaelysam I mean, it segfaults at the end of the function as expected, so I just have to implement the ctor properly now 23:55 gaelysam thank you very much