private void TriggerAttack(int instanceID, Killer killer) { if (this.killers.ContainsKey(instanceID)) { killer.Attack(this.victims); this.tm.doOnce <int, Killer>(killer.GetFireInterval(), this.TriggerAttack, instanceID, killer); } return; }
public void RegisteKiller(Killer killer) { print("Register: killer" + killer.GetID().ToString()); if (!this.killers.ContainsKey(killer.GetID())) { this.killers.Add(killer.GetID(), killer); this.tm.doOnce <int, Killer>(killer.GetFireInterval(), this.TriggerAttack, killer.GetID(), killer); } return; }