* Move descriptive function comments to above the function definition.
* Adopt some luadoc styles.
* Update a stale reference to a renamed function in comments.
* Fix silly and mostly inconsequential logic bug that had gone unnoticed up
till now.
* Condense a single use variable away by using a slightly more elaborate
assignment statement.
* Add a few more local aliases for global minetest.* functions.
* Replace use of local table with compostability values with a call to
`minetest.get_item_group()`.
* Define local alias for `minetest.get_item_group`.
* Remove the now unused static compostabilty values table.
* Change carpet from `group:attached_node` to `group:supported_node`,
allowing carpets to be placed on top of torches, water source blocks
and other non-walkable nodes, like in MC.
* Make carpets walkable. When a carpet is placed on top of a fence or a
wall, the carpet can be jumped upon, allowing to in effect jump over
fences and walls.
The daylight detector code used get_node_light(), which detects both
natural and artificial light. This patch improves the code to use
get_natural_light(), which was introduced with Minetest 5.4.0.
* Check if node has a definition table before attempting to evaluate its
attributes.
* Define local variable to cache multiple accesses to `registered_nodes[]`
and improve readability.
This solves a problem were nether portal removal would trigger deep
recursion through node callbacks. For large portals this could result
in stack overflow crashes on LuaJIT. The issue is solved by rewriting
the portal removal to avoid recursion and removing the portal in one
operation using minetest.bulk_set_node.
The function dynamic_add_media() was changed in incompatible ways in
several minor versions of Minetest, breaking the display of handheld
maps in Minetest 5.5.0. This patch makes handheld maps display there.
The function was blocking with one argument in Minetest 5.3. It was also
blocking in Minetest 5.4, but took an additional argument for a function
to execute once the media had been received. Calling dynamic_add_media()
with a single argument had been deprecated; a function that did nothing
was provided in mcl_maps to satisfy the changed argument requirements.
In Minetest 5.5, dynamic_add_media() was changed to non-blocking. This
introduced a race condition in mcl_maps, where a client often tried to
display a map before it had received the map texture from the server.
Opening an issue on the Minetest issue tracker led to it being closed in
about 20 minutes: <https://github.com/minetest/minetest/issues/11997>