Or condition possible?

Discussion and feedback on Construct 2

Post » Sat Feb 11, 2012 1:27 pm


Hi,
i've a simple question:
Is it possible to make an or Condition in C2?

When a variable has the values 0,1,2 and I want a condition like that:

if (variable= 1 or variable =2) --> Actions

What i usually then do is to invert the condition:
if not (variable = 0) -> Actions

Is there a way to make this with or?

Thanks,
Joe7Joe72012-02-11 13:28:58
B
14
S
7
G
5
Posts: 173
Reputation: 4,802

Post » Sat Feb 11, 2012 1:33 pm

Adding an 'OR' event has been on our todo list for a while, but if the only possible values are 0, 1 and 2, then "variable is greater than 0" is a perfectly standard way of testing if it's 1 or 2.
Scirra Founder
B
414
S
245
G
92
Posts: 25,203
Reputation: 200,347

Post » Sat Feb 11, 2012 1:37 pm

Thanks for the very quick reply.
No problem to work around but i still wanted to know if theres a hidden feature.

Joe7
Joe72012-02-11 13:38:31
B
14
S
7
G
5
Posts: 173
Reputation: 4,802


Return to Construct 2 General

Who is online

Users browsing this forum: Dellaclearing, gabrielsantana22, marks2 and 0 guests