Because I was lazy to write > 60 nodes definitions I did written a framework that do it for me. The result is a mod that contains basically a method "customnode.add_nodes_from_textures()" that can be used from other mods. So the init.lua can be in best case:
Code: Select all
customnode.add_nodes_from_textures({ descr_prefix = "New Super Mario" })
In further development the shapes handler was added. Beside node variants (wood, stone..) the support for tasks was added. The stairs/slabs is enabled by default for certain variants, the carpets support is provided only.
To be able to run tasks on already defined nodes the method customnode.apply_variants_to_depnodes() was introduced. This method reads the depends.txt from custom-mod and then check for usable nodes and apply the variant tasks on them.
Not implemented (and not planned currently): mobs, items.
More details in github readme.
github: https://github.com/bell07/minetest-customnode/
License: L-GPL2.1
Dependencies:
default (The sounds are used from this mod)
stairs (optional) - generates stairs and slabs for some variants
Screenshots: (not included, my usage in mods "smb", "sonic", kirby", "newsupermario")
customnode.apply_variants_to_depnodes() for abriglass, pbj_pup and
myroofs
Code: Select all
customnode.register_variant("glass", {
tasks = {"stairs:stairs_slabs"},
})
customnode.register_variant("default", {
tasks = {"carpets:carpet"},
})
customnode.apply_variants_to_depnodes()