forked from VoxeLibre/VoxeLibre
stop projectile mobs from being completely disabled while stunned
This commit is contained in:
parent
eb7ae5e10e
commit
73b4d3c1d2
|
@ -744,6 +744,14 @@ mobs.mob_step = function(self, dtime)
|
||||||
self.pause_timer = 0
|
self.pause_timer = 0
|
||||||
end
|
end
|
||||||
|
|
||||||
|
--stop projectile mobs from being completely disabled while stunned
|
||||||
|
if self.projectile_timer and self.projectile_timer > 0.01 then
|
||||||
|
self.projectile_timer = self.projectile_timer - dtime
|
||||||
|
if self.projectile_timer < 0.01 then
|
||||||
|
self.projectile_timer = 0.01
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
return -- don't allow collision detection
|
return -- don't allow collision detection
|
||||||
--do normal ai
|
--do normal ai
|
||||||
else
|
else
|
||||||
|
|
Loading…
Reference in New Issue