User Tools

Site Tools


designer_tutorials:tutorials:factories:territory_tracking_and_respawn

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
designer_tutorials:tutorials:factories:territory_tracking_and_respawn [2020/01/15 22:41]
Edward Nygma
designer_tutorials:tutorials:factories:territory_tracking_and_respawn [2020/01/17 22:31] (current)
Edward Nygma
Line 1: Line 1:
 Territory Tracking and Respawn Territory Tracking and Respawn
  
-{{:designer_tutorials:tutorials:factories:game.png|}}+{{:designer_tutorials:tutorials:factories:game.png?900|}}
  
  
 This tutorial lays out a combination of factory structures that work in tandem.  First let's get an idea of what we're trying to build. This tutorial lays out a combination of factory structures that work in tandem.  First let's get an idea of what we're trying to build.
  
-{{:designer_tutorials:tutorials:factories:game_lowerleft.png|}}+{{:designer_tutorials:tutorials:factories:game_lowerleft.png?600|}}
  
 The object of the game is to be the last player with units in play.  "In Play" refers to units within any territory marked 4 or 5 in the image above.  Each player will start with 2 units in each grid, as shown above (4 and 5).  When a unit is removed from the grid, it will respawn.  You may only spawn one unit per turn in each grid. The object of the game is to be the last player with units in play.  "In Play" refers to units within any territory marked 4 or 5 in the image above.  Each player will start with 2 units in each grid, as shown above (4 and 5).  When a unit is removed from the grid, it will respawn.  You may only spawn one unit per turn in each grid.
Line 20: Line 20:
  
  
-{{:designer_tutorials:tutorials:factories:game_t2.png|}}+{{:designer_tutorials:tutorials:factories:game_t2.png?600|}}
  
  
-This is little overwhelming, so let's break it down a bit, starting with T1.+These 3 territories are the basis for tracking system.  We'll make it a bit more complex laterbut let's start here.
  
-This is the capital city.  It allows you to be eliminated immediatelyand can be included in a continent to guarantee that it only applies to a specific player.+T2 functions as an On/Off switch.  It's either occupied or empty1 or 0, On or Off, True or False.
  
-It's going to start by doing something odd.  It's going to attempt to autocapture T2 with a +1>> We'll ignore that for now, and come back to it.+T1 is trying to turn it On and T4 is trying to turn it off.
  
-T2 exists as a True or False statement, or an On/Off switch.  If T2 is player occupied, it is On, if it is neutral it is Off.  T1 is trying to turn it on with the +1>>but we're still not quite ready for that.+When T2 is On, or occupied, it can be included in a continent that says "If the conditions indicated by T2 are Truethen this continent becomes active."
  
-T4 is the grid in which we're trying to track units.  If I own T4 territories, then I should NOT respawn If I own 1 or 0 T4 territories I should respawn.  +In our case, we want T2 to turn on when the player does NOT own T4. If the unit in T4 dies, activate the respawn continent.
  
-Now, if I have 2 territories in grid 4then I want to turn T2 OFF.  If I have territory in grid 4 I want to turn T2 ON.  If I have territories in grid 4, I want to turn T2 AND T3 on.+In order to do that we have T1 turn T2 Onbut if the player DOES own T4, turn T2 Off instead.  +1 -0.
  
-Now I have 3 states.  2 T4s = T2 OFFT3 OFF.  T4s = T2 ON, T3 OFF.  0 T4s = T2 ONT3 ON.+T1, the player's capitaloperates as a single-territory continent with a +autocapture factory(>>) with T2 as its target.  This attempts to turn T2 from to 1or Off to On.
  
-So T1 is trying to turn on T2 with +1>>, but we only want T2 on if we've lost units.  So if we haven't lost units, we have to counter that +1 trying to turn T2 on, so it stays off.+To offset this, we need to make T4 a -autocapture factory (>>) from T4 to T2.  Since T4 is accessible by multiple players, we need to include the player capital in this continent, so T4 T1 -1>> T2.
  
