Tag Info

New answers tagged


This is very similar to how one might handle Achievements, or Challenges, or any other situation needing you to keep track of a series of events and counters. Simply coding the rules into a scripting language does work. You would need to be sure that all events related to conditions you care about are exposed to the language. You might also need to allow ...


i'll be a bit abstract. Why don't you use a Observer pattern After each turn you call NotifyObservers that invoke the Notify method inside each observer. Every observer is a win/defeat condition. At the start of a stage, you "register" one or more observers.


We used hardcoded conditions with some variables in early days. That was working good enough, but quite cumbersome. There were standard objects (houses, army, citizens, time) and deeds (kill, preserve) connected with win/defeat goals. So for example we could have: kill houses of player 5 to win kill army of player 5 to win preserve citizens of player 4 to ...

Top 50 recent answers are included