Document _mcl_baseitem

This commit is contained in:
cora 2024-08-22 22:49:08 +02:00 committed by cora
parent 3d5565e980
commit 9779c95432

1
API.md
View File

@ -111,6 +111,7 @@ These can be applied to all node registrations.
* `_on_hopper_in` callback when an item is about to be pushed to the node from a hopper: function(hopper_pos, node_pos) * `_on_hopper_in` callback when an item is about to be pushed to the node from a hopper: function(hopper_pos, node_pos)
* `_on_hopper_out` callback when an item is about to be sucked into a hopper under the node: function(node_pos, hopper_pos) * `_on_hopper_out` callback when an item is about to be sucked into a hopper under the node: function(node_pos, hopper_pos)
* `_on_lightning_strike` callback when a node is hit by lightning: function(node_pos, lightning_pos1, lightning_pos2) * `_on_lightning_strike` callback when a node is hit by lightning: function(node_pos, lightning_pos1, lightning_pos2)
* `_mcl_baseitem` this used to determine the item corresponding to the placed node. Can either be an itemstring or a function(pos) returning an itemstack.
* Get node names close to player (to reduce constant querying): * Get node names close to player (to reduce constant querying):
`PLAYER/mcl_playerinfo` `PLAYER/mcl_playerinfo`
* Colors and dyes API: `ITEMS/mcl_dyes` * Colors and dyes API: `ITEMS/mcl_dyes`