mob/proc/MonsterAttack(mob/M)
var/damage = 5
sleep(20)
damage += rand(1,10)
M<< "[src] attacks you for [damage] damage!"
M.hp -= damage
M.Update()
M.DeathCheck(src)
sleep(10)
if(istype(M,/mob/NPC/Monster))
M.MonsterAttack(src)
else
M.Attack(src)
..()
Now when the battle starts it works perfectly however the problem that exists is that when i die the battle does not end. How do i stop the monster from continuing to call the MonsterAttack() proc?
~>Jiskuha
<DM<if(src.dead||M.dead)
return</DM>