Need help, by creating a Sub Menu | based on same layer

0 favourites
  • 7 posts
From the Asset Store
Game with complete Source-Code (Construct 3 / .c3p) + HTML5 Exported.
  • Hello everyone,

    to keep it short,

    I want to create subMenus based on the same layer, and just get into the center of screen with lerp.

    There are 3x "isMainside" (numbers): on start of layout they are set to 0.

    "isMainside = 1" (go to second page)

    "isMainside1 = 1" (go to third page)

    the problem is, when I activate the number from 0 to 1 the script rush through all instanses, as you can see in the Video.

    How do I stop the script rushing through all Instanses and just update the numbers once at a Time.

    Example:

    when Button A down, and isMainSide = 0 -> set isMainSide to 1 (activated(while activated it should move to second page))

    when Button A down, and isMainSide = 1, and isMainSide1 = 0 -> set isMainSide1 = 1 (go to third page)

    in the video you´re able to see what im talking about.

    Subscribe to Construct videos now

    I allready tried with boolean but boolean means it always trigger while activated.

    thanks for helping.

    hopefully its understandable what im talking about.

    The problem maybe is -> as long as the Button A is down, it rushes through. To bad there is no on button A pressed option.

    Tagged:

  • It's a little convoluted, couldn't you just use one variable and increase it for each page? Anyway to fix it you can have button A pressed as a top event, then the other logic can be included as sub events with Else, that way it will only check one at a time on the button press and not run through them all.

  • It's a little convoluted, couldn't you just use one variable and increase it for each page? Anyway to fix it you can have button A pressed as a top event, then the other logic can be included as sub events with Else, that way it will only check one at a time on the button press and not run through them all.

    thanks, I just clicked on add another condition and was wondering why on button pressed did not appear.

    fixed it for now with "wait for 0.01 seconds" but I will try on button pressed, now that I know it still there. ^^

    Im so sorry, couldnt handle this for 2 days now.

    Edit: tried with on button pressed, the problem is you cant add another condition. but works fine with wait for 0.01 sec.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • the issue isn't whether you used 'button is down' or 'on button pressed', you can use 'button is down' with trigger once but 'on button pressed' is better. On button pressed would still run through all the events and adding wait 0.01 seconds isn't a great fix. You can use Else to make sure it runs through only one of the actions and not all of them.

  • the issue isn't whether you used 'button is down' or 'on button pressed', you can use 'button is down' with trigger once but 'on button pressed' is better. On button pressed would still run through all the events and adding wait 0.01 seconds isn't a great fix. You can use Else to make sure it runs through only one of the actions and not all of them.

    like this?

    but an Error appears

  • Make sure the on button pressed is on its own at the top level, then add the other conditions as indented sub events

  • Make sure the on button pressed is on its own at the top level, then add the other conditions as indented sub events

    ah thanks, I got it.

    works fine, for everyone who also has this problem.

    Solution in pic.

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