better calculation
This commit is contained in:
parent
7d3ba09c35
commit
cfb5b63bb6
@ -12,9 +12,7 @@ function nssm:virulence(mobe)
|
||||
if not nssm.lessvirulent then
|
||||
return 0
|
||||
end
|
||||
local chance = 100 - mobe.hp_max
|
||||
--minetest.debug("Got virulence dampening "..chance.." for "..self.name)
|
||||
if chance < 1 then return 1 else return chance end
|
||||
local chance = math.ceil(100 / mobe.hp_max)
|
||||
end
|
||||
|
||||
function nssm:affectbones(mobe) -- as function for adaptable heuristic
|
||||
|
Loading…
x
Reference in New Issue
Block a user