Commit Graph

41 Commits

Author SHA1 Message Date
Tom Stellard eb15df7cd9 Allow using rank_start and rank_end tags for prom_games
This adds the same functionality already supported by the prom_rel
tags to support reserve team promotion rules for promotion games.
This allows you to specify a larger range of teams to promte than
the number of teams defined with the number_of_teams tag, so that
if a team is ineligible for promotion than other teams can be
substituted.  For example, if you wanted to promote at most 2
of the top 3 teams, you could do:

<prom_games>
  <prom_games_number_of_advance>2</prom_games_number_of_advance>
  <rank_start>1</rank_start>
  <rank_end>3</rank_end>
</prom_games>

Note that the rank_start and rank_end tags are not supported when using
the prom_games_loser_sid tag.
2020-12-24 10:43:39 -08:00
Tom Stellard f928273875 Add first_team and reserve_level tags to team element
The first_team tag can be used to indicate that a team is a 'reserve
team'.  The value for this new tag is the name of the first team
for this reserve team.  The reserve_level is used to indicate if this
is the 2nd, 3rd, 4th, etc. team for the first team. For example:

<team>
  <team_name>Blue</team_name>
</team>
<team>
  <team_name>Blue 2</team_name>
  <first_team>Blue</first_team>
  <reserve_level>2</reserve_level>
</team>
<team>
  <team_name>Blue 3</team_name>
  <first_team>Blue</first_team>
  <reserve_level>3</reserve_level>
</team>
2020-12-24 10:43:39 -08:00
Tom Stellard 8bca18d8a2 Add number_of_teams tag to prom_rel_element
This tag is intended to be used for leagues that may have some teams in
the league that are ineligible for promotions (e.g. reserve teams).
Often these leagues will promote 2 of the top 3 teams or something
similar, so if one team is ineligible, the league would still be able
to promote 2 teams.  Below is an example of how to model this scenario
with the new tag:

<prom_rel_element>
  <rank_start>1</rank_start>
  <rank_end>3</rank_end>
  <number_of_teams>2</number_of_teams>
</prom_rel_element>
2020-12-24 10:43:39 -08:00
Tom Stellard a31ea36c08 Cache some commonly used constants
All constants were stored in a g_datalist structure, which has very slow
lookups.  This was not ideally for constansts used during game play
which are accessed thousands of times.  Caching these values makes the
game simulations about 2 times faster.
2020-12-24 10:43:39 -08:00
gyboth 078b70a1ea Added debug logging. 2009-04-29 17:18:54 +00:00
gunnar_g a707c3805e Solving valgrind issues 2009-03-10 15:58:48 +00:00
gyboth a04940877b European cups. 2009-01-08 22:20:26 +00:00
gyboth 3919e51861 Fixture scheduling bugfix. 2008-12-28 10:31:06 +00:00
gyboth a76cae2a44 Week breaks introduced. 2008-12-26 15:59:46 +00:00
gyboth c3f2c238b8 Def improvements, Italian definition corrected. 2008-12-23 10:33:55 +00:00
gyboth fed258a749 Added custom round robin breaks to leagues and cups. 2008-12-14 10:37:10 +00:00
gyboth 23cfbb3f0c Added function name output when compiled with DEBUG. 2008-11-25 13:50:07 +00:00
gyboth 945c4d1093 Added league properties and changed league active status to property. 2008-11-24 11:16:36 +00:00
gyboth c48a361342 Adjusted table highlight colours for multiple tables. 2008-11-23 11:48:36 +00:00
gyboth b9415b186e Multiple tables for leagues feature completed. 2008-11-22 16:51:31 +00:00
gyboth a535439936 Added multiple tables for leagues. 2008-11-21 17:00:47 +00:00
gyboth 73d4cc6795 Added joined leagues to defs system (e.g. for US conferences). 2008-11-20 20:20:18 +00:00
gyboth 819358f291 Added two match weeks for leagues. 2007-02-17 12:06:30 +00:00
gyboth 8b539e28fe "Def system improvements." 2006-06-30 13:24:50 +00:00
gyboth 55c6a7546a "2.0.0" 2006-06-04 17:10:08 +00:00
gyboth 15ad0cbb01 "Job exchange, first buggy draft with lots of debugging output." 2005-12-01 11:50:54 +00:00
gyboth 6f61b20f96 "Minor bugfix in query_cup_begins." 2005-11-26 16:52:51 +00:00
gyboth fa0b06f39d "Randomise teams option added." 2005-10-20 15:45:00 +00:00
gyboth 53131dd2e9 "Switched most GStrings to gchar." 2005-10-09 09:35:44 +00:00
gyboth 63e471da3f "World cup first try." 2005-09-21 17:42:41 +00:00
gyboth 00ba7127c9 "Supernational league changes" 2005-09-19 21:13:36 +00:00
gyboth 08d169daf3 "Player skill system changed." 2005-09-14 21:16:22 +00:00
gyboth ce6564ef47 "Team definition system." 2005-06-21 13:33:16 +00:00
gyboth d8c8eee3c1 "-m Player name files, first and last names." 2005-06-01 18:19:02 +00:00
gyboth 367feec221 "League layer" 2005-05-24 18:31:07 +00:00
gyboth 745977466d Cup structure changes. 2005-05-06 16:35:19 +00:00
gyboth f87bb3130e Season stats done. Table arrows. 2005-05-02 14:39:30 +00:00
gyboth fd6e42af8e Promotion games, supercups (phew). 2005-04-14 19:07:25 +00:00
gyboth 903288474a Season end. 2005-04-13 13:01:59 +00:00
gyboth b5ccda8879 Minor fixes. 2005-04-09 19:18:28 +00:00
gyboth b26f5bd652 Resume option. 2005-04-06 11:14:34 +00:00
gyboth 323e24b52b Tables display implemented. Flags added. 2005-03-15 15:10:57 +00:00
gyboth 7e07d74abd Made some progress; removed editor gui. 2005-03-03 12:46:48 +00:00
gyboth 993e7b6ba2 Live game can be tested a bit now. 2005-01-09 20:21:22 +00:00
gyboth be3b94742f Finished loading of leagues and cups and generating of teams. 2004-12-30 16:48:19 +00:00
gyboth 7114381bfb Initial revision 2004-12-23 12:58:39 +00:00