public PoliticalOffice(Empire e, string name, PoliticalOffice parent = null) { OfficeName = name; empire = e; if (AllOffices.ContainsKey(empire)) { AllOffices [empire].Add(this); } else { AllOffices.Add(empire, new List <PoliticalOffice> () { this }); } CharacterToOffice.Add(Director, this); OfficeToCharacter.Add(this, Director); if (parent != null) { Parent = parent; Parent.Children.Add(this); } }
public void AppointPoliticalOffice(PoliticalOffice pol, bool appointedNotRemoved = true) { SetAssigned(true); string st = appointedNotRemoved ? string.Format("{0}: <color=navy>{1}</color> is <color=green>appointed</color> the <color=cyan>Director</color> of the <color=white>{2}</color>.", StrategicClock.GetDate(), GetNameString(), pol.OfficeName) : string.Format("{0}: <color=navy>{1}</color> is <color=red>removed</color> as the <color=cyan>Director</color> of the <color=white>{2}</color>.", StrategicClock.GetDate(), GetNameString(), pol.OfficeName); AddHistory(st); }