Scrolling Menu: Make item clickable or non-clickable

Hello Guys,

I need your help.

Context:

  • I’m working on a Mobile game
  • In this game there are several menus (MAP, INVENTORY, UPGRADE, SHOP)
  • In the MAP MENU for example, you can scroll up and down

Problem :

  • I can’t make the Map menu buttons non-clickable when the user scrolls.

How I worked :
To save time, I’ve made a small recap to try and centralize information about this project:

  • how the scrolling area is created
  • what I’m trying to do
  • what I’ve already tried and what doesn’t work

Step1 :

Step 2 :

Step 3 :

Has anyone worked on something similar?
I’ve been stuck on this subject for several days and I’m going crazy :frowning:

Thanks for your help !

You could try to save the X and Y position of the cursor when you click, and if you stop clicking and the X and Y is the same, the button gets clicked.
Something like this:

When mouse button pressed, trigger once
Set variable X to CursorX()
Set variable Y to CursorY()

When mouse button is released, X=CursorX, Y=CursorY, trigger once
And whatever you want next

Hello Mikel,

thanks for your reply!
By rechecking the different ways of doing it, I was able to find a solution which consists of playing with the fact that the mouse button is down or release + a calculation of where the mouse clicks and if it has moved in the meantime.