// Use this for initialization void Start() { feverBar = transform.FindChild("feverFrame").FindChild("feverBar").gameObject.GetComponent<Image>(); timeBar = transform.FindChild("timeFrame").FindChild("timeBar").gameObject.GetComponent<Image>(); GameInfoCanvas giCanvas = transform.root.gameObject.GetComponent<AppliController>().GetCurrentScene().GetComponent<GameScene>().gameUI.gameInfoCanvas; lTimeScript = giCanvas.limitTime; feverScript = giCanvas.feverGauge; transform.FindChild("ScoreNum").GetComponent<Text>().text = giCanvas.score.GameScore.ToString(); }
// Use this for initialization void Start() { GetComponent<Canvas>().worldCamera = Camera.main; _score = GetComponentInChildren<Score>(); _limitTime = GetComponentInChildren<LimitTime>(); _feverGauge = GetComponentInChildren<FeverGauge>(); _stageSelectButton = GetComponentInChildren<Button>(); levelText = transform.FindChild("GameInfoPanel").FindChild("LevelText").GetComponent<Text>(); levelText.text = "Easy"; }
void Awake() { instance = this; feverField.transform.localScale = new Vector3(0, 1, 1); }
void Start () { feverInstance = FeverGauge.Instance; SharedDataInstance = SharedData.Instance; sprBody.SetSprite(string.Format("body_{0}", SharedDataInstance.bodyId)); sprEyes.SetSprite(string.Format("eyes_{0}", SharedDataInstance.eyesId)); sprMouth.SetSprite(string.Format("mouth_{0}", SharedDataInstance.mouthId)); sprFin.SetSprite(string.Format("fin_{0}", SharedDataInstance.finId)); curHitPoint = maxHitPoint; }
void Start () { feverInstance = FeverGauge.Instance; sprBody.SetSprite(string.Format("body_{0}", SharedData.bodyId)); aniEyes.Play(string.Format("Hurt_{0}", SharedData.eyesId)); aniEyes.Stop(); aniFin.Play(string.Format("Swimming_{0}", SharedData.finId)); aniMouth.Play(string.Format("Eat_{0}", SharedData.mouthId)); aniMouth.Stop(); curHitPoint = maxHitPoint; }