Error with mouse click

Bugs will be moved here once resolved.

Post » Sun Aug 19, 2012 9:15 pm

I'm creating a vertical shoot-em-up and all is going well, I'm using the CTRL key to fire and I also want to be able to use the left mouse button. As soon as I add an 'or' condition for clicking the mouse to also fire I get the following error when running the game and pressing either CTRL or the left mouse button:

Javascript error!
TypeError: cur_act is undefined
http://localhost:50000/Sprite_plugin.js, line 1037

This is either a bug in Construct 2 or a problem in a third party plugin or behavior - please report it to the developer!


If I remove the mouse click everything is fine. Here's the capx: StarForce

I'm using Beta release r99 [paid version]. Does this happen for anyone else?Nickydude2012-08-19 21:15:58
B
72
S
25
G
9
Posts: 382
Reputation: 10,649

Post » Sun Aug 19, 2012 9:45 pm

@Nickydude

Here's a [temporary] fix: *.Capx

I basically put the actions into an inactive group called 'Fire', which when ctrl or LMB are pressed, it activates, runs events before deactivating. Put in a start of layout event also for safe measure.

The 'Or' function does work for this. But it didn't prior to me changing the events, so I say 'temporary' fix at the moment.

Hope this helps.

-Adam
B
85
S
31
G
14
Posts: 106
Reputation: 16,430

Post » Sun Aug 19, 2012 9:49 pm

Thanks Andeming, You're getting the error as well? Which browser are you using? I'm using FF 14.0.1. I assumed it would work simply using 'or', weird. Thanks for the temp fix, works great. Nickydude2012-08-19 21:51:12
B
72
S
25
G
9
Posts: 382
Reputation: 10,649

Post » Sun Aug 19, 2012 11:12 pm

@Nickydude

No worries. I was using Google Chrome, WinXP SP3. I'm not quite sure of what causes the bug with the 'OR' conditions, because it does work with some actions, but not with others.

Glad the temp fix works. All the best,

-Adam
B
85
S
31
G
14
Posts: 106
Reputation: 16,430

Post » Mon Aug 20, 2012 2:43 pm

Thanks for the report - there was a bug in the runtime and it should be fixed now!
Scirra Founder
B
359
S
214
G
72
Posts: 22,946
Reputation: 178,478

Post » Mon Aug 20, 2012 7:55 pm

No probs Ashley. :)
B
72
S
25
G
9
Posts: 382
Reputation: 10,649


Return to Closed bugs

Who is online

Users browsing this forum: No registered users and 1 guest