diff --git a/TTCS_Prot/Assets/clueObject.cs b/TTCS_Prot/Assets/clueObject.cs index ff029afb6cc0ad26cbb81e9a28b86d5ce02dec77..7869580bb5749ce0392c88bfc8ba42180e3ed2e3 100644 --- a/TTCS_Prot/Assets/clueObject.cs +++ b/TTCS_Prot/Assets/clueObject.cs @@ -33,7 +33,7 @@ public class clueObject : MonoBehaviour this.GetComponent<SpriteRenderer>().color = new Color(1.0f, 1.0f, 1.0f, 0.0f); } - if(allowInspection && Input.GetButtonDown("Inspect") & !searched) + if(allowInspection && Input.GetButtonDown("Inspect") && !searched) { for(int i = 0; i < clues.Length; i++) { @@ -47,7 +47,7 @@ public class clueObject : MonoBehaviour private void OnTriggerEnter(Collider other) { - if (other.tag == "Character") + if (other.tag == "Character" && !searched) allowInspection = true; }