forked from minetest/minetest_game
Add item name to chest log messages
This commit is contained in:
parent
3a55e19055
commit
42cc6d2c31
@ -1445,11 +1445,13 @@ minetest.register_node("default:chest", {
|
|||||||
end,
|
end,
|
||||||
on_metadata_inventory_put = function(pos, listname, index, stack, player)
|
on_metadata_inventory_put = function(pos, listname, index, stack, player)
|
||||||
minetest.log("action", player:get_player_name() ..
|
minetest.log("action", player:get_player_name() ..
|
||||||
" moves stuff to chest at " .. minetest.pos_to_string(pos))
|
" moves " .. stack:get_name() ..
|
||||||
|
" to chest at " .. minetest.pos_to_string(pos))
|
||||||
end,
|
end,
|
||||||
on_metadata_inventory_take = function(pos, listname, index, stack, player)
|
on_metadata_inventory_take = function(pos, listname, index, stack, player)
|
||||||
minetest.log("action", player:get_player_name() ..
|
minetest.log("action", player:get_player_name() ..
|
||||||
" takes stuff from chest at " .. minetest.pos_to_string(pos))
|
" takes " .. stack:get_name() ..
|
||||||
|
" from chest at " .. minetest.pos_to_string(pos))
|
||||||
end,
|
end,
|
||||||
})
|
})
|
||||||
|
|
||||||
@ -1505,11 +1507,13 @@ minetest.register_node("default:chest_locked", {
|
|||||||
end,
|
end,
|
||||||
on_metadata_inventory_put = function(pos, listname, index, stack, player)
|
on_metadata_inventory_put = function(pos, listname, index, stack, player)
|
||||||
minetest.log("action", player:get_player_name() ..
|
minetest.log("action", player:get_player_name() ..
|
||||||
" moves stuff to locked chest at " .. minetest.pos_to_string(pos))
|
" moves " .. stack:get_name() ..
|
||||||
|
" to locked chest at " .. minetest.pos_to_string(pos))
|
||||||
end,
|
end,
|
||||||
on_metadata_inventory_take = function(pos, listname, index, stack, player)
|
on_metadata_inventory_take = function(pos, listname, index, stack, player)
|
||||||
minetest.log("action", player:get_player_name() ..
|
minetest.log("action", player:get_player_name() ..
|
||||||
" takes stuff from locked chest at " .. minetest.pos_to_string(pos))
|
" takes " .. stack:get_name() ..
|
||||||
|
" from locked chest at " .. minetest.pos_to_string(pos))
|
||||||
end,
|
end,
|
||||||
on_rightclick = function(pos, node, clicker)
|
on_rightclick = function(pos, node, clicker)
|
||||||
local meta = minetest.get_meta(pos)
|
local meta = minetest.get_meta(pos)
|
||||||
|
Loading…
Reference in New Issue
Block a user