Ive been making this map and i want to set the victory condition that you must kill the opposing players special unit. So when the special unit dies, your army looses the game. How do i set this condition and how do i set that special unit? sorry im kinda new at this.
Welcome to sc2mapster! Feel free to send me a PM if you need anything ;)
So you will want to make a variable to store your "special unit". You should have 2 variables- one for player 1's unit, and 1 for player 2's. Each of those variable should be "unit" variables.
Next, make a trigger. The event should be "unit dies". And then you would set the unit to your special unit for player 1. The events would be whatever you want to happen- like you could show a message saying "PLAYER 2 WINS!!". You would then make a 2nd trigger, but this one will have an event that runs when the 2nd unit dies.
I'm not sure how experienced you are- if you don't understand this feel free to send me a PM and I'll go into a more detailed explanation.
Rollback Post to RevisionRollBack
Feel free to Send me a PM if you have any questions/concerns!
First up, create 2 global variables, with the type "unit" (i'll refer to them with "p1 special" and "p2 special", but u can name them whatever you want). Leave their initial values to "no unit.
On the trigger your using to create the special units, add a set variable right after the "create ... for player 1" action. Make it read "set "p1 special" = Last created unit". Do the same after "create ... for player 2" only with "p2 special"
Make a new trigger, with the event "Unit Dies". Leave it on "Any Unit". Create an "If Then Else" action, and add a comparison to the "If". Change it to "triggering unit = p1 special". Then, add "end game in victory for player 2" and "end game in defeat for player 1" to the "Then"
Finally, just copy paste the "If Then" in the same trigger, change it to "p2 special", inverse the victory and defeat, and you should be good to go.
Lemme know if you ahve any problems, or need me to elaborate something:)
Ive been making this map and i want to set the victory condition that you must kill the opposing players special unit. So when the special unit dies, your army looses the game. How do i set this condition and how do i set that special unit? sorry im kinda new at this.
@softshell1984: Go
Welcome to sc2mapster! Feel free to send me a PM if you need anything ;)
So you will want to make a variable to store your "special unit". You should have 2 variables- one for player 1's unit, and 1 for player 2's. Each of those variable should be "unit" variables.
Next, make a trigger. The event should be "unit dies". And then you would set the unit to your special unit for player 1. The events would be whatever you want to happen- like you could show a message saying "PLAYER 2 WINS!!". You would then make a 2nd trigger, but this one will have an event that runs when the 2nd unit dies.
I'm not sure how experienced you are- if you don't understand this feel free to send me a PM and I'll go into a more detailed explanation.
@zeldarules28: Go
Could you give me a step by step process, or give me some more details? thanks
@softshell1984: Go
First up, create 2 global variables, with the type "unit" (i'll refer to them with "p1 special" and "p2 special", but u can name them whatever you want). Leave their initial values to "no unit.
On the trigger your using to create the special units, add a set variable right after the "create ... for player 1" action. Make it read "set "p1 special" = Last created unit". Do the same after "create ... for player 2" only with "p2 special"
Make a new trigger, with the event "Unit Dies". Leave it on "Any Unit". Create an "If Then Else" action, and add a comparison to the "If". Change it to "triggering unit = p1 special". Then, add "end game in victory for player 2" and "end game in defeat for player 1" to the "Then"
Finally, just copy paste the "If Then" in the same trigger, change it to "p2 special", inverse the victory and defeat, and you should be good to go.
Lemme know if you ahve any problems, or need me to elaborate something:)
sorry, i really dont even know how to do that, maybe step by step? I trying to do it but cant. thanks
@softshell1984: Go
DUDE YOUR IN LUCK!!!
Blizzard answered this themselves in their triggers section
http://us.battle.net/sc2/en/game/maps-and-mods/tutorials/trigger/
YOu should really read all their tutorials.
@rageofhell: Go
thanks man, really helped me out
@softshell1984: Go
Yeah Im really new to all this, Blizzard has 5 sections of tutorials, Read those they can really help you out.
Yeah, making map is soooo easy, effortless, every map should be free!!!