示例#1
0
 public void ActivateObject()
 {
     //door.Toggle();
     if (!isExit && door != null)
     {
         door.Toggle();
     }
     else if (door != null)
     {
         component.invoke();
     }
     if (component != null && !isPlayed)
     {
         isPlayed = true;
         component.invoke();
     }
 }
示例#2
0
 public void PressButton()
 {
     //door.Toggle();
     if (!isExit)
     {
         door.Toggle();
     }
     else
     {
         component.invoke();
     }
     //Debug.Log("Ik word aangeroepen");
     if (component != null && !isPlayed)
     {
         isPlayed = true;
         component.invoke();
     }
 }