1
0
mirror of https://github.com/minetest/minetest_game.git synced 2025-06-28 04:40:22 +02:00

Fix some placer nil checks

This commit is contained in:
sfan5
2024-01-11 15:50:36 +01:00
committed by GitHub
parent a3b171e317
commit 70cf7a26fd
6 changed files with 18 additions and 18 deletions

View File

@ -625,7 +625,7 @@ function tnt.register_tnt(def)
groups = {dig_immediate = 2, mesecon = 2, tnt = 1, flammable = 5},
sounds = default.node_sound_wood_defaults(),
after_place_node = function(pos, placer)
if placer:is_player() then
if placer and placer:is_player() then
local meta = minetest.get_meta(pos)
meta:set_string("owner", placer:get_player_name())
end