- Joined
- Feb 22, 2015
- Messages
- 10
I'm currently making a Clash Royale-inspired map.
I tried to make it work like the original game; whenever you begin training a unit, it'll dissapear (unavailable for training) and a new one should show up available to train.
The problem is sometimes when I begin training a unit, it dissapears from training but the new unit doesn't become available to train.
These are the current triggers:
This one is to set the units available to train. By default, you can train Footman, Archer, Rifleman, and Mortar Team.
This one is to randomize the new unit available for training.
And this one: (Custom Spawn) I thought it might have something to do with it. What this trigger does is teleport the last trained unit to the exact spot where you put the rally-point before training.
If someone could please help me fix this problem, it would be very much appreciated.
Here's the link to my map in case you didn't understand how the gameplay works:
http://www.hiveworkshop.com/forums/maps-564/warcraft-royale-v1-0-4-a-276874
I tried to make it work like the original game; whenever you begin training a unit, it'll dissapear (unavailable for training) and a new one should show up available to train.
The problem is sometimes when I begin training a unit, it dissapears from training but the new unit doesn't become available to train.
These are the current triggers:
This one is to set the units available to train. By default, you can train Footman, Archer, Rifleman, and Mortar Team.
-
Events
-
Map initialization
-
-
Conditions
-
Actions
-
Set RandomUnit[1] = Footman
-
Set RandomUnit[2] = Archer
-
Set RandomUnit[3] = Rifleman
-
Set RandomUnit[4] = Mortar Team
-
Set RandomUnit[5] = Giant
-
Set RandomUnit[6] = Bandit
-
Set RandomUnit[7] = Spearman
-
Set RandomUnit[8] = Skeleton
-
Set RandomUnit[9] = Golem
-
Set RandomUnit[10] = Wizard
-
Set RandomUnit[11] = Baby Dragon
-
Set RandomUnit[12] = Knight
-
Player Group - Pick every player in (All players controlled by a User player) and do (Actions)
-
Loop - Actions
-
Player - Make RandomUnit[5] Unavailable for training/construction by (Picked player)
-
Player - Make RandomUnit[6] Unavailable for training/construction by (Picked player)
-
Player - Make RandomUnit[7] Unavailable for training/construction by (Picked player)
-
Player - Make RandomUnit[8] Unavailable for training/construction by (Picked player)
-
Player - Make RandomUnit[9] Unavailable for training/construction by (Picked player)
-
Player - Make RandomUnit[10] Unavailable for training/construction by (Picked player)
-
Player - Make RandomUnit[11] Unavailable for training/construction by (Picked player)
-
Player - Make RandomUnit[12] Unavailable for training/construction by (Picked player)
-
-
-
Wait 0.01 seconds
-
Trigger - Turn off (This trigger)
-
-
Events
-
Unit - A unit Begins training a unit
-
-
Conditions
-
Actions
-
Wait 0.01 seconds
-
Player - Make (Trained unit-type) Unavailable for training/construction by (Owner of (Triggering unit))
-
Player - Make RandomUnit[(Random integer number between 1 and 12)] Available for training/construction by (Owner of (Triggering unit))
-
-
Events
-
Unit - A unit Finishes training a unit
-
-
Conditions
-
Actions
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
-
(Owner of (Triggering unit)) Equal to Player 1 (Red)
-
-
Then - Actions
-
Set Temp_Unit_1 = (Trained unit)
-
Set Temp_Loc_1 = (Rally-Point of (Triggering unit) as a point)
-
Unit - Move Temp_Unit_1 instantly to Temp_Loc_1
-
Custom script: call RemoveLocation(udg_Temp_Loc_1)
-
-
Else - Actions
-
Do nothing
-
-
-
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
-
If - Conditions
-
(Owner of (Triggering unit)) Equal to Player 2 (Blue)
-
-
Then - Actions
-
Set Temp_Unit_2 = (Trained unit)
-
Set Temp_Loc_2 = (Rally-Point of (Triggering unit) as a point)
-
Unit - Move Temp_Unit_2 instantly to Temp_Loc_2
-
Custom script: call RemoveLocation(udg_Temp_Loc_2)
-
-
Else - Actions
-
Do nothing
-
-
-
If someone could please help me fix this problem, it would be very much appreciated.
Here's the link to my map in case you didn't understand how the gameplay works:
http://www.hiveworkshop.com/forums/maps-564/warcraft-royale-v1-0-4-a-276874