Stop mouse clicks during Waits

0 favourites
  • 14 posts
From the Asset Store
Add calm and a lounge vibe to your games with these 8 tracks
  • Hi again!

    This time I'm in big trouble, I want to disable the mouse click during Waits. I tried this by making a Global Variable Set to FALSE before "waiting", and the TRUE after the "waiting". But that doesn't seem to work.

    Here's the example code. ClickReady (The Global Variable) is highlighted.

    <img src="http://img829.imageshack.us/img829/4234/mouseready.png" border="0">

    Please check my CAPICS HERE

  • You set the value of the variable to '1' both before and after the wait?

  • lonrotGame.capx

    I simplified some stuff too

  • Thanks Yann, you have saved me times already. I'm in the process of updating my newest version of the game with your cleaner code, I can set the local variable to IS Win but "not equal to" Win as you did in your version. What I'm missing?

    <img src="http://img707.imageshack.us/img707/520/notequalto.png" border="0" />

    EDIT: Found it, Right Click Invert.

  • I can't make the "loose" animation to show up, I have double checked and it should work to my end.

    NOTE: The loose animation is triggered only if Retry (Global Value) is set to 1.

    <img src="http://img252.imageshack.us/img252/8701/retryanimation1.png" border="0">

    Here's the updated CAPICS

    Please take a look <img src="smileys/smiley12.gif" border="0" align="middle">

  • There's something wrong with the link.

    Also when retry = 1 you start to play the animation, but you haven't actualy "Set animation" by its name.

    That's probably what's missing if all the rest should work as intended.

  • You have an operator for "is not equal to"

    instead of inverting the "System: Retry = 1" (don't know if it's the issue, the link is broken as Kyat said)

    And remember, your link must start with http:// for it to be properly clickable.

  • Link fixed!!

    Guys, I made both suggestions and it worked at some point, I can only see one frame of the entire animation and I suspect is the last frame. Tried various combinations but the animation remains frozen.

    That animation has worked perfectly until now.

    <img src="http://img535.imageshack.us/img535/2504/frozenanimation.png" border="0">

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • I know why your animation isn't playing but I have two question:

    1/ What do you want to use this retry for

    2/ Why didn't you keep what I did (using the fade behavior instead of manymanymany animation frame) ?

    (for the "why": adding 'trigger once' should avoid triggering the 'set animation from beginning' thus only showing the first frame every tick)

  • Hey Yann

    1) The framed animation repeated each time the ball collapsed, and my solution was to make the Boolean variable to avoid it.

    2) I really like your solution, but is not possible to make it blur and zoom just like the framed animation. I can sacrifice a few kilobytes for that.

    UPDATE: Trigger once, that's it! Thanks again Yann. One final thing, really! (I hope so). For some weird reason, the second time a ball is dropped, the Drop Icon becomes Green. Tried various things but I can't seem to get it right. For debugging purposes I set the Icon to Red(Wait) while the "Playing" variable is set to 1, and visceversa. Nothing changed thought.

    Here's the current CAPX. Yes the link is working. <img src="smileys/smiley32.gif" border="0" align="middle">

    <img src="http://img42.imageshack.us/img42/7588/dropiconproblem.png" border="0">

  • If I simplified your capx it was for me also... so I could better read it :D...

    Now it's a mess again. I am patient so I was cleaning it again but c2 crashed on me so... meh!

  • Sorry to hear that, hopefully you can get into it later :)

    You are quite right about using your cleaner code, I didn't use it because of all new the sounds and tweaks weren't there, and I went cold thinking about getting them back together <img src="smileys/smiley36.gif" border="0" align="middle" />

  • Yeah I thought that was something like that (:

    Well, I'll see during the day if I don't fall asleep /o/

  • Save it Yann, I just found out what the problem was. I had to put wait before Setting "Playing" Global Variable, in that way it won't change the icon after a new ball is being dropped. <img src="smileys/smiley41.gif" border="0" align="middle" />

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)