// Use this for initialization void Start() { animator = GetComponentInChildren <Animator>(); powerup_ui = transform.parent.GetComponentInChildren <PowerUpUI>(); powerup_meter = GameObject.FindObjectOfType <PowerupMeter>(); gd = GameObject.FindObjectOfType <GestureDetector>(); InitializeCooldownMeter(); InitializeBouncers(); }
void Start() { _spriteRenderer = GetComponent <SpriteRenderer>(); _spriteRenderer.sprite = PowerUp.Image; _powerUpUi = FindObjectOfType <PowerUpUI>(); _spawner = FindObjectOfType <PowerUpSpawner>(); }
public void InitUI(Character character) { m_avaibleMoney.text = "Avaible Money : " + (int)GameManager.Instance.CurrentTimer; foreach (PowerUp powerUp in character.PowerUpManager.PowerUps) { PowerUpUI powerUpUI = GameObject.Instantiate(m_powerUpUI, m_listParent).GetComponent <PowerUpUI>(); powerUpUI.Init(this, powerUp); } gameObject.SetActive(true); }
// Use this for initialization void Start() { current_amount = 0f; powerup_ui = GameObject.FindObjectOfType <PowerUpUI>(); UpdateDisplay(); grid_highlighter = transform.parent.GetComponentInChildren <GridHighlighter>(); grid = grid_highlighter.GetComponent <SpriteRenderer>(); shaker = GetComponent <Shaker>(); shaker.RegisterObject(transform.parent.position); }
protected void Awake() { powerUpUI = FindObjectOfType <PowerUpUI>(); spriteRenderer = GetComponent <SpriteRenderer>(); colliderComp = GetComponent <Collider2D>(); }
// Use this for initialization void Start() { powerup_ui = GameObject.FindObjectOfType <PowerUpUI>(); powerup_meter = GameObject.FindObjectOfType <PowerupMeter>(); next_is_triple_shot = false; }
private void Awake() { powerUpUI = GameObject.Find("PowerUps").GetComponent <PowerUpUI>(); }
void Awake() { // Initialise variables. Instance = this; }