Ejemplo n.º 1
0
    // Use this for initialization
    void Start()
    {
        GM      = GameObject.FindGameObjectWithTag("GameController").GetComponent <GameManager>();
        sShaker = GetComponent <spriteShaker>();
        aSource = GetComponent <AudioSource>();
        sl      = GM.sliderGrill;
        //sR = GetComponent<SpriteRenderer>();

        string weight = "2 Kg.";


        int i = Random.Range(0, 100);

        if (i < 20)
        {
            transform.localScale = Vector3.one * 0.75f;
            cookRatio            = 2;
            weight = "1 Kg.";
        }

        if (i > 80)
        {
            transform.localScale = Vector3.one * 1.5f;
            cookRatio            = 0.7f;
            weight = "4 Kg.";
        }

        GM.UI.chickenWeight.text = weight;
    }
Ejemplo n.º 2
0
	// Use this for initialization
	void Start () {
        GM = GameObject.FindGameObjectWithTag("GameController").GetComponent<GameManager>();
        sShaker = GetComponent<spriteShaker>();
        aSource = GetComponent<AudioSource>();
        sl = GM.sliderGrill;
        //sR = GetComponent<SpriteRenderer>();

        string weight = "2 Kg.";
        

        int i = Random.Range(0, 100);
        if (i < 20) {
            transform.localScale = Vector3.one * 0.75f;
            cookRatio = 2;
            weight = "1 Kg.";
        }

        if (i >80)
        {
            transform.localScale = Vector3.one * 1.5f;
            cookRatio = 0.7f;
            weight = "4 Kg.";
        }

        GM.UI.chickenWeight.text = weight;

	}