예제 #1
0
    // Start is called before the first frame update
    void Start()
    {
        //reviveButtonRect.anchoredPosition = new Vector2(0, 500);
        pool = GameObject.Find("Tilemap").GetComponent <ObjectPoolNS>();
        anim = GetComponent <Animator>();

        /*
         * GameManager.manager.coin_in_bank = PlayerPrefs.GetFloat("current_coins", 0);
         * GameManager.manager.max_fatigue = PlayerPrefs.GetFloat("max_fatigue", 10);
         * GameManager.manager.fatigue_recover_multiplier = PlayerPrefs.GetFloat("fatigue_recover", 5);
         * GameManager.manager.fatigue_drain_rate = PlayerPrefs.GetFloat("fatigue_drain", 1);
         * GameManager.manager.pushing_max = PlayerPrefs.GetFloat("max_hold", 3);
         * GameManager.manager.pushing_drain_rate = PlayerPrefs.GetFloat("hold_time_drain", 1);
         * GameManager.manager.fast_duration = PlayerPrefs.GetFloat("fast_duration", 0.9f);
         *
         * GameManager.manager.max_fatigue_coin_req = PlayerPrefs.GetFloat("max_fatigue_cost", 100);
         * GameManager.manager.fatigue_recover_coin_req = PlayerPrefs.GetFloat("fatigue_recover_cost", 100);
         * GameManager.manager.fatigue_drain_coin_req = PlayerPrefs.GetFloat("fatigue_drain_cost", 100);
         * GameManager.manager.max_hold_coin_req = PlayerPrefs.GetFloat("max_hold_cost", 100);
         * GameManager.manager.hold_drain_coin_req = PlayerPrefs.GetFloat("hold_time_drain_cost", 100);
         * GameManager.manager.fast_duration_coin_req = PlayerPrefs.GetFloat("fast_duration_cost", 100);
         */

        stop_counter.maxValue    = GameManager.manager.pushing_max;
        fatigue_counter.maxValue = GameManager.manager.max_fatigue;
    }
예제 #2
0
 private void Start()
 {
     shake              = FindObjectOfType <CamShake>();
     box_collider       = GetComponent <BoxCollider2D>();
     transform.position = start_pos.position;
     barrelPool         = GameObject.Find("Barrel Spawner").GetComponent <ObjectPoolNS>();
     health             = 1;
 }
예제 #3
0
 // Start is called before the first frame update
 void Start()
 {
     tilemap_pool = GetComponentInParent <ObjectPoolNS>();
 }
예제 #4
0
 // Start is called before the first frame update
 void Start()
 {
     ID                 = 1;
     box_particles      = GameObject.Find("Particles").GetComponent <ObjectPoolNS>();
     transform.position = start_pos.position;
 }
예제 #5
0
 // Start is called before the first frame update
 void Start()
 {
     rb2d  = GetComponent <Rigidbody2D>();
     shake = FindObjectOfType <CamShake>();
     pool  = GameObject.Find("Tilemap").GetComponent <ObjectPoolNS>();
 }
예제 #6
0
 private void Start()
 {
     boss        = GetComponentInChildren <Pig>();
     bullet_pool = GameObject.Find("Enemy Projectile Pool").GetComponent <ObjectPoolNS>();
 }
예제 #7
0
 private void Start()
 {
     pool = GameObject.Find("Tilemap").GetComponent <ObjectPoolNS>();
 }
예제 #8
0
 // Start is called before the first frame update
 void Start()
 {
     player_death = FindObjectOfType <PlayerDeath>();
     quest_giver  = FindObjectOfType <Quest_Giver>();
     pool         = GameObject.Find("Tilemap").GetComponent <ObjectPoolNS>();
 }
예제 #9
0
 // Start is called before the first frame update
 void Start()
 {
     transform.position = start_pos.position;
     barrels            = GameObject.Find("Barrel Spawner").GetComponent <ObjectPoolNS>();
     health             = 1;
 }
예제 #10
0
 // Start is called before the first frame update
 void Start()
 {
     rb2d      = GetComponent <Rigidbody2D>();
     particles = GameObject.Find("Particles").GetComponent <ObjectPoolNS>();
     //rb2d.AddForce(Vector2.right * speed, ForceMode2D.Impulse);
 }