Jump to content
Sign in to follow this  
horton

OR factor

Recommended Posts

Herro Bohemia, whats up im here with a new question o-rah

Hah i've been fixing around with variables, this is what i've got.

1st presence trigger, group 1. Condition ' THIS ' onACT ' Ent1=True'

2nd presence trigger, group 2. Condition ' THIS ' onACT ' Ent2=True'

3rd presence trigger, group 3. Condition ' THIS ' onACT ' Ent3=True'

These triggers are grouped with the group it stands for.

then there is the merge kinda thing, i dont want 1 group to be the ones being able to activate this thing, either one of the 3 groups needs to be able to activate this.

Soo the last trigger is condition '((ent1) OR (ent2) OR (ent3));' onact 'HQ sidechat "blablabla";'

This doesn't work for me. Anyone smart enough to help me out ;) ?

This thing is made soo that if the mission doesnt have all the members in it, it will still finish if one of the groups reaches the target.

Thanks for anything, and in advance! :D

Share this post


Link to post
Share on other sites

In init.sqf or some objects init field do:

ent1 = false; ent2 = false; ent3 = false

Trigger Condition:

ent1 OR ent2 OR ent3

The game engine doesn't support lazy evaluation. Thus, even with OR condition, you need to make sure there are no undefined variables in it.

97447

1488320

Share this post


Link to post
Share on other sites

Im new to scripting, but okay.. Lazy evaluation?

Share this post


Link to post
Share on other sites

Well, the point is that the game engine will always check every single condition you have added with AND or OR. All of them has to return true or false always. If there is even one that doesn't, the condition is false.

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
Sign in to follow this  

×