-
Notifications
You must be signed in to change notification settings - Fork 22
Phase Management (outdated)
Phase management From rails Jump to: navigation, search
Phase management is currently being refactored. The plan is to keep both the old and new ways to configure phases existing in parallel for a while, so that a gradual changeover is possible. The new game 18TN is used as a guinea pig; it is this game that has necessitated a newe approach to phase management.
The basic idea is to (almost) all phase-triggered changes to be configured with the phases; so far these were split between the phase and the train definitions. Three different configuration item types are under consideration:
-
New values for standard properties, such as which tile colours can be laid, is buying privates allowed, which off-board values apply, etc. All properties propagate from one phase to the next, unless changed explicitly. Nothing new here, this is already in place.
-
Actions to be executed immediately, such as rusting or obsoleting trains, making new trains available[1] , closing privates. Only the private-closing action already exists. The train-related actions are currently defined with the train types, and the idea is to move these to the phase definitions, if for consistency only.
-
Actions to be executed later, by setting a temporary (or perhaps permanent)condition. This would apply to the 18TN Civil War, and perhaps also to already existing delayed actions like the 18EU Final Minor Exchange Round, and the 1835 Prussian formation (triggering of these actions is now specially hardcoded). The Phase class would only need a generic mechanism to set such conditions (probably just strings), the detection, execution, and resetting will always be in game-specific code.
[1] Making the next train type available after buying the last train of a type would remain automatic by default. It would be silly to start defining subphases for that purpose. Only exceptions to this rule may need to be configured. Completed
The below changes have been programmed, but only the 18TN and 1856 configurations have been adapted yet. For other games (like 1830) the old methods still work.
New rusted and released attributes for <Trains> under <Phase>. Example (1856):
which replaces (1830):
<TrainType name="6" ... rustedTrain="3" releasedTrain="D">
New <NewPhase> tag under <Train> that allows starting a new phase on buying any train of a type. Example (18TN):
which replaces (1830):
<TrainType name="6" ... startPhase="6" ...>
To do
Planned on short term:
Train limits per company
Conditions (such as the 18TN Civil War: a setting per company)
See below for reminders and suggested extensions to be implemented sooner or later. Suggestions and things to remember
By Volker Schnell: Some train specials from OO-Games 1844, Switzerland, private company Nr. 7 owns a train (5h) which can assigned to a company with a trainslot and run it in its first operating round 1844, Regional-company can acquire only h-Trains. 1844, when the first 3-train is bought, all 2 Trains became 2h-Trains (3 to 3h with 5 train, 4 to 4h with 6-Train, 5 to 5h with 8-Train) 1853, lookout version, if opening of small companies (nr.(5),6,7,8) occurs, all 6 2 Trains became 7 2/1M Trains, a 2M and a 3M Train are added.
if all 7 2/1M trains are bought before the first 3-Train, more 2/1M trains are available until the first 3-Train
big company (1-4 (5)) can't buy 1M-Trains.
18C2C, Merged company have 2 Lok-Shells, 1824/1837 Austria, coal company can only own G-Trains 1880 2R (restaurated 2 Trains, which take a trainslot but are not sufficient for the lok duty 1880, China, private has the right, to take an actual train before the company run, or when it is closed with the first 4-Train, take the second 4-train.
at this moment appointment to a company with no free trainslot is possible, just throw away an older one.
if no appointment is possible, the 4-train is gone
By Scott Petersen:
I think the only other game with a half phase is 18Mex--it is a well-liked game and I expect that there is significant player interest in it. 1880 has the special rule that a Stock Round is executed when the last train of a rank is purchased (there is another condition too--no train purchased since the company last ran). There are probably lots of examples of delayed actions that could be done as in your case 3.
Note that for the 18TN Civil War, each company needs a temporary condition which is removed once it runs with the Civil War run (non-counted train). I've not played it enough to know, but I think due to stock price movement, the Civil War might not all happen sequentially. For example, if it is triggered shortly before an SR and a company runs it's CW run before the SR, then the SR has stock price movement, the company that already did a CW run might run before one that has not done its CW run.
By John David Galt:
[type 1] Some others that deserve mention: which set of rules apply to financing of major companies started in this phase (1856, 18EU); which map areas are off limits for running (1835) and/or building (1837); whether loans are available.
In the case of new train limits I would declare the new limit here, but make enforcing it (discarding the trains) a separate action of type 2 or 3, since the timing varies by game. (1835 requires each minor to discard excess trains before Pr formation can begin, but 1856 and 18MEX allow CGR/NdM to wait and see which companies are going to merge into them before deciding which trains to keep.)
[type 2] Agree, and let's add some more: removing tiles and tokens from newly off- limits map areas (1837); making automatic tile placements (also 1837, but this is how I would implement changes to red-area payouts and similar);
[note 1] Here I disagree. Take 1853. Yes, the last 2 train makes 3 trains available, and so on; but the last 2M train does not necessarily make 3M trains available immediately. Both the last 2M and the first 4 must be purchased to make a 3M available, and so on. G trains in 1837 also work this way.