How do I Show and Hide Menu

0 favourites
  • 8 posts
From the Asset Store
A well commented template with list menus and shops to use in your top-down RPGs or metroidvania games!
  • Hello!

    I am trying to show and hide a menu while the game is running. The thing is that the images aren't changing everytime the player is touching the sprites. Seems like some spots on the image aren't sensitive to touch. Perhaps the PNG alpha? Once in a while it does work.

    I have attached an image of the eventsheet.

    Thanks!

  • Hence, the images are on top of each other, same layer.

  • The sprites are still there, whether they are visible or not, so they are both getting the touch event. You are better off using frames on one sprite and changing the frames.

  • Hi Blackhornet! Thanks and it really works. But... what if I have menu-itens while the menu is on?

    Tried that.. but if I touch, for instance, the Music button, the music event is triggered and the menu frame also changes.

  • You just need to combine the actions and check more state to process and ignore as appropriate.

  • Followed your example. But what if Sprite2 (the blue one) is also used to go back to the previous stage?

    Cause in your example "SoundOnOff" are not overlapping "Sprite2". You are using an external button to show/hide the menu.

    In my project I have 3 buttons and 2 menu sprites. If only I could disable objects or enable sprites to catch touches following Z order as priority.

  • Followed your example. But what if Sprite2 (the blue one) is also used to go back to the previous stage?

    Cause in your example "SoundOnOff" are not overlapping "Sprite2". You are using an external button to show/hide the menu.

    In my project I have 3 buttons and 2 menu sprites. If only I could disable objects or enable sprites to catch touches following Z order as priority.

    Well, you could just make 4th button that would be opening and closing the menu, where the arrow in your examples is. Simple, and actually more ux friendly.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • You're right Megatronx! Why make it easy if we can make it harder? lol .. keep it simple! =)

    Thank you guys!

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