Make parachutes and headbars immortal
This commit is contained in:
parent
fd5caec63f
commit
c6efdc9f10
@ -53,6 +53,7 @@ minetest.register_entity(
|
||||
_wielder = nil,
|
||||
|
||||
on_activate = function(self, staticdata)
|
||||
self.object:set_armor_groups({immortal=1})
|
||||
local name = staticdata
|
||||
local wielder = minetest.get_player_by_name(name)
|
||||
if wielder and wielder:is_player() then
|
||||
|
@ -23,6 +23,9 @@ minetest.register_craftitem(
|
||||
inventory_image = "parachute_inventory.png",
|
||||
wield_image = "parachute_inventory.png",
|
||||
stack_max = 1,
|
||||
on_activate = function(self)
|
||||
self.object:set_armor_groups({immortal=1})
|
||||
end,
|
||||
on_use = function(itemstack, player, pointed_thing)
|
||||
local name = player:get_player_name()
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user