[SOLVED]AND & OR in Triggers

Posted on
Wed May 27, 2015 5:03 pm
george99 offline
Posts: 224
Joined: May 27, 2015

[SOLVED]AND & OR in Triggers

Right now from what I can tell, you can only set the conditions of a trigger to be all under 1 OR statement (any), or all under one AND statement (all).
It would be nice if I could combine multiple instances of this. For example:

Code: Select all
AND
        OR
              var A = true
              var B = false
              var C = false
        OR
              var D = true
              var E = true
              var F = false
       var G = true


In English, at least one of the 1st OR set must match. At least one of the 2nd set must match. var G must always be true.

I hope that is clear.

Posted on
Wed May 27, 2015 5:06 pm
george99 offline
Posts: 224
Joined: May 27, 2015

Re: AND & OR in Triggers

I should add that technically, I can probably accomplish this with multiple triggers and a lot of variables, however, it would be quite cumbersome. Much more convenient withing 1 trigger's condition.

Posted on
Wed May 27, 2015 11:11 pm
howartp offline
Posts: 4559
Joined: Jan 09, 2014
Location: West Yorkshire, UK

Re: AND & OR in Triggers

Have a look at the Docs under Conditions:

http://wiki.indigodomo.com/doku.php?id= ... conditions

There's a little-known solution for what you're asking by using the 'option' key when you click the + button to add a condition.

Posted on
Thu May 28, 2015 6:32 am
george99 offline
Posts: 224
Joined: May 27, 2015

Re: AND & OR in Triggers

Nice! Thanks.

Page 1 of 1

Who is online

Users browsing this forum: No registered users and 13 guests