Page 1 of 1

ABM Ore Placement

PostPosted: Mon Jun 20, 2016 20:19
by octacian
How can I use ABMs to generate ores in worlds that have already been created? This has been a problem that has bothered me for a while, and it should be simple to solve. Just have a conf option to use ABMs for ores within one specific mod which would not only allow for generating ores from new mods on old worlds but also regenerating old caves.

I'm not sure how the ABMs would be written to do such advanced placement, but I think that you would most likely use other blocks as reference point from which to generate new materials.

Re: ABM Ore Placement

PostPosted: Mon Jun 20, 2016 21:01
by paramat
Use the new LBM instead, it's like an ABM but runs only once for each mapblock when that mapblock is first loaded, see lua_api.txt.

Re: ABM Ore Placement

PostPosted: Mon Jun 20, 2016 22:06
by octacian
OK, when was this introduced? (That way I know what version of Minetest my mod will require.) I assume it's then up to me to process the surrounding blocks and generate the needed ores, but I guess I'll figure that out...

Your phone or window isn't wide enough to display the code box. If it's a phone, try rotating it to landscape mode.
Code: Select all
name = "modname:replace_legacy_door"


The above is a identifier name which I assume works like those of formspecs?