Issue: Invisible objects are still clickable

Get help using Construct 2

Post » Wed Sep 04, 2013 8:13 am

I have a button sprite set to invisible. When I play the game, I am still able to click on it even though I can't see it. How do I disable clickability of the object?
B
58
S
19
G
3
Posts: 446
Reputation: 6,302

Post » Wed Sep 04, 2013 8:28 am

Add another condition with your click: Sprite is visible
B
17
S
8
G
4
Posts: 93
Reputation: 3,190

Post » Wed Sep 04, 2013 8:52 am

@c4sp3r89 He meant that he doesn't want his invisible objects to be clickable in any way. He can get them invisible just fine, but they can still be clicked in that state.

@jook00 Maybe try putting the buttons/UI elements you want to be fully unavailable in specific layers, then turn on/off said layers? See if that works.Pancholo2013-09-04 08:53:08
B
13
S
5
G
1
Posts: 34
Reputation: 2,022

Post » Wed Sep 04, 2013 9:07 am

@Pancholo

c4sp3r89's solution does exactly what jook00 is asking for. By adding the condition "is visible" to on object clicked, the object will only be clickable when visible. It's the easiest solution.
I told my dentist I had trouble with my teeth and asked her to fix it without looking in my mouth..
B
54
S
16
G
8
Posts: 6,160
Reputation: 19,775

Post » Thu Sep 05, 2013 12:48 am

@LittleStain

Hah! You are right. I just found it awkward and my brain couldn't process it like that it seems. I need to be more creative if I'm aiming to become a full-fledged programmer!
B
13
S
5
G
1
Posts: 34
Reputation: 2,022

Post » Thu Sep 05, 2013 3:22 am

Wow that is so simple. I feel so stupid. Thank you
B
58
S
19
G
3
Posts: 446
Reputation: 6,302


Return to How do I....?

Who is online

Users browsing this forum: Yahoo [Bot], YoHoho and 16 guests