private void Awake()
 {
     _pSystems    = GameObject.FindGameObjectWithTag("GameSystems").GetComponent <PlayerSystems>();
     _enemy       = GetComponentInParent <EnemyController>();
     _enemyStats  = GetComponentInParent <EnemyStats>();
     handCollider = GetComponent <BoxCollider>();
 }
Esempio n. 2
0
    // Start is called before the first frame update

    void Awake()
    {
        isPlayerAlive = true;
        hasMana       = true;
        isShielded    = false;
        currentHp     = playerHp;
        currentMana   = playerMana;

        pSystems = GameObject.FindGameObjectWithTag("GameSystems").GetComponent <PlayerSystems>();
    }
Esempio n. 3
0
    void RemoveSystem(GameObject system)
    {
        string systemName  = system.name;
        string systemCoord = systemName.Split('(')[1].TrimEnd(')');

        nameList.Remove(systemCoord);

        if (PlayerSystems.Contains(system))
        {
            PlayerSystems.Remove(system);
        }

        Destroy(system);
    }
Esempio n. 4
0
 void Start()
 {
     player    = GameObject.FindGameObjectWithTag("Player").GetComponent <PlayerStats>();
     p_Systems = GameObject.FindGameObjectWithTag("GameSystems").GetComponent <PlayerSystems>();
 }
Esempio n. 5
0
 private void Awake()
 {
     Physics.IgnoreLayerCollision(16, 12);
     _player = GameObject.FindGameObjectWithTag("GameSystems").GetComponent <PlayerSystems>();
 }
Esempio n. 6
0
 // Start is called before the first frame update
 private void Awake()
 {
     player = GameObject.FindGameObjectWithTag("GameSystems").GetComponent <PlayerSystems>();
     enemy  = GetComponentInParent <EnemyStats>();
 }