BUG: 'OR' not working

For questions about using Classic.

Post » Wed Jun 08, 2011 2:23 pm

[quote="Shindoh":3v652iba][quote="tulamide":3v652iba]There is an issue with 'or'. I think I found the possible reason for it some time ago, and wanted to work on it now that I started helping with Construct Classic development. But I currently don't have a pc, I can't work on it.

Here is the link describing the possible issue: [url:3v652iba]http://www.scirra.com/forum/viewtopic.php?f=3&t=7428[/url:3v652iba][/quote:3v652iba]
What's weird though, is when following the exact same steps I explain in the (updated) first post, the 'OR' event works, but it will start giving the error message, as soon as You put it into a Group.[/quote:3v652iba]

Yup, I noticed that as well. I had OR expressions on my game and they only worked when they weren't in a group.

Alternate method for OR right now: Have a function and call it in the two (or more) conditions, this prevents copy and paste of actions for each condition
"Construct 4 lets YOU make advanced games! (maybe)" Construct Classic - Examples Kit
B
86
S
28
G
13
Posts: 2,092
Reputation: 15,009

Post » Wed Jun 08, 2011 2:27 pm

I know, but I do think it has the same reason, the time units needed to evaluate the or'ed conditions. On the top level of the event tree it gives the impression of always working (although it does only work beginning with tick 2 (instead of tick 1).

I use the following image to explain it to myself:
Tick N: First condition is retrieved. Second is missing, so it can't be compared. Any call to the 'or' event will fail.
Tick N + 1: Second condition is retrieved. Both are present to compare. A call to the event will be successful.
Image
B
23
S
8
G
10
Posts: 1,820
Reputation: 8,242

Previous

Return to Help & Support using Construct Classic

Who is online

Users browsing this forum: No registered users and 3 guests