void makeInstace()
 {
     if (instance == null)
     {
         instance = this;
     }
 }
Beispiel #2
0
 void Start()
 {
     if (player == null)
     {
         player = GameObject.Find("character").GetComponent <characterController>();
     }
     gamePlayController = GameObject.Find("GameplayController").GetComponent <gamePlayController>();
 }
Beispiel #3
0
    private void Start()
    {
        playerStatus ps = new playerStatus();

        // fileManager.savePlayerStatus(ps);
        instance = this;

        updateCoinUI(0);
        updateScoreUI(0);

        resetPlayerStatus();
    }
Beispiel #4
0
 void Start()
 {
     charTransform      = this.transform;
     gamePlayController = GameObject.Find("GameplayController").GetComponent <gamePlayController>();
 }
Beispiel #5
0
 void Awake()
 {
     _gamePlayController = Object.FindObjectOfType <gamePlayController>();
     anim = this.GetComponent <Animator>();
     anim.SetInteger("typeAnim", level);
 }
 void OnDisable()
 {
     SceneManager.sceneLoaded -= onSceneLoaded;
     instance = null;
 }
Beispiel #7
0
 void Start()
 {
     gamePlayController = GameObject.Find("GameplayController").GetComponent <gamePlayController>();
     sound = gameObject.GetComponent <AudioSource>();
 }