invisible button is clickable - when using touch

Get help using Construct 2

Post » Fri Jan 25, 2013 1:32 pm

Hello,

I am trying to make my game more smartphone / tablet friendly via adding touch actions to buttons.   

I have a 3 level game, the button to advance to level 2 is placed on the stage and is set to invisible to start.   

I added an is touching object to advance to level 2.   

When I drag characters around the stage, when it goes over the the location of the button it advances to level 2.   I only want the button active when it is displayed.

Any advice greatly appreciated.    

Thanks

Tim
B
4
Posts: 16
Reputation: 857

Post » Fri Jan 25, 2013 2:43 pm

Add an additional event/condition-

Button...is visible.

B
21
S
6
G
8
Posts: 1,215
Reputation: 7,881

Post » Mon Feb 18, 2013 5:48 am

Bug or feature?
B
8
S
3
G
2
Posts: 49
Reputation: 1,943

Post » Mon Feb 18, 2013 5:54 am

Invisible objects can be triggerd - they are invisible on screen but visible for events.
ImageImageImageImage
B
157
S
64
G
41
Posts: 2,590
Reputation: 34,640

Post » Tue Dec 08, 2015 6:10 am

Except with the mouse, the invisible objects are not triggered.
B
20
S
7
G
3
Posts: 302
Reputation: 3,634

Post » Tue Dec 08, 2015 11:59 pm

The touch triggers invisible events also @Phoenixbowman
B
8
S
2
Posts: 27
Reputation: 610


Post » Thu Dec 10, 2015 10:12 am

As @chrisbrobs said. Just add the condition "is visible" to the on touch event and the button will not be clickable while invisible.

Exmaple: On touched object - object is visible > go to layout X
B
52
S
22
G
12
Posts: 725
Reputation: 11,716


Return to How do I....?

Who is online

Users browsing this forum: tarek2 and 9 guests