//public FixedJoystick joystick;
    //private float v;
    // Use this for initialization
    void Start()
    {
        shieldTimer     = shieldTotalTimer;
        magnetTimer     = magnetTotalTimer;
        magnetEnabled   = false;
        shieldActivated = false;
        //magnetTimer = 10f;
        //h = GetAxis("Horizontal");
        //v = GetAxisRow("Vertical");
        Debug.Log("Left Button Position : " + leftButton.transform.position);
        Debug.Log("right Button Position : " + rightButton.transform.position);
        Debug.Log("Jump Button Position : " + jumpButton.transform.position);
        LoadGame();
        Debug.Log("Left Button Position : " + leftButton.transform.position);
        Debug.Log("right Button Position : " + rightButton.transform.position);
        Debug.Log("Jump Button Position : " + jumpButton.transform.position);
        gm = GameObject.FindWithTag("GameController").GetComponent <gamaManager>();


        // Option to set sideways Force

        /*if (!PlayerPrefs.HasKey("Sideways Force")) {
         * PlayerPrefs.SetInt("Sideways Force",30);
         * }
         * else {
         * sideways_force = PlayerPrefs.GetInt("Sideways Force");
         * }*/
        //forward_force = gm.forwardForce;
    }
 /*public GameObject powerupTimerPanel;
  * public GameObject magnetTimerPanel;*/
 // Start is called before the first frame update
 void Start()
 {
     magnetTimer      = magnetTotalTimer;
     gm               = GameObject.FindWithTag("GameController").GetComponent <gamaManager>();
     pm               = GameObject.FindWithTag("Player").GetComponent <player_movement>();
     magnetTimerImage = pm.magnetTimerImage;
 }
 // Start is called before the first frame update
 void Start()
 {
     gm = GameObject.FindWithTag("GameController").GetComponent <gamaManager>();
     //RandomPosition = new Vector3(Random.Range(-4f, 4f), 0.5f, Random.Range(player.transform.position.z + 100f, player.transform.position.z + 200f));
     //newshield = Instantiate(shield, RandomPosition, Quaternion.identity);
     shieldInstantiationTime = Random.Range(10f, 30f);
 }
Exemplo n.º 4
0
 // Start is called before the first frame update
 void Start()
 {
     time = timeAmt;
     cost = 50;
     //gm = GetComponent<gamaManager>();
     gm = GameObject.FindWithTag("GameController").GetComponent <gamaManager>();
     //startTimer();
 }
Exemplo n.º 5
0
 // Start is called before the first frame update
 void Start()
 {
     //StartCoroutine(increaseSpeedTimer());
     gm     = GameObject.FindWithTag("GameController").GetComponent <gamaManager>();
     Player = GameObject.FindWithTag("Player");
     //forward_force = gm.getRandomSpeed();
     //Debug.Log("Random speed : "+forward_force);
     //forward_force = gm.forwardForce;
 }
Exemplo n.º 6
0
 // Start is called before the first frame update
 void Start()
 {
     gm           = GameObject.FindWithTag("GameController").GetComponent <gamaManager>();
     screenBounds = Camera.main.ScreenToWorldPoint(new Vector3(Screen.width, Screen.height, Camera.main.transform.position.z));
     //Debug.Log(screenBounds);
     forward_force = gm.forwardForce;
     //StartCoroutine(CoinsGenerate());
     sm      = GetComponent <SpawnEnemy>();
     sm.coin = a;
 }
 // Start is called before the first frame update
 void Start()
 {
     gm     = GameObject.FindWithTag("GameController").GetComponent <gamaManager>();
     Player = GameObject.FindWithTag("Player");
 }