Ejemplo n.º 1
0
 // Use this for initialization
 void Start()
 {
     Player        = GameObject.Find("Player");
     PM            = GameObject.Find("Player").GetComponent <Player_Manager>();
     currentSeason = null;
     currentScene  = SceneManager.GetActiveScene().name;
 }
Ejemplo n.º 2
0
        // Use this for initialization
        void Start()
        {
            //jumpHeight;
            PlayerManager = GetComponent <Player_Manager>();
            rBody         = GetComponent <Rigidbody2D>();
            Anim          = GetComponent <Animator>();

            PlayerManager.currentMoveSpeed = PlayerManager.defaultMoveSpeed;
        }
Ejemplo n.º 3
0
        // Use this for initialization
        void Start()
        {
            Player = GameObject.Find("Player");
            PM     = Player.GetComponent <Player_Manager>();

            //if a scene is loaded and a duplicate object is found. Destroy it
            if (GameObject.Find(this.name).GetComponent <Object_Interaction>().created == true)
            {
                Destroy(this.gameObject);
            }
            created = true;
        }
Ejemplo n.º 4
0
 // Use this for initialization
 void Start()
 {
     Player = GameObject.Find("Player");
     SC     = GameObject.Find("SceneChanger").GetComponent <SceneChanger>();
     PM     = GameObject.Find("Player").GetComponent <Player_Manager>();
     if (!SC.justChanged)
     {
         Player.transform.position = transform.position;
     }
     else
     {
         SC.justChanged = false;
     }
 }