One trigger condition will never take priority over another and there are a lot of paradoxes like this. What you need to do is make sure that the first trigger in the list is the one that checks if two units has died and creates a unit. Since the actions of this trigger will make the conditions of the next false again, the second will never know the difference. Also in contradictory to what Mini Moose said a trigger CAN fire before another is finished. Every trigger that has a wait in it causes all the rest of the triggers to check there conditions and run there actions before it completes. It is the base of the hyper trigger that we all love so much, and the unknown evil that many of use curse about when we have things that “should happen”, but don’t. Anyways to keep it simple Helios do this
First trigger (trig that replaces your units) Just make sure you have no waits in this trigger, if you do make sure there after you create the unit.
Conditions:
-Current player Suffers at least two deaths of “unit”
Actions:
-Set Deaths of “unit” for current player to subtract 2
-Create one unit at location for current player
-Display text “Muhahaha Half of us live again. . .”
-Preserve Trigger
Second Trigger (defeat)
Conditions:
-Current command exactly 0 unit
Actions:
-End game in Defeat for current player
-Display Text “Muhahaha did you think you were going to get a half a man, loser”
Note: Display text is for humor and I would suggest you do not use ither of those messages in your mapAnyways back to what I was talking about (
Helios you can quit reading now)
The wait trigger is by far the most complex trigger in StarEdit. And it takes a real expert to even agree with me. I have done hours of research on them and finally I believe I understand almost every aspect of it. Including how hyper triggers work and function in extreme detail. So much detail in fact that not only tell you how and why they work, when they effect your other waits or not but the actual order than every single wait will fire and how many times.
Anyways although waits are confusing I find the majority of unrealized errors is due unrealized trigger order. For example The great misfunctional music loop . . .
Players: Computer player
Conditions: Switch is set
Actions: Wait XXXX / Clear switch
Players: Force 1
Conditions: Switch is clear
Actions: Play wav / Set switch.
This trigger only works for one player, and many people don’t realize it till its too late (cause most people test as P1). What people fail to realize is that a trigger for “force 1” or “all players” is NOT one trigger, It is actually several triggers ran independently owned by all the respective players. Because the trigger is owned by multiple players and ran independently when the first player runs the trigger the music will start and the switch will set. Then it checks the next player and the switch is no longer clear so they never hear the music.
Of course this isn’t only true with music it is also commonly noticed in display text, and center screens. And there are also other forms of misconception caused by triggers owned by Forces and All players like the Infamous [url=Createing units in Multiplayer]
http://www.staredit.net/?showtutorial=8[/url] stated here by our beloved Yoshi da Sniper. But this tutorial is total crap and only makes the situation worse. It barely addresses the issue at all but instead makes a sinless formula only to send us father into the realm of the evil that is the ignorance to triggers. There are many other situations almost all have the same problem but I’ll quit talking about them to avoid offending Yoshi, confusing people, and lack of personal sleep.
End the end of my post I wonder how many of you are still with me, or even care. But if only 1 or 2 people understood what I said and understood it then it is a major accomplishment for me. Merry Christmas, and Happy New Year.