Results 1 to 7 of 7

Thread: Can't get a simple "or" to work! And "or" is too short to search for on the forum.

Threaded View

  1. #1

    [Solved] Can't get a simple "or" to work

    I've tried "a or b" and "a || b", and neither one works. The game always treats the "or" like an "and." I've got a very, very simple setup here so that there is no possibility of doubt:

    Condition: this
    On Act.: x1 = true

    Condition: this
    On Act.: x2 = true

    Condition: x1 or x2
    On Act.: player setdamage 1

    I've even got x1 and x2 set up with text cues, so I know that x1 is firing when it is meant to and x2 is firing when it is meant to. And yet I do not die if I only fire x1, or only fire x2. I only die when I fire both x1 and x2. Why is "or" being perceived by the game as an "and"?

    ---------- Post added at 21:21 ---------- Previous post was at 21:17 ----------

    Update: Hmm, I think I can work around this by simply creating a second trigger identical to the first except for the condition.

    Condition: x1
    On Act.: player setdamage 1

    Condition: x2
    On Act: player setdamage 1

    But then, what is the "or" function for? And I rather need it for a more complex script: (objtown2reached1 or !alive pla1 or !spawn1) and (objtown2reached2 or !alive pla2 or !spawn2) and (objtown2reached3 or !alive pla3 or !spawn3) and (objtown2reached4 or !alive pla4 or !spawn4)

    ---------- Post added at 22:33 ---------- Previous post was at 21:21 ----------

    Update: Solved. I worked around it by creating many triggers with one condition each, instead of one trigger with many conditions. Many conditions and few activations. The problem is solved, but since "or" and || are too small for the search engine, there doesn't seem to be much point in this thread remaining in existence.
    Last edited by Echo38; May 28 2012 at 02:31.

Similar Threads

  1. CfgVehicles: overriding "accuracy", "camuflage" and "sensitivity"
    By fabrizio_T in forum ARMA 2 & OA : ADDONS - Configs & Scripting
    Replies: 4
    Last Post: Apr 18 2013, 19:21
  2. List of "Armed Assault 1" addons that work in "ArmA II" as well
    By Dr. Horrible in forum ARMA 2 & OA - ADDONS & MODS: COMPLETE
    Replies: 168
    Last Post: Apr 17 2013, 06:58
  3. Does "name" movein(position) "vehiclename" not work anymore?
    By Pd3 in forum ARMA 2 & OA : MISSIONS - Editing & Scripting
    Replies: 2
    Last Post: May 18 2012, 00:07
  4. Does the "Keys" folder stil "work"?
    By NoBrainer in forum ARMA 2 & OA - MULTIPLAYER
    Replies: 3
    Last Post: Oct 24 2009, 12:30
  5. Add "LAND", "Up" and "Down" actions to command menu
    By EricM in forum ARMA 2 & OA - SUGGESTIONS
    Replies: 4
    Last Post: Jul 4 2009, 19:01

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •