예제 #1
0
    bool damaged;                                             // True when the player gets damaged.

    void Awake()
    {
        Instance = this;
        // Setting up the references.
        anim           = GetComponent <Animator> ();
        playerAudio    = GetComponents <AudioSource> ();
        playermovement = GetComponent <PlayerMovement> ();
        shootFireBolt  = GetComponentInChildren <ShootFireBolt> ();
        orbControl     = GetComponentInChildren <OrbControl> ();
        gameOverAnim   = gameOverCanvas.GetComponent <Animator> ();

        // Set the initial health of the player.
        currentHealth = startingHealth;
    }
 void Awake()
 {
     Instance = this;
 }