Defeat trigger bug..

Sivert

New Member
Reaction score
0
Jeg have this trigger so one loses when this "main building" dies..
Code:
Events
 unit -  a unit dies
Conditions
 (Number of living Main Building units owned by (Owner of (Triggering unit)))                 equal to 0
Action
 Game - defeat (owner of (dying unit)) with the message : Defeat!

I'v bin testing it.. it works - You get the message defeat when you lose dont have anymore of the main building, but when I'v played with more players, some of them just die, early in the game WITH their main building intact.... Anyone know what to do.. ?
 

Exide

I am amazingly focused right now!
Reaction score
448
How about changing the condition to:

Unit Type of (Dying unit) equal to 'Main Building'
 
H

Hjalle

Guest
Code:
 (Number of living Main Building units owned by (Owner of (Triggering unit)))
um, this condition doesn't do anything?

And yes, change dying unit to trigger unit.
 

Exide

I am amazingly focused right now!
Reaction score
448
If you scroll to the right, you'll see the complete condition, Hjalle. :)
 
H

Hjalle

Guest
Rofl, why is it over there? :p

Anyway, as I said before. Change the (owner of (dying unit)) to (owner of (triggering unit))
 

Exide

I am amazingly focused right now!
Reaction score
448
Why change the (owner of (dying unit)) to (owner of (triggering unit))?

-Yes, they both work. But dying unit should answer better to the event 'A unit Dies', imo. Also, since they both work, there's no reason to change, right?
 
H

Hjalle

Guest
Well, dying unit can get overlapsed if another unit dies before the action is run.
Triggering unit won't do this.

Even thought i think this trigger should work, but thats the first thing i noticed that he could change.
 

Exide

I am amazingly focused right now!
Reaction score
448
I was wondering about that..

What if I have a trigger such as:

Code:
Stupid Trigger
    Events
        Unit - A unit Dies
    Conditions
    Actions
        Wait 80.00 seconds
        Unit - Create 1 (Unit-type of (Triggering unit)) for (Owner of (Triggering unit)) at (Player 1 (Red) start location) facing Default building facing degrees

What would happen if two or more units die, within these 80 seconds of waiting? Would it "ruin" the trigger, or would each dying unit "get their own trigger, and wait"?
 

AceHart

Your Friendly Neighborhood Admin
Reaction score
1,495
With the event "a unit dies", both "triggering unit" and "dying unit" are perfectly save to use. Even after waiting.

Note though that dead units other than Heroes only stay around for some 90 seconds, at which point the game removes the unit.
 

Faust

You can change this now in User CP.
Reaction score
123
Note though that dead units other than Heroes only stay around for some 90 seconds, at which point the game removes the unit.
The decay time? That can be set in gameplay constants.
 
General chit-chat
Help Users
  • No one is chatting at the moment.

      The Helper Discord

      Members online

      No members online now.

      Affiliates

      Hive Workshop NUON Dome World Editor Tutorials

      Network Sponsors

      Apex Steel Pipe - Buys and sells Steel Pipe.
      Top