示例#1
0
 public void Update()
 {
     if (leftElytra.instrumentPlaying && rightElytra.instrumentPlaying && !activated)
     {
         activated = true;
         leftElytra.LockElytra();
         rightElytra.LockElytra();
         door.Activate();
     }
 }
示例#2
0
 private void OnCollisionEnter(Collision collision)
 {
     if (this.active && collision.gameObject.tag == "Player")
     {
         if (closet)
         {
             closet.Toggle();
         }
         if (door)
         {
             door.Activate();
         }
         if (shedDoor)
         {
             shedDoor.Activate();
         }
         Destroy(gameObject);
     }
 }