public void OnDestroyed() { MyEnemyPlayer = null; GameManager = null; HandManager = null; CardDeckManager = null; BattleGroundManager = null; }
public BattlePlayer(string username, int clientId, int metalLeft, int metalMax, int lifeLeft, int lifeMax, int energyLeft, int energyMax, GameManager serverGameManager) : base(username, metalLeft, metalMax, lifeLeft, lifeMax, energyLeft, energyMax) { ClientId = clientId; GameManager = serverGameManager; HandManager = new Battle_HandManager(this); CardDeckManager = new CardDeckManager(this); BattleGroundManager = new BattleGroundManager(this); BattleStatistics = new BattleStatistics(); }
void Start() { unitFactoryManager = GetComponent <UnitFactoryManager>(); battleGroundManager = GetComponent <BattleGroundManager>(); activeUnitManager = GetComponent <ActiveUnitManager>(); uiController = GetComponent <UIController>(); //Subject-Observer activeUnitManager.Register(this); }