public RiceTerrainTile(uint row, uint col, bool flooded) { this.row = row; this.col = col; _riceState = RiceState.NOT_PLANTED; selected = false; _daysPlanted = 0; _daysBurning = 0; _hasAlreadyBeenWorked = false; _weed = new Weed(this); _bHasAppliedHerbicide = false; _bHasAppliedFangueig = false; _isBurningRostoll = false; _tutMan = GameObject.FindGameObjectWithTag("Tutorial").GetComponent <TutorialManager> (); GameObject.FindGameObjectWithTag("Logic").GetComponent <TimeManager> ().addListerToDayChange(this.newDayCallback); _actionsDoneInTheYear = new List <int> (); if (flooded) { this._terrainState = RiceTerrainState.WATER; } else { this._terrainState = RiceTerrainState.SOIL_MUDDY; } _plague = new PlagueInstance(this); updateTerrainRepresentation(); // Load Outline InstantiateImages(); }
public RiceTerrainTile() { GameObject.FindGameObjectWithTag("Logic").GetComponent <TimeManager>().addListerToDayChange(this.newDayCallback); _weed = new Weed(this); _plague = new PlagueInstance(this); _tutMan = GameObject.FindGameObjectWithTag("Tutorial").GetComponent <TutorialManager> (); }