Page MenuHomeFeedback Tracker

Trigger looping in the preview without satisfying conditions
New, WishlistPublic

Description

I was looking for a trigger to end a cooperative mission: in this trigger i wanted to have ALL alive players in the perimeter of the trigger in order to launch the End of Mission; it was a sort of "Extraction" of the war zone.

So i made this (you will see few differences with STR part):
i created a BLUFOR player on a map (tested on Stratis in vanilla, and Sahrani through All In Arma Terrain Pack), i created a Flag in order to locate the Trigger, then i created a trigger, with a radius of 5m, i name it Trig1 (for the example) and set parameters as following:
Type: none
Activation: BLUFOR
Time: One Time (or repetition, it works too; and the trigger loops in "One Time")
Presence: "is present"
Condition: {(isPlayer _x) and (alive _x)} count playableUnits == {(isPlayer _x) and (alive _x)} count list Trig1;
On Act.: hint "test OK";
On Deact.: hint "test echec";
I've put an object (an oil puddle) out of the trigger zone to "see it"

When i launch Preview, the trigger is automatically activated, displaying "Test OK" on the top of the right of the screen. If a set "repetition" on the trigger and i step in the trigger zone, "Test echec" is displayed. {F24830}

Details

Legacy ID
1074587700
Severity
None
Resolution
Open
Reproducibility
Always
Category
Editor
Steps To Reproduce
  1. Launch Arma 3, in vanilla, or with any mod (tested with All In ArmA Terrain Pack v1.2.1)

2)Go to Mission Editor

  1. create a BLUFOR Player
  2. Create a Flag
  3. Create a trigger named Trig1 on the Flag; no sync, no group needed
  4. Set the radius of Trig1 on 5m (square or Circle)
  5. no timer
  6. no text
  7. Type: NONE
  8. Activation: BLUFOR
  9. One Time or Repetition (no influence on Looping Execution)
  10. "Is Present"
  11. condition: {(isPlayer _x) and (alive _x)} count playableUnits == {(isPlayer _x) and (alive _x)} count list Trig1;
  12. On Act.: hint "test OK";
  13. On Deact.: hint "test echec"; (like failed, in French)
  14. (optional) Add a musique to the event on Effect Tab, in order to hear the loop
Additional Information

This occures only in Preview mode: if i export this to MP mission then i launch it on a dedicated server, the phenomenon disappears and the trigegr works as expected.

Event Timeline

Vonrichter edited Additional Information. (Show Details)
Vonrichter set Category to Editor.
Vonrichter set Reproducibility to Always.
Vonrichter set Severity to None.
Vonrichter set Resolution to Open.
Vonrichter set Legacy ID to 1074587700.May 7 2016, 7:28 PM

playableUnits is returns a empty array when your in preview mode.

playableUnits returns correct value on a dedicated server; but can you explain WHY the trigger is excuted while conditions are NOT satisfied ? (in fact, i'm not in the trigger perimeter to satisfy the first condition: activation by Blufor)
The problem is not the return value of playableUnits, but the trigger's activation.
Or may i have misundestood the Condition Function, where it replaces conditions defined above (timer, side etc...) ?

Moreover, is it normal in preview mode to not be counted as playableUnit ? (in Preview mode, it would not be surprizing that PlayableUnits returns a value equals to 1; but returning an empty value is certainly surprizing)

PiepMGI added a subscriber: PiepMGI.Sep 3 2018, 6:40 PM

Probably an initialization sequence where 0 == 0
See: https://community.bistudio.com/wiki/Initialization_Order

Just add count allPlayers > 0 && ... in the condition field.