mirror of
https://notabug.org/TenPlus1/protector.git
synced 2025-01-10 13:27:33 +01:00
fix obj nil bug
This commit is contained in:
parent
a37e8e651e
commit
038aece5f7
2
init.lua
2
init.lua
@ -241,7 +241,9 @@ function minetest.is_protected(pos, digger)
|
|||||||
|
|
||||||
-- drop stack
|
-- drop stack
|
||||||
local obj = minetest.add_item(player:getpos(), sta)
|
local obj = minetest.add_item(player:getpos(), sta)
|
||||||
|
if obj then
|
||||||
obj:setvelocity({x = 0, y = 5, z = 0})
|
obj:setvelocity({x = 0, y = 5, z = 0})
|
||||||
|
end
|
||||||
end)
|
end)
|
||||||
|
|
||||||
end
|
end
|
||||||
|
Loading…
Reference in New Issue
Block a user