protected bool _didDealDamage = false;            // A check to see if the monster has dealt damage to the player or not
    #endregion

    public void Start()
    {
        _damageText    = Resources.Load("InWorldUI/DamageText") as GameObject;
        _rigid         = GetComponent <Rigidbody>();
        _sm            = SpawnMonsters.instance;
        _chargeAtMove  = Random.Range(5, 10);
        _monsterCanvas = transform.Find("MonsterCanvas").gameObject;
        _redFill       = _monsterCanvas.transform.Find("Red").gameObject;
        _player        = PlayerScript.instance;
        _camera        = GameObject.Find("ARCore Device").GetComponentInChildren <Camera>();
    }
Beispiel #2
0
    void Start()
    {
        spawnMonsters = FindObjectOfType <SpawnMonsters>();
        HudMenu       = GameObject.FindGameObjectWithTag("Area").GetComponent <Hud_Menu>();


        for (int i = 0; i < Warps.Length; i++)
        {
            Warps[i].GetComponent <BoxCollider2D>().isTrigger = false;
        }
    }
Beispiel #3
0
 private void Awake()
 {
     instance = this;
 }