1
0
Fork 0
mirror of https://github.com/luanti-org/luanti.git synced 2025-06-27 16:36:03 +00:00

[CSM] Add event on_place_node API lua (#5548)

* [CSM] Add event on_place_node API lua
This commit is contained in:
Vincent Glize 2017-04-29 12:08:16 +02:00 committed by Loïc Blot
parent ecf08255b0
commit dc5bc6cac7
12 changed files with 88 additions and 37 deletions

View file

@ -10,6 +10,13 @@ core.register_on_connect(function()
print("[PREVIEW] Player connection completed")
end)
core.register_on_placenode(function(pointed_thing, node)
print("The local player place a node!")
print("pointed_thing :" .. dump(pointed_thing))
print("node placed :" .. dump(node))
return false
end)
-- This is an example function to ensure it's working properly, should be removed before merge
core.register_on_receiving_chat_messages(function(message)
print("[PREVIEW] Received message " .. message)