[Trigger] Dummy expiration triggers 'Unit dies' event

Status
Not open for further replies.
Level 5
Joined
Dec 25, 2018
Messages
110
I have a trigger which triggers whenever unit dies, I made condition
  • (Unit-type of (Dying unit)) Not equal to Dummy
But it still triggers...
Any fix for this?
(Killing player is always detected as player red, even if dummys owner was blue etc)
 
Last edited:
  • Unit dies
    • Events
      • Unit - A unit Dies
    • Conditions
      • Or - Any (Conditions) are true
        • Conditions
          • (Owner of (Dying unit)) Equal to Player 11 (Dark Green)
          • (Owner of (Dying unit)) Equal to Player 12 (Brown)
          • (Unit-type of (Dying unit)) Not equal to Dummy
    • Actions
      • Set EndGold[(Player number of (Owner of (Killing unit)))] = (EndGold[(Player number of (Owner of (Killing unit)))] + 8)
      • If (All Conditions are True) then do (Then Actions) else do (Else Actions)
        • If - Conditions
          • DebugIncome Equal to 1
        • Then - Actions
          • Game - Display to Player Group - Player 1 (Red) for 5.00 seconds the text: ((String((Player number of (Owner of (Killing unit))))) + ( + (String(EndRoundGold[(Player number of (Owner of (Killing unit)))]))))
        • Else - Actions
 
Last edited:
"Or" conditions work like that now if any one of those returns a value true, then the trigger will run. You have to move the (Unit-type of (Dying unit)) Not equal to Dummy out of the "Or" bracket and place it right under "Conditions". That way the conditions will look like:

If ((Unit-type of (Dying unit)) Not equal to Dummy == true) && (((Owner of (Dying unit)) Equal to Player 11 (Dark Green) == true) || ((Owner of (Dying unit)) Equal to Player 12 (Brown) == true))

if that makes sense to you.

In other words, the trigger conditions should look like this:
  • Conditions
    • (Unit-type of (Dying unit)) Not equal to Dummy
    • Or - Any (Conditions) are true
      • Conditions
        • (Owner of (Dying unit)) Equal to Player 11 (Dark Green)
        • (Owner of (Dying unit)) Equal to Player 12 (Brown)
 
Last edited:
Status
Not open for further replies.
Back
Top