Added Fire API section for on_burn

This commit is contained in:
Skip 2016-01-01 16:03:49 +00:00
parent 1ca949819a
commit 907c22a401

View file

@ -145,6 +145,17 @@ farming.register_plant(name, Plant definition)
maxlight = default.LIGHT_MAX -- Maximum light to grow
}
Fire API
--------
The fire API supports nodes with groups.flammable set, with an optional callback function:
on_burn(position, igniter_node_name, action)
^ Optionally return true to prevent node being removed
-> position: "Burn position"
-> igniter_node_name: "Igniting node's name"
-> action: "Action in progress"
^ Current <action> passed to, is "remove"
Screwdriver API
---------------
The screwdriver API allows you to control a node's behaviour when a screwdriver is used on it.