예제 #1
0
        public virtual void Start()
        {
            if (health <= 0)
            {
                health = 1;
            }

            if (maxHealth < health)
            {
                maxHealth = health;
            }

            if (takeDamageAudioClip || recoverHealthAudioClip)
            {
                audioSource = AudioManager.AudioSourceInstance;
            }

            controller = GetComponent <Controller2D> ();
        }
예제 #2
0
 // Use this for initialization
 public virtual void Start()
 {
     controller = GetComponent <Controller2D> ();
 }
예제 #3
0
 void Start()
 {
     controller = transform.parent.GetComponent <Controller2D> ();
 }
예제 #4
0
        // Use this for initialization
        void Start()
        {
            player = FindObjectOfType <PlayerController> ();

            isFollowing = true;
        }