private void Awake() { _pSystems = GameObject.FindGameObjectWithTag("GameSystems").GetComponent <PlayerSystems>(); _enemy = GetComponentInParent <EnemyController>(); _enemyStats = GetComponentInParent <EnemyStats>(); handCollider = GetComponent <BoxCollider>(); }
// 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>(); }
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); }
void Start() { player = GameObject.FindGameObjectWithTag("Player").GetComponent <PlayerStats>(); p_Systems = GameObject.FindGameObjectWithTag("GameSystems").GetComponent <PlayerSystems>(); }
private void Awake() { Physics.IgnoreLayerCollision(16, 12); _player = GameObject.FindGameObjectWithTag("GameSystems").GetComponent <PlayerSystems>(); }
// Start is called before the first frame update private void Awake() { player = GameObject.FindGameObjectWithTag("GameSystems").GetComponent <PlayerSystems>(); enemy = GetComponentInParent <EnemyStats>(); }