Hey guys...
i need your help
i made an arena system for my map which should do the following :
-when the arena timer expires pause all units and make them invurnable
-choose one of 3 types of arena fighting
-move the heroes to the arena
-let them fight
-checking whether heroes/units die
-if all teams are finished or in arena type 3 one team of heroes died it should show a message and port every hero back and unpause all units and and make them invurnable again
here the triggers making problems:
so the problems are:
-the triggers do not see whether the fights are over
-all the stuff that should happen after that does not happen (porting back, giving gold etc)
hope someone can help me
thanks in advance
greetz happy
i need your help
i made an arena system for my map which should do the following :
-when the arena timer expires pause all units and make them invurnable
-choose one of 3 types of arena fighting
-move the heroes to the arena
-let them fight
-checking whether heroes/units die
-if all teams are finished or in arena type 3 one team of heroes died it should show a message and port every hero back and unpause all units and and make them invurnable again
here the triggers making problems:
Trigger:
- arena creeps check
- Events
- Time - ArenaTimer expires
- Conditions
- Arena_Boolean Equal to True
- Actions
- If (All Conditions are True) then do (Then Actions) else do (Else Actions)
- 'IF'-Conditions
- Arena_IntegerType Equal to 1
- 'THEN'-Actions
- If (All Conditions are True) then do (Then Actions) else do (Else Actions)
- 'IF'-Conditions
- (Arena_Heroes[1] is dead) Equal to True
- 'THEN'-Actions
- Set hero_died[1] = Arena_Heroes[1]
- Set heaven_done = True
- Spiel - Display to (All players) the text: Heaven's Hero died....
- Set TempGroup = (Units in edge L <gen>)
- Unit Group - Pick every unit in TempGroup and do (Actions)
- Loop - Actions
- Unit - Remove (Picked unit) from the game
- Loop - Actions
- Custom script: call DestroyGroup(udg_TempGroup)
- 'ELSE'-Actions
- If (All Conditions are True) then do (Then Actions) else do (Else Actions)
- 'IF'-Conditions
- heaven_done Equal to True
- 'THEN'-Actions
- 'ELSE'-Actions
- Set arena_heaven = edge L <gen>
- If (All Conditions are True) then do (Then Actions) else do (Else Actions)
- 'IF'-Conditions
- (Number of units in (Units in arena_heaven owned by Neutral Hostile)) Greater than/Equal to 1
- 'THEN'-Actions
- Custom script: call RemoveRect (udg_arena_heaven)
- 'ELSE'-Actions
- Set heaven_done = True
- Game - Display to (All players) the text: Heaven finished all...
- Custom script: call RemoveRect (udg_arena_heaven)
- Game - Display to (All players) the text: (Each Player of Team Heaven got |cffFFC125 + ((String((500 x Creep_Number))) + |r Gold.))
- Player Group - Pick every player in (All allies of Spieler 1 (Rot)) and do (Actions)
- Loop - Actions
- Player - Add (500 x Creep_Number) to (Picked player) Gold
- Loop - Actions
- 'IF'-Conditions
- 'IF'-Conditions
- If (All Conditions are True) then do (Then Actions) else do (Else Actions)
- 'IF'-Conditions
- If (All Conditions are True) then do (Then Actions) else do (Else Actions)
- 'IF'-Conditions
- (Arena_Heroes[2] is dead) Equal to True
- 'THEN'-Actions
- Set hero_died[2] = Arena_Heroes[2]
- Set hell_done = True
- Game - Display to (All players) the text: Hell's Hero died......
- Set TempGroup = (Units in edge R <gen>)
- Unit Group - Pick every unit in TempGroup and do (Actions)
- Loop - Actions
- Unit - Remove (Picked unit) from the game
- Loop - Actions
- Custom script: call DestroyGroup(udg_TempGroup)
- 'ELSE'-Actions
- If (All Conditions are True) then do (Then Actions) else do (Else Actions)
- 'IF'-Conditions
- hell_done Equal to True
- 'THEN'-Actions
- 'ELSE'-Actions
- Set arena_hell = edge R <gen>
- If (All Conditions are True) then do (Then Actions) else do (Else Actions)
- 'IF'-Conditions
- (Number of units in (Units in arena_hell owned by Neutral Hostile)) Greater than/Equal to 1
- 'THEN'-Actions
- Custom script: call RemoveRect (udg_arena_hell)
- 'ELSE'-Actions
- Set hell_done = True
- Game - Display to (All players) the text: Hell finished all t...
- Custom script: call RemoveRect (udg_arena_hell)
- Game - Display to (All players) the text: (Each Player of Team Hell got |cffFFC125 + ((String((500 x Creep_Number))) + |r Gold.))
- Player Group - Pick every player in (All allies of Spieler 7 (Green)) and do (Actions)
- Loop - Actions
- Player - Add (500 x Creep_Number) to (Picked player) Gold
- Loop - Actions
- 'IF'-Conditions
- 'IF'-Conditions
- If (All Conditions are True) then do (Then Actions) else do (Else Actions)
- 'IF'-Conditions
- If (All Conditions are True) then do (Then Actions) else do (Else Actions)
- 'ELSE'-Actions
- If (All Conditions are True) then do (Then Actions) else do (Else Actions)
- 'IF'-Conditions
- Arena_IntegerType Equal to 2
- 'THEN'-Actions
- If (All Conditions are True) then do (Then Actions) else do (Else Actions)
- 'IF'-Conditions
- (Arena_Heroes[1] is dead) Equal to True
- 'THEN'-Actions
- Set Arena_IntegerType2 = 1
- Set hero_died[Arena_IntegerType2] = Arena_Heroes[1]
- If (All Conditions are True) then do (Then Actions) else do (Else Actions)
- 'IF'-Conditions
- (Arena_Heroes[2] is dead) Equal to True
- 'THEN'-Actions
- Set Arena_IntegerType2 = 2
- Set hero_died[Arena_IntegerType2] = Arena_Heroes[2]
- 'ELSE'-Actions
- 'IF'-Conditions
- If (All Conditions are True) then do (Then Actions) else do (Else Actions)
- 'IF'-Conditions
- Arena_IntegerType2 Equal to 1
- 'THEN'-Actions
- Game - Display to (All players) the text: A Hero of Team Heav...
- 'ELSE'-Actions
- If (All Conditions are True) then do (Then Actions) else do (Else Actions)
- 'IF'-Conditions
- Arena_IntegerType2 Equal to 2
- 'THEN'-Actions
- Game - Display to (All players) the text: Another Hero of Tea...
- Set heaven_done = True
- Set TempGroup = (Units in CreepsArenaHeavenTotal <gen>)
- Unit Group - Pick every unit in TempGroup and do (Actions)
- Loop - Actions
- Unit - Remove (Picked unit) from the game
- Loop - Actions
- Custom script: call DestroyGroup(udg_TempGroup)
- 'ELSE'-Actions
- 'IF'-Conditions
- If (All Conditions are True) then do (Then Actions) else do (Else Actions)
- 'IF'-Conditions
- 'ELSE'-Actions
- If (All Conditions are True) then do (Then Actions) else do (Else Actions)
- 'IF'-Conditions
- heaven_done Equal to True
- 'THEN'-Actions
- 'ELSE'-Actions
- Set arena_heaven = CreepsArenaHeavenTotal <gen>
- If (All Conditions are True) then do (Then Actions) else do (Else Actions)
- 'IF'-Conditions
- (Number of units in (Units in arena_heaven owned by Neutral Hostile)) Greater than/Equal to 1
- 'THEN'-Actions
- Custom script: call RemoveRect (udg_arena_heaven)
- 'ELSE'-Actions
- Set heaven_done = True
- Game - Display to (All players) the text: Team Heaven finishe...
- Custom script: call RemoveRect (udg_arena_heaven)
- Game - Display to (All players) the text: (Each Player of Team Heaven got |cffFFC125 + ((String((250 x Creep_Number))) + |r Gold.))
- Player Group - Pick every player in (All allies of Spieler 1 (Red)) and do (Actions)
- Loop - Actions
- Player - Add (250 x Creep_Number) to (Picked player) Gold
- Loop - Actions
- 'IF'-Conditions
- 'IF'-Conditions
- If (All Conditions are True) then do (Then Actions) else do (Else Actions)
- 'IF'-Conditions
- If (All Conditions are True) then do (Then Actions) else do (Else Actions)
- 'IF'-Conditions
- (Arena_Heroes[3] is dead) Equal to True
- 'THEN'-Actions
- Set Arena_IntegerType3 = 1
- Set hero_died[Arena_IntegerType3] = Arena_Heroes[3]
- If (All Conditions are True) then do (Then Actions) else do (Else Actions)
- 'IF'-Conditions
- (Arena_Heroes[4] is dead) Equal to True
- 'THEN'-Actions
- Set Arena_IntegerType3 = 2
- Set hero_died[Arena_IntegerType3] = Arena_Heroes[4]
- 'ELSE'-Actions
- 'IF'-Conditions
- If (All Conditions are True) then do (Then Actions) else do (Else Actions)
- 'IF'-Conditions
- Arena_IntegerType3 Equal to 1
- 'THEN'-Actions
- Game - Display to (All players) the text: A Hero of Team Hell...
- 'ELSE'-Actions
- If (All Conditions are True) then do (Then Actions) else do (Else Actions)
- 'IF'-Conditions
- Arena_IntegerType3 Equal to 2
- 'THEN'-Actions
- Game - Display to (All players) the text: Another Hero of Tea...
- Set hell_done = True
- Set TempGroup = (Units in CreepsArenaHellTotal <gen>)
- Unit Group - Pick every unit in TempGroup and do (Actions)
- Loop - Actions
- Unit - Kill (Picked unit)
- Loop - Actions
- Custom script: call DestroyGroup(udg_TempGroup)
- 'ELSE'-Actions
- 'IF'-Conditions
- If (All Conditions are True) then do (Then Actions) else do (Else Actions)
- 'IF'-Conditions
- 'ELSE'-Actions
- If (All Conditions are True) then do (Then Actions) else do (Else Actions)
- 'IF'-Conditions
- hell_done Equal to True
- 'THEN'-Actions
- 'ELSE'-Actions
- Set arena_hell = CreepsArenaHellTotal <gen>
- If (All Conditions are True) then do (Then Actions) else do (Else Actions)
- 'IF'-Conditions
- (Number of units in (Units in arena_hell owned by Neutral Hostile)) Greater than/Equal to 1
- 'THEN'-Actions
- Custom script: call RemoveRect (udg_arena_hell)
- 'ELSE'-Actions
- Set hell_done = True
- Game - Display to (All players) the text: Team Hell finished ...
- Custom script: call RemoveRect (udg_arena_hell)
- Game - Display to (All players) the text: (Each Player of Team Hell got |cffFFC125 + ((String((500 x Creep_Number))) + |r Gold.))
- Player Group - Pick every player in (All allies of Spieler 7 (Green)) and do (Actions)
- Loop - Actions
- Player - Add (500 x Creep_Number) to (Picked player) Gold
- Loop - Actions
- 'IF'-Conditions
- 'IF'-Conditions
- If (All Conditions are True) then do (Then Actions) else do (Else Actions)
- 'IF'-Conditions
- If (All Conditions are True) then do (Then Actions) else do (Else Actions)
- 'ELSE'-Actions
- For each (Integer A) from 1 to Arena_HeroesFight, do (Actions)
- Loop - Actions
- If (All Conditions are True) then do (Then Actions) else do (Else Actions)
- 'IF'-Conditions
- (Arena_Heroes[(Integer A)] is dead) Equal to True
- 'THEN'-Actions
- Set hero_died[(Integer A)] = Arena_Heroes[(Integer A)]
- Game - Display to (All players) the text: A Hero of Team Heav...
- Unit Group - Remove Arena_Heroes[(Integer A)] from ArenaHeroFightsGroup[1]
- If (All Conditions are True) then do (Then Actions) else do (Else Actions)
- 'IF'-Conditions
- (Number of units in ArenaHeroFightsGroup[1]) Greater than/Equal to Arena_HeroesFight
- 'THEN'-Actions
- 'ELSE'-Actions
- Unit Group - Remove all units from ArenaHeroFightsGroup[1]
- Unit Group - Remove all units from ArenaHeroFightsGroup[2]
- Set heaven_done = True
- Set hell_done = True
- Game - Display to (All players) the text: Team Hell won the d...
- Game - Display to (All players) the text: (Each Player of Team Hell got |cffFFC125 + ((String((1000 x Creep_Number))) + |r Gold.))
- Player Group - Pick every player in (All allies of Spieler 7 (Green)) and do (Actions)
- Loop - Actions
- Player - Add (1000 x Creep_Number) to (Picked player) Gold
- Loop - Actions
- 'IF'-Conditions
- 'ELSE'-Actions
- 'IF'-Conditions
- If (All Conditions are True) then do (Then Actions) else do (Else Actions)
- Loop - Actions
- For each (Integer A) from (Arena_HeroesFight + 1) to (Arena_HeroesFight x 2), do (Actions)
- Loop - Actions
- If (All Conditions are True) then do (Then Actions) else do (Else Actions)
- 'IF'-Conditions
- (Arena_Heroes[(Integer A)] is dead) Equal to True
- 'THEN'-Actions
- Set hero_died[(Integer A)] = Arena_Heroes[(Integer A)]
- Game - Display to (All players) the text: A Hero of Team Hell...
- Unit Group - Remove Arena_Heroes[(Integer A)] from ArenaHeroFightsGroup[2]
- If (All Conditions are True) then do (Then Actions) else do (Else Actions)
- 'IF'-Conditions
- (Number of units in ArenaHeroFightsGroup[2]) Greater than/Equal to Arena_HeroesFight
- 'THEN'-Actions
- 'ELSE'-Actions
- Unit Group - Remove all units from ArenaHeroFightsGroup[1]
- Unit Group - Remove all units from ArenaHeroFightsGroup[2]
- Set heaven_done = True
- Set hell_done = True
- Game - Display to (All players) the text: Team Heaven won the...
- Game - Display to (All players) the text: (Each Player of Team Heaven got |cffFFC125 + ((String((1000 x Creep_Number))) + |r Gold.))
- Player Group - Pick every player in (All allies of Spieler 1 (Red)) and do (Actions)
- Loop - Actions
- Player - Add (1000 x Creep_Number) to (Picked player) Gold
- Loop - Actions
- 'IF'-Conditions
- 'ELSE'-Actions
- 'IF'-Conditions
- If (All Conditions are True) then do (Then Actions) else do (Else Actions)
- Loop - Actions
- For each (Integer A) from 1 to Arena_HeroesFight, do (Actions)
- 'IF'-Conditions
- If (All Conditions are True) then do (Then Actions) else do (Else Actions)
- 'IF'-Conditions
- If (All Conditions are True) then do (Then Actions) else do (Else Actions)
- Events
Trigger:
- finished
- Events
- Time - CreepsArena_Timer expires
- Conditions
- Actions
- If (All Conditions are True) then do (Then Actions) else do (Else Actions)
- 'IF'-Conditions
- And - All (Conditions) are true
- Conditions
- heaven_done Equal to True
- hell_done Equal to True
- Conditions
- And - All (Conditions) are true
- 'THEN'-Actions
- Trigger - Turn on arena trigger <gen>
- Trigger - Turn on revival <gen>
- Trigger - Run port back and unpause <gen> (ignoring conditions)
- Set Arena_Boolean = False
- 'ELSE'-Actions
- Countdown-Timer - Start CreepsArena_Timer as a One-Shot timer that will expire in 0.10 seconds
- Countdown-Timer - Start ArenaTimer as a One-Shot timer that will expire in 0.10 seconds
- 'IF'-Conditions
- If (All Conditions are True) then do (Then Actions) else do (Else Actions)
- Events
Trigger:
- port back and unpause
- Events
- Conditions
- Actions
- Set Temp_Group = (Units in (Entire map))
- Unit Group - Pick every unit in Temp_Group and do (Actions)
- Loop - Actions
- Unit - Unpause (Picked unit)
- Unit - Make (Picked unit) Vurnable
- Loop - Actions
- For each (Integer A) from 1 to 12, do (Actions)
- Loop - Actions
- Unit Group - Pick every unit in Temp_Group and do (Actions)
- Loop - Actions
- If (All Conditions are True) then do (Then Actions) else do (Else Actions)
- 'IF'-Conditions
- (Picked unit) Equal to Arena_Heroes[(Integer A)]
- 'THEN'-Actions
- If (All Conditions are True) then do (Then Actions) else do (Else Actions)
- 'IF'-Conditions
- (Arena_Heroes[(Integer A)] is dead) Equal to True
- 'THEN'-Actions
- Set Temp_Point = (Center of item fuse over rank 2 til rank 4 <gen>)
- Hero - Instantly revive Arena_Heroes[(Integer A)] at Temp_Point, Hide revival graphics
- Custom script: call RemoveLocation (udg_Temp_Point)
- 'ELSE'-Actions
- 'IF'-Conditions
- Unit - Move (Picked unit) instantly to player_positions[(Player number of (Owner of (Picked unit)))]
- Set Arena_Heroes[(Integer A)] = No Unit
- If (All Conditions are True) then do (Then Actions) else do (Else Actions)
- 'ELSE'-Actions
- 'IF'-Conditions
- If (All Conditions are True) then do (Then Actions) else do (Else Actions)
- Loop - Actions
- Unit Group - Pick every unit in Temp_Group and do (Actions)
- Loop - Actions
- Set heaven_done = False
- Set hell_done = False
- Custom script: call DestroyGroup (udg_Temp_Group)
- Countdown-Timer - Start arena_timer as a One-Shot timer that will expire in 600.00 seconds
- Countdown-Timer - Create a timer window for (Last started timer) with title Arena starts in...
- Set timer_window = (Last created timer window)
- Trigger - Turn off arena creeps check <gen>
- Trigger - Turn off (This trigger)
so the problems are:
-the triggers do not see whether the fights are over
-all the stuff that should happen after that does not happen (porting back, giving gold etc)
hope someone can help me
thanks in advance
greetz happy