public bool handleActorAttack(DamageInfo damageInfo) { for (int i = 0; i < actors.Count; i++) { victim = actors.ElementAt(i); if (victim.Equals(damageInfo.attacker)) continue; else if (victim.hitBox.Intersects(damageInfo.attackRect)) { victim.velocity += damageInfo.attacker.sightVector * 20; victim.onHurt(damageInfo); Recoil recoil = new Recoil(victim.animationList, victim); if (!victim.animationList.has(recoil)) victim.animationList.pushFront(recoil); if (victim.health <= 0) { victim.onKill(damageInfo); actors.Remove(victim); } return true; } } return false; }