public void OnNextTurn(City city, GameMaster game) { foreach (BuildingEffect effect in GlobalBuildingDictionary.GetNextTurnEffects(ID)) { effect.Apply(city); } }
public string GetDescription() { string descr = "BUILDING TEST DESCRIPTION\n"; descr += "On Completion: \n"; foreach (BuildingEffect effect in GlobalBuildingDictionary.GetCompletionEffects(ID)) { descr += "\t" + effect.ToString() + "\n"; } descr += "On Next Turn:"; foreach (BuildingEffect effect in GlobalBuildingDictionary.GetNextTurnEffects(ID)) { descr += "\n\t" + effect.ToString(); } return(descr); }
public void Complete(City city, World world) { foreach (BuildingEffect effect in GlobalBuildingDictionary.GetCompletionEffects(ID)) { effect.Apply(city); } if (destIndex == -1) { destination.Buildings.Add(this); } else { destination.Buildings[destIndex] = this; } }