Go
Wc3C.net
»
Warcraft III Modding
»
Developer's Corner
»
General Development
»
Removing Invulnerable Units From the Game
Removing Invulnerable Units From the Game
08-02-2008, 10:41 AM
#1
Manee
Why wont this trigger work?
Trigger:
Main Structure Wipe Out
Events
Unit - Base Obelisk 0016 <gen> Dies
Unit - Base Obelisk 0023 <gen> Dies
Unit - Base Obelisk 0028 <gen> Dies
Conditions
Actions
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
(Triggering unit) Equal to Base Obelisk 0016 <gen>
Then - Actions
Player Group - Pick every player in Force1 and do (Actions)
Loop - Actions
Set Force1Units = (Units in (Playable map area) owned by (Picked player))
Unit Group - Pick every unit in Force1Units and do (Actions)
Loop - Actions
Unit - Make (Picked unit) Vulnerable
Unit - Remove (Picked unit) from the game
Else - Actions
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
(Triggering unit) Equal to Base Obelisk 0023 <gen>
Then - Actions
Player Group - Pick every player in Force2 and do (Actions)
Loop - Actions
Set Force2Units = (Units in (Playable map area) owned by (Picked player))
Unit Group - Pick every unit in Force2Units and do (Actions)
Loop - Actions
Unit - Make (Picked unit) Vulnerable
Unit - Remove (Picked unit) from the game
Else - Actions
If (All Conditions are True) then do (Then Actions) else do (Else Actions)
If - Conditions
(Triggering unit) Equal to Base Obelisk 0028 <gen>
Then - Actions
Player Group - Pick every player in Force3 and do (Actions)
Loop - Actions
Set Force3Units = (Units in (Playable map area) owned by (Picked player))
Unit Group - Pick every unit in Force3Units and do (Actions)
Loop - Actions
Unit - Make (Picked unit) Vulnerable
Unit - Remove (Picked unit) from the game
Else - Actions
this is suppose to remove all units(including the invulnerable ones) after an obelisk is destroyed
edit: nvm, problem solved
08-02-2008, 11:19 AM
#2
DioD
nested ForForce and ForGroup calls bugged, rebuild trigger to evoid this.
08-05-2008, 06:28 AM
#3
Pyrogasm
What he's saying is that you can't be sure "Picked Player" and/or "Picked Unit" will refer to the proper picked unit/player.