-So, if we have a unit in T4, we need to have it give -1>> to T2 to counter the +1>> from T1, so the net is 0, and T2 stays neutral.  So Continent = T1 (If this player) + T4 (Owns a unit on grid 4) = -1>> T2 (Keep T2 Of(f).+Now T2 is the target of 2 separate factories, +1 from the capital, and -1 from T4, so the bonuses cancel each other out, and T2 stays Off, neutral, with 0 units.
  
-T1 +1>> T2 <<-(T4 + T1)  = T2 stays off.+If you do NOT own territory T4, you no longer get the -1>> to T2, and as a result, the net bonus is +from T1, which grants ownership of T2.
  
-Now, if I lose all of my units in T4...  I no longer have any -1>> to prevent T1 from turning on T2... so it turns on.+{{:designer_tutorials:tutorials:factories:game_example.png?600|}}
  
-Now that T2 is on, I know that  I've lost units, and I can include T2 in continent that respawns a unit on the board!+If player owns T4: 
  
-Note: T2 has a -1 to itself, so that once you do respawn, it reverts to its default OFF state.+(T1) +1>> T2 <<-1 (T4+T1) = Off
  
-Let's include T3.+If the player does Not own T4, 
  
 +(T1) +1>> T2 = On
  
-{{:designer_tutorials:tutorials:factories:game_t3.png|}}+That means T2 only turns on, when the player loses ownership of T4, and it turns off if the player regains ownership of T4.
  
 +If you create a grid of territories that all have the T4 structure of (T1 + T4a) -1>> T2, (T1 + T4b) -1>> T2... then T2 will only turn on when the player no longer owns ANY territories in the grid.
  
-T3 is pretty much identical to T2, but it tracks if there are 2 unitsinstead of 1.+This happens because every T4 represents a -1, and your capital only ever gives +1.  The only time the T1 +1>> T2 outweighs the T4 opposite forces(T1 +T4n) -1>> T2 for each owned unit on the gridis when the number of T4 territories owned is 0.
  
-In order to do this T1 gives +2>> to T3.  So unless it gets two separate -1>> bonuses from two separate T4s, it will turn on.+The T2 -1> T2 sets the switch back to Off (its default state) if it turned on last turn.
  
 +Before we go much further into T2, let's expand this tracking system to track 2 units at once.  
 + 
  
-{{:designer_tutorials:tutorials:factories:game_lowerright.png|}}+{{:designer_tutorials:tutorials:factories:game_t3.png?600|}}
  
-{{:designer_tutorials:tutorials:factories:game_upperleft.png|}}+ 
 +Now we've added T3 to track a second unit.  Technically we're tracking territories, but with a max of 1 per territory, I call it tracking units. 
 + 
 +First we must consider that if we are tracking 2 units at a time, then T4 will now provide up to two separate -1>> T2 bonuses. 
 + 
 +If the bonus is -2, then the player has 2 territories in Grid 4.  If it's -1, one unit has been lost.  If there is no bonus (-0?), both units have been lost. 
 + 
 +To counteract that we send +2 from T1, instead of +1 like we do for T2.  Let's see what happens now. 
 + 
 +If the player has 2 units in T4: 
 + 
 +T1 +2>> T3, T4a -1>> T3, and T4b -1>> T3, for a net of 0 units, or Off. 
 + 
 +If the player has 1 unit in T4: 
 + 
 +T1 +2>> T3, T4a -1>> T3, for a net of +1 unit, or On. 
 + 
 +If the player has 0 units in T4: 
 + 
 +T1 +2>> T3, for a net of +2 units, but the territory has a max of 1, so it's On with 1 unit. 
 + 
 +So if the player has lost at least 1 unit, T3 will turn on. 
 + 
 +T2, now with only +1, will only turn on if the player owns no T4 territories. 
 + 
 +T1 +1>> T2 is only 1 or more if there is no T4 -1>> T2, or when the player has lost 2 units. 
 + 
 +No we can say, if the player has T3, he has lost at least one unit.  If the player has T2 AND T3, the player has lost both units. 
 + 
 +If the play has neither T2 or T3, the player has the expected 2 units still on the board. 
 + 
 + 
 +{{:designer_tutorials:tutorials:factories:game_lowerright.png?600|}} 
 + 
 + 
 +Spawn time!   
 + 
 +If the player owns T2, Take T8.  T2 +1>> T8. 
 + 
 +Oh, but if I already have T8, remove it.  T8 -1> T8.  Note: this can be standard (>) instead of autocapture (>>) because it only works if it's owned already. 
 + 
 +Since these bonuses and switch flipping happens when continent bonuses are registered, these changes are only made at the start of the player's turn. 
 + 
 +This means, when I lose a unit, at the start of my first turn with a unit missing, I take T2.  So it will take another turn before T2's continent will trigger.  This causes a difficult-to-explain delay. 
 + 
 +You can bypass this delay, by making T2 and T8 the same territory, so as soon as you capture T2, it can attack back to the board, like T8 can, instead of waiting for it to be used in a continent. 
 + 
 +In this case, I want the delay. 
 + 
 +Also, T8 has a maximum of 1 unit, and HAS to have a maximum of 1 unit for this very sensitive system to work... so you can only spawn one unit per turn with this system as is. 
 + 
 +This can also be changed, but I don't want to for this design. 
 + 
 +The above graphic shows two spawns.  T2 and T6 are essentially identical, just T6 tracks Grid 5, just as T2 tracks Grid 4 in this design. 
 + 
 + 
 +{{:designer_tutorials:tutorials:factories:game_upperleft.png?600|}} 
 + 
 +Here's the whole system.  T1 gives tries to turn on T2 and T3 with +1>> and +2>> The occupied T4 territories each thrown -1>> at them, and it's replicated to track Grid 5. 
 + 
 +Now we have a system that tracks up to two units on two separate grids, and respawns when you have at least 1 unit missing.  Copy Paste, Find and Replace //**"(P1 territory ID), **// with T2 territory ID, and repeat for T3,6,7,8,9 and now you're doing it for multiple players. 
 + 
 +Now we just need a win condition. 
 + 
 +{{:designer_tutorials:tutorials:factories:game_win.png?600|}} 
 + 
 +The way our system works says that if a player has lost 1 unit in Grid 4, T3 turns on.  If they lose both units, T2 turns on.   
 + 
 +So if the player has both, then they have no units on Grid 4.  T6 and T7 means no units on Grid 5 either... 
 + 
 +If the player has all 4, they have no units left at all, and are eliminated by giving -1>> to their own capital and involuntarily surrendering. 
 + 
 +Technically you can drop T2 and T6 from this continent... but I don't want to update the graphic at the moment. 
 + 
 +Questions, comments, concerns?  Let me know!
  
designer_tutorials/tutorials/factories/territory_tracking_and_respawn.1579146067.txt.gz · Last modified: 2020/01/15 22:41 by Edward Nygma