mirror of
https://github.com/luanti-org/luanti.git
synced 2025-09-15 18:57:08 +00:00
Call on_secondary_use when object is right-clicked
This commit is contained in:
parent
3b0df9760b
commit
4d668f32a6
4 changed files with 15 additions and 7 deletions
|
@ -6432,9 +6432,9 @@ Used by `minetest.register_node`, `minetest.register_craftitem`, and
|
|||
-- default: minetest.item_place
|
||||
|
||||
on_secondary_use = function(itemstack, user, pointed_thing),
|
||||
-- Same as on_place but called when pointing at nothing.
|
||||
-- Same as on_place but called when not pointing at a node.
|
||||
-- The user may be any ObjectRef or nil.
|
||||
-- pointed_thing: always { type = "nothing" }
|
||||
-- default: nil
|
||||
|
||||
on_drop = function(itemstack, dropper, pos),
|
||||
-- Shall drop item and return the leftover itemstack.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue