Debugger stepping question

Just started using Construct 2? Post your questions here

Post » Mon Jun 02, 2014 5:49 am

Hi all. I recently bought a personal edition of C2 and am wading through the learning curve. So here's my first newbie question. :)

I have two actions that I want to execute in an event when two conditions are true. So I have an 'and' expression as below (which represents the single event). I have numbered each condition and action to help describe the order of events. The 'X' below indicates an inverted condition.

Code: Select all
1. System    | Enemy.Count <= 0                   3. BlackHole | Set Visible
2. BlackHole | X Is visible                       4. System    | Set StartSpaceship to 1

Values in debugger:
Code: Select all
Enemy (0)
BlackHole (1)
#0 ->Visible [1]

When I step to this event when debugging, the red dashed outline displays around the first condition (1), indicating the expression is evaluating. I click Next in the debugger and the red dashed outline then displays around the 'Set Visible' action (3) rather than on the next condition (which is FALSE at the time, verified in the Inspect window). So the order is 1-3-4 and I would expect 1-2 followed by next event (assuming first condition is TRUE). So, my actions are executed even when I don't think they should be.

What am I doing wrong?

Posts: 1,646
Reputation: 6,596

Return to Beginner's Questions

Who is online

Users browsing this forum: No registered users and 1 guest