hand cursor on object does not always work

Get help using Construct 2

Post » Thu Feb 16, 2017 4:58 pm

I have a page with several buttons for a menu as well as a music button and a reset button.
For each of these I have the following code:

Mouse/cursor is over "object name here" /mouse/set cursor to Hand
System/else/Mouse/set cursor to normal

"object name here" - here of course I have the name of the element I want the cursor to show the hand on mouse over.

I also tried to use a family with the same code but it still does not work right:
The menu buttons get the hand cursor on mouse over
The Music and Reset buttons do not.

Why?
B
8
S
1
Posts: 86
Reputation: 618

Post » Thu Feb 16, 2017 5:20 pm

If you have several events like ...

Mouse/cursor is over "object name here" /mouse/set cursor to Hand
System/else/Mouse/set cursor to normal

.... that indeed can not work.

Say we have two of those events.

Mouse is over object 'A' > Hand
Else > normal

Mouse is over object 'B' > Hand
Else > normal

That first event makes it a 'Hand'. As expected.
But then it is not over 'B', so the second set it back to 'normal'.

One (1) family should work fine. Or, arrange them like this.

Mouse is over object 'A'
____ set 'Hand'.
Else
Mouse is over object 'B'
____ set 'Hand'.
Else
Mouse is over object 'B'
____ set 'Hand'.
Else
____Set 'Normal'
B
33
S
18
G
28
Posts: 2,493
Reputation: 20,950

Post » Thu Feb 16, 2017 5:55 pm

Thank you for taking the time to answer my question. :)
Mouse does not work and I think it is the else that is interfering with the rest. Let me try your idea and I will get back with you either way.
B
8
S
1
Posts: 86
Reputation: 618

Post » Thu Feb 16, 2017 6:00 pm

The family did not work but fantastic, your system works.
Man, this has driven me crazy for a while!
I think the else for each object just messed things up and thinking about it now, it makes sense.

You made my day!
B
8
S
1
Posts: 86
Reputation: 618


Return to How do I....?

Who is online

Users browsing this forum: No registered users and 17 guests