public void ModuleDestroy() { Transform t; for (int i = 0; i < transform.childCount; i++) { if ((t = transform.GetChild(i)).CompareTag("Hackable")) { Destroy(t.gameObject); } } if (PlayerInside == 0) { return; } HackAction h = null; foreach (ModuleAction a in Actions) { if ((a is HackAction)) { h = (HackAction)a; } else { a.enabled = false; } } UIManager.current.ChangeAbilities(PlayerInside); h.Init(PlayerInside); }
public HackException(HackAction action, string message) : base(message) { this.Action = action; }