Minetest logo

IRC log for #minetest, 2024-09-06

| Channels | #minetest index | Today | | Google Search | Plaintext

All times shown according to UTC.

Time Nick Message
00:18 SFENCE joined #minetest
00:18 liceDibrarian joined #minetest
00:20 cation joined #minetest
00:25 kamdard_ joined #minetest
00:33 ireallyhateirc joined #minetest
00:43 SFENCE joined #minetest
01:01 SFENCE joined #minetest
01:20 SFENCE joined #minetest
01:37 SFENCE joined #minetest
01:44 SFENCE joined #minetest
02:00 SFENCE_arch joined #minetest
02:13 fling joined #minetest
02:49 sparky4 joined #minetest
04:00 MTDiscord joined #minetest
04:33 fluxionary joined #minetest
04:46 untilted joined #minetest
04:51 untilted hi
04:52 MTDiscord joined #minetest
05:17 Trifton joined #minetest
05:45 Trifton joined #minetest
05:50 [MatrxMT] <Bram> Do I understand it correctly that `minetest.register_portable_metatable(name, mt)` allows me to port custom data to an async environment, or am I getting that wrong?
05:53 [MatrxMT] <Bram> And if that's not the case, then what is it good for?
06:13 MTDiscord <sfence> I think, this is not for data exactly. Just for objects. So if you transver vector, you cen still use it like a vector-> vec:vector_method()
06:23 gregon joined #minetest
06:45 lemonzest joined #minetest
06:46 hlqkj joined #minetest
07:18 sfan5 @Bram depends on what you mean by "custom data"
07:19 [MatrxMT] <Bram> I'd like to transfer a `registered_caves` type from the mod initialization to the mapgen environment, in a similar way to how `minetest.registered_nodes` is accessible in the mapgen environment.
07:21 [MatrxMT] <Bram> Hmmm. If I initialize variables in a mapgen script, then other mods with custom mapgen scripts can access those variables, right?
07:34 sfan5 yes
07:34 sfan5 register_portable_metatable does not transfer any data
07:34 sfan5 there are upcoming IPC functions for this
07:34 sfan5 currently the best option is to write a serialized form to a file in the world folder and read it back in the mapgen env
08:53 cheek_pain joined #minetest
08:54 jaca122 joined #minetest
09:00 hlqkj joined #minetest
09:11 untilted joined #minetest
09:13 gregon joined #minetest
09:19 TheCoffeMaker joined #minetest
09:48 ireallyhateirc joined #minetest
10:03 jaca122 joined #minetest
10:19 untilted Hello, I'm learning the lua api right now and I'm curious about the mapgen, reading the source code right now (script/lua_api/l_mapgen.h).
10:21 untilted I figured there is not much to set "dynamically" as the chunk generation runs, by reading the set_mapgen "cannot set after initialization" errors.
10:23 untilted So I see that the way to go modifying the mapgen is to use the register_mapgen_script, register_on_generated, etc. functions on the api.
10:24 untilted I was afraid it could be too slow but I saw some merges that put this feature on a new thread so i'll just try it.
10:27 untilted This is the part where I ask about the mapgens themselves, v7 is the one to use right? I read that this one has less "hard-coding" and on the github I saw paramat make this giant dungeon above the world, then he put it underground again by changing a variable in source-code.
10:29 ireallyhateirc custom mapgens can be implemented entirely with lua, the mapgen env (register_mapgen_script) lets you modify the voxel manip flat array just after it was generated by C++
10:31 ireallyhateirc depends what you mean by "the one to use". v7 is better than v6 if that's what you ask for, but there are other "good" mapgens like valleys, carpathian or flat
10:32 untilted Yeah I've checked valleys and it was interesting how it felt like an entire different game. v6 I'm curious why its at the very bottom of the mapgen list.
10:33 [MatrxMT] <Blockhead256> v6 doesn't act like the other generators do with its biome system, mods end up needing to write separate code for it
10:34 untilted ireallyhateirc: Does this mean that the mapgen env in lua gets this kind of binary data from v7 to work with before writing to map?
10:35 untilted I can't, for example, modify a perlin noise on v7 to make the terrain very spiky or ultra flat, etc.
10:36 ireallyhateirc yeah, mapgen env lets you modify nodes after generation but before it gets written to map, though I wouldn't really call that data "binary", it's just a lua table
10:36 ireallyhateirc I believe you can modify perlin noise parameters with mapgen settings?
10:37 ireallyhateirc https://github.com/minetest/minetest/blob/master/minetest.conf.example
10:37 ireallyhateirc in this document there are various mapgen settings listed
10:38 untilted I see, I can have my own conf file for a custom game right?
10:39 ireallyhateirc Here's an example file from my game: https://codeberg.org/perfect_city_game_studio/perfect_city/src/branch/master/minetest.conf
10:40 ireallyhateirc There I customize perlin noise for hills with the flat mapgen
10:41 untilted Thank you. I see some PerlinNoise/PerlinNoiseMap classes on the API so I'm going to look for some mapgen examples on the forums.
10:42 untilted I saw some interesting ones but at first glance it looked like it was an entire new mapgen in lua not using v7 at all.
10:42 ireallyhateirc you can also do this in lua:  minetest.set_mapgen_setting("mgflat_spflags", "nolakes, hills, nocaverns", true)
10:44 untilted I see, I can only do this once on the lua scripts.
10:44 ireallyhateirc yeah, I put that for example in ./minetest/my-game/mods/mapgen/init.lua
10:44 ireallyhateirc but anywhere works I guess
10:45 untilted Thanks.
11:11 boingman joined #minetest
11:14 MTDiscord1 joined #minetest
13:37 liceDibrarian joined #minetest
13:46 SFENCE_arch joined #minetest
13:59 Desour joined #minetest
13:59 SFENCE joined #minetest
14:07 mrkubax10 joined #minetest
14:08 kamdard joined #minetest
14:09 mrkubax10 joined #minetest
14:19 SFENCE joined #minetest
14:22 Artea joined #minetest
14:56 SFENCE joined #minetest
14:58 MacroFaxSax joined #minetest
15:30 SFENCE joined #minetest
15:45 Artea joined #minetest
15:49 jaca122 joined #minetest
15:58 SFENCE joined #minetest
16:44 CoolJar10 joined #minetest
16:48 CoolJar10 @MisterE couldn’t you use Wire-guard and ur router to configure ur own domain on ur local network?? And setting up protocol allowing Global Access to such port
16:59 jaca122 joined #minetest
17:02 SFENCE joined #minetest
17:19 Juri joined #minetest
17:21 fluxionary joined #minetest
18:27 Sokomine joined #minetest
18:27 kamdard joined #minetest
18:48 kamdard joined #minetest
19:04 Desour_ joined #minetest
19:16 Thelie joined #minetest
19:19 SFENCE joined #minetest
19:49 SFENCE joined #minetest
20:10 SFENCE joined #minetest
20:28 Talkless joined #minetest
20:28 SFENCE joined #minetest
20:28 Glaedr joined #minetest
20:42 silverwolf73828 joined #minetest
20:47 SFENCE joined #minetest
20:52 kamdard joined #minetest
21:04 MTDiscord <mistere_123> I'm quite confused why I am the ideal person to answer this question
21:06 SFENCE joined #minetest
21:08 MTDiscord <mistere_123> If you are asking about setting up a server hosted from your house, freemyip.com is a solution.
21:13 est31 joined #minetest
21:16 MTDiscord <warr1024> Asking if you could use wireguard as part of a home network setup is like asking if you can use copper to move information.  Yes, there are a lot of ways it could be involved, but without something more specific in mind, I'm not sure what can usefully be said about it.
21:24 SFENCE joined #minetest
21:36 SFENCE joined #minetest
21:55 SFENCE joined #minetest
22:00 Pokey joined #minetest
22:07 cation joined #minetest
22:15 SFENCE joined #minetest
22:32 panwolfram joined #minetest
22:33 SFENCE joined #minetest
22:51 SFENCE joined #minetest
23:01 erstazi joined #minetest
23:05 Eragon joined #minetest
23:09 SFENCE joined #minetest
23:27 untilted joined #minetest
23:29 SFENCE joined #minetest
23:31 untilted How does the lua mods work exactly? Is there an "initialization" order of which ones get to register items/biomes/etc first and can I force it to do this?
23:31 MTDiscord <luatic> mods can declare dependencies which are loaded before them. games can additionally declare a first/last mod to be loaded.
23:33 untilted I declare that by adding more dependencies in the mod.conf right? That made it work, thank you.
23:34 untilted Basically I was moving the mapgen.lua in the "default" mod to a separate one and "spawn" was triggering an assert.
23:37 SFENCE joined #minetest
23:43 Leopold joined #minetest
23:43 ireallyhateirc untilted, you seem new: https://rubenwardy.com/minetest_modding_book/en/index.html
23:44 ireallyhateirc this small book is helpful for starting modding, it explain some basic stuff

| Channels | #minetest index | Today | | Google Search | Plaintext