- Joined
- Feb 14, 2008
- Messages
- 289
i am working on a map (no duh) and i have all of the farm, tower, town, and barrack spawn locations for the beginning of the map set in arrays.
Farm[1-16]
Tower[1-16]
Town[1-4]
Barrack[1-4]
Also, there are 4 players which are supposed to gain these units.
Player[8-11]
Each player is supposed to gain 4 farms, 4 towers, 1 town, and 1 barracks.
now since there is supposed to be eventually multiple race choices, i am trying to minimize the head-ache with Integer A and B.
but the problem is at this point i cannot figure out what equation to use in order for it to place a farm in farm[1-4] for player 8, a farm in [5-8] for player 9, a farm in [9-12] for player 10, and a farm in [13-16] for player 10. this situation repeats itself for towers as well.
here is basically the trigger. ignore the cinematic and timer related things.
Farm[1-16]
Tower[1-16]
Town[1-4]
Barrack[1-4]
Also, there are 4 players which are supposed to gain these units.
Player[8-11]
Each player is supposed to gain 4 farms, 4 towers, 1 town, and 1 barracks.
now since there is supposed to be eventually multiple race choices, i am trying to minimize the head-ache with Integer A and B.
but the problem is at this point i cannot figure out what equation to use in order for it to place a farm in farm[1-4] for player 8, a farm in [5-8] for player 9, a farm in [9-12] for player 10, and a farm in [13-16] for player 10. this situation repeats itself for towers as well.
here is basically the trigger. ignore the cinematic and timer related things.
-
Game Start
- Events
- Conditions
-
Actions
- Cinematic - Turn cinematic mode Off for (All players)
- Camera - Pan camera for Player 1 (Red) to (Center of Evil Spawn 1 <gen>) over 0.00 seconds
- Camera - Pan camera for Player 2 (Blue) to (Center of Evil Spawn 2 <gen>) over 0.00 seconds
- Camera - Pan camera for Player 3 (Teal) to (Center of Evil Spawn 3 <gen>) over 0.00 seconds
- Camera - Pan camera for Player 4 (Purple) to (Center of Evil Spawn 4 <gen>) over 0.00 seconds
- Camera - Pan camera for Player 5 (Yellow) to (Center of Evil Spawn 5 <gen>) over 0.00 seconds
- Camera - Pan camera for Player 6 (Orange) to (Center of Evil Spawn 6 <gen>) over 0.00 seconds
- Camera - Pan camera for Player 7 (Green) to (Center of Evil Spawn 7 <gen>) over 0.00 seconds
- Camera - Pan camera for Player 8 (Pink) to (Center of Castle 1 <gen>) over 0.00 seconds
- Camera - Pan camera for Player 9 (Gray) to (Center of Castle 2 <gen>) over 0.00 seconds
- Camera - Pan camera for Player 10 (Light Blue) to (Center of Castle 3 <gen>) over 0.00 seconds
- Camera - Pan camera for Player 11 (Dark Green) to (Center of Castle 4 <gen>) over 0.00 seconds
- Camera - Pan camera for Player 12 (Brown) to (Center of Titan Spawn <gen>) over 0.00 seconds
- Countdown Timer - Start income_Timer as a Repeating timer that will expire in 20.00 seconds
- Countdown Timer - Create a timer window for (Last started timer) with title Income in...
- Countdown Timer - Start Sargeras_timer as a One-shot timer that will expire in 120.00 seconds
- Countdown Timer - Create a timer window for (Last started timer) with title Sargeras in...
-
For each (Integer A) from 1 to 7, do (Actions)
-
Loop - Actions
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
- Race_chosen_integ[(Integer A)] Equal to 0
-
Then - Actions
- Unit - Create 1 Void Summoner for Player[(Integer A)] at Evil_Spawn_point[(Integer A)] facing Default building facing degrees
- Else - Actions
-
If - Conditions
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
Loop - Actions
-
For each (Integer A) from 8 to 11, do (Actions)
-
Loop - Actions
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
- Race_chosen_integ[(Integer A)] Equal to 0
-
Then - Actions
- Unit - Create 1 Town Hall for Player[(Integer A)] at Town_point[((Integer A) - 7)] facing Default building facing degrees
- Unit - Create 1 Barracks for Player[(Integer A)] at Barrack_point[((Integer A) - 7)] facing Default building facing degrees
-
For each (Integer B) from 1 to 4, do (Actions)
-
Loop - Actions
- Unit - Create 1 Tower for Player[(Integer A)] at Tower_point[(Integer B)] facing Default building facing degrees
-
Loop - Actions
-
For each (Integer B) from 1 to 4, do (Actions)
-
Loop - Actions
- Unit - Create 1 Farm for Player[(Integer A)] at Farm_point[(Integer B)] facing Default building facing degrees
-
Loop - Actions
- Else - Actions
-
If - Conditions
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
Loop - Actions