Exemple #1
0
    // Use this for initialization
    void Start()
    {
        //gameMngr = GameObject.Find ("GameManager");

        counter = gameMngr.GetComponent <DrawUI> ();
        Debug.Log("filter set up");
    }
Exemple #2
0
        private static void RemoveDrawer(DrawUI method)
        {
            if (method == null)
            {
                return;
            }

            if (drawers.Contains(method))
            {
                drawers.Remove(method);
            }
        }
Exemple #3
0
        public static void AddDrawer(DrawUI method)
        {
            if (method != null)
            {
                if (drawers.Contains(method))
                {
                    return;
                }

                drawers.Add(method);
            }
        }
Exemple #4
0
    private void LoadComponents()
    {
        _netWorking = new NetWorking();
        _notyfy     = new Notyfy();
        _drawUI     = new DrawUI();

        _drawUI.GameHandler = this;
        _enemy                = EnemyGameObject.GetComponent <Enemy>();
        _enemyHandler         = EnemyGameObject.GetComponent <EnemyHandler>();
        _animatorDefeatNotyfy = DefeatNotyfy.GetComponent <Animator>();
        _animatorWinNotyfy    = WinNotyfy.GetComponent <Animator>();
        _rewardAD             = GetComponent <RewardAD>();
        _enemyHandler.Damage  = Damage;
        TimeHandle.Power(TimeGame);

        _enemyHandler.Notify += ChangeHealth;
        TimeHandle.OnChanges += SendNotifyEndTime;
        _rewardAD.Notify     += Reward;

        if (PlayerPrefs.HasKey("Record"))
        {
            Best = PlayerPrefs.GetInt("Record");
        }
    }
Exemple #5
0
    //public GameObject enemyInstance;
    //public GameObject burst;

    void Start()
    {
        counter = gameMngr.GetComponent <DrawUI> ();
    }
 private void Start()
 {
     _drawUI = FindObjectOfType <DrawUI>();
 }