fix crash by nil damagegroup
parent
9d023c0a97
commit
ff7e2acbbe
|
@ -211,6 +211,7 @@ on_punch=function(self, puncher, time_from_last_punch, tool_capabilities, dir)
|
|||
aliveai.max(self,true)
|
||||
return self
|
||||
end
|
||||
tool_capabilities.damage_groups.fleshy=tool_capabilities.damage_groups.fleshy or 1
|
||||
local mindmg=tool_capabilities.damage_groups.fleshy>=self.mindamage
|
||||
local dmg=0
|
||||
|
||||
|
@ -668,4 +669,4 @@ minetest.register_craftitem("aliveai:teampawner", {
|
|||
end
|
||||
return itemstack
|
||||
end,
|
||||
})
|
||||
})
|
Loading…
Reference in New Issue