Ejemplo n.º 1
0
    void Start()
    {
        currentTime = 0;

        achievements = GameObject.FindGameObjectWithTag("Achievements");
        player       = GameObject.FindGameObjectWithTag("Player");
        player.transform.position = GameObject.FindGameObjectWithTag("SpawnPoint").transform.position;

        if (player.GetComponent <PlayerController>().levelCounter == 1)
        {
            PlayerPrefs.SetString("FoundSecretLevel", "False");
        }

        // Questzuweisung

        try
        {
            achievmentDisplay = GameObject.FindGameObjectWithTag("CollectAHatAchievement").GetComponent <AchievmentDisplay>();
        }        catch {}



        //Bug mit dem animationScreen

        try
        {
            transitionAnim.GetComponentInChildren <Animator>();
        }
        catch { }
    }
 // Start is called before the first frame update
 void Start()
 {
     try
     {
         achievmentDisplay = GameObject.FindGameObjectWithTag("SecondLap").GetComponent <AchievmentDisplay>();
     }
     catch
     {
     }
 }
Ejemplo n.º 3
0
 public void Start()
 {
     try
     {
         achievmentDisplay = GameObject.FindGameObjectWithTag("HitTheWallAchievement").GetComponent <AchievmentDisplay>();
     }
     catch
     {
     }
 }
Ejemplo n.º 4
0
    private void Start()
    {
        weaponFire = GameObject.Find("FireParticles");

        try
        {
            achievmentDisplay = GameObject.FindGameObjectWithTag("HotFork").GetComponent <AchievmentDisplay>();
        }
        catch { }
    }
Ejemplo n.º 5
0
 // Use this for initialization
 void Start()
 {
     audiomanager = FindObjectOfType <AudioManager>();
     try
     {
         achievementDisplay = GameObject.FindGameObjectWithTag("FindSecretsAchievement").GetComponent <AchievmentDisplay>();
     }
     catch
     {
     }
 }
Ejemplo n.º 6
0
 public void Start()
 {
     audioManager = FindObjectOfType <AudioManager>();
     try
     {
         achievmentDisplay = GameObject.FindGameObjectWithTag("CollectAHatAchievement").GetComponent <AchievmentDisplay>();
     }
     catch
     {
     }
 }
Ejemplo n.º 7
0
 private void Update()
 {
     currentTime += Time.deltaTime;
     try
     {
         if (GameObject.FindGameObjectWithTag("SpeedRun").GetComponent <AchievmentDisplay>() != null && speedRunDisplay == null)
         {
             speedRunDisplay = GameObject.FindGameObjectWithTag("SpeedRun").GetComponent <AchievmentDisplay>();
         }
     }
     catch { }
 }
Ejemplo n.º 8
0
 private void Start()
 {
     player = GameObject.FindGameObjectWithTag("Player");
     anim   = GetComponentInChildren <Animator>();
     try
     {
         achievmentDisplay = GameObject.FindGameObjectWithTag("StepOnTrapsAchievement").GetComponent <AchievmentDisplay>();
     }
     catch
     {
     }
 }
Ejemplo n.º 9
0
    private void Update()
    {
        if (achievmentDisplay == null && levelCounter < 2)
        {
            try
            {
                achievmentDisplay = GameObject.FindGameObjectWithTag("StepOnTrapsAchievement").GetComponent <AchievmentDisplay>();
            }
            catch
            {
            }
        }

        if (spawnPoint == null)
        {
            spawnPoint = GameObject.FindGameObjectWithTag("SpawnPoint");
        }
    }
Ejemplo n.º 10
0
 // Use this for initialization
 void Start()
 {
     alive        = true;
     health       = startHealth;
     ec           = FindObjectOfType <EventController>();
     audioManager = FindObjectOfType <AudioManager>();
     try
     {
         achievmentDisplay = GameObject.FindGameObjectWithTag("NoWeaponAchievement").GetComponent <AchievmentDisplay>();
     }
     catch
     {
     }
     if (healthBarSlider != null)
     {
         healthBarSlider.value = CalculateHealth();
     }
 }
Ejemplo n.º 11
0
 // Use this for initialization
 void Start()
 {
     audioManager = FindObjectOfType <AudioManager>();
     vaseAnim     = GetComponent <Animator>();
     try
     {
         achievmentDisplay = GameObject.FindGameObjectWithTag("DestroyVasesAchievement").GetComponent <AchievmentDisplay>();
     }
     catch { }
     if (isBroken == true)
     {
         vaseAnim.Play("BrokenIdle");
         GetComponent <Collider2D>().enabled = false;
         if (shadow != null)
         {
             shadow.SetActive(false);
         }
     }
 }