Beispiel #1
0
 public override void LoseWeakPoint(string tag = "")
 {
     Debug.Log("Destuction tag: " + tag);
     //
     if (tag.Equals("Connection"))
     {
         posteriorSegmentBehaviour.LoseConnectionWithPrev();
         posteriorSegmentBehaviour = null;
         posteriorSegment          = null;
         //
         CheckDeath();
         // TODO: Manejar aqui reaisgnacion en body part
         HeadBehaviour.StartSprint();
         //
         enemyManager.ActivateEnemies(2, transform.position);
     }
     else if (tag.Equals("Generator"))
     {
         // De momento trabajamos con este valor
         currentLiftForce -= 25;
         //
         CheckDeath();
         //
         StartSprint();
         //
         enemyManager.ActivateEnemies(1, transform.position);
     }
 }
Beispiel #2
0
 void Start()
 {
     sounds     = GetComponents <AudioSource> ();
     headScript = GetComponent <HeadBehaviour> ();
     leftAlive  = true;
     rightAlive = true;
     headAlive  = true;
     StartCoroutine(bossSpawn());
 }
Beispiel #3
0
 public IEnumerator bossFightStart()
 {
     health           = 9;
     healthTrack      = GameObject.FindGameObjectWithTag("Boss").GetComponent <HeadBehaviour> ();
     bossText.enabled = true;
     for (int i = 0; i < 10; i++)
     {
         lifeBar[i].enabled = true;
         beep.Play();
         yield return(new WaitForSeconds(0.1f));
     }
 }