private void OnTriggerStay(Collider collision) { switch (mode) { case 0: if (collision.CompareTag("Card")) { objectInContact = collision.gameObject; } break; case 1: if (collision.CompareTag("Npc")) { Npc npcScript = collision.gameObject.GetComponent <Npc>(); if (npcScript.GetItsPlayerGroup()) { if (!npcScript.GetActionExpended()) { objectInContact = collision.gameObject; } } } break; case 2: if (collision.CompareTag("Npc")) { objectInContact = collision.gameObject; } break; } }