The SurfaceGUI is in StaterGUI and the Adornee is set to the part, as it should be; however, it is not firing the function when clicked.
Hierarchy and properties:
https://gyazo.com/6296756a75fc12dfde6fe860623a3bf2
Script snippet:
mainframe.Topbar.CHARACTER.MouseButton1Down:Connect(function()
print("hi")
if debounce == false then
debounce = true
mainframe.StartScreen:TweenPosition(UDim2.new(1,0,0.108,0),1,1,2)
mainframe.Character:TweenPosition(UDim2.new(0,0,0.108,0),1,1,2)
end
end)
Expected output:
hi
Output:
N/A
2 Likes
Is this in a serverscript or localscript?
It’s in a LocalScript and it the mouse cursor icon doesn’t go black which is weird (when hovering over the buttons).
Can you show the rest of the hierarchy within the GUI? And also, try using Activated instead of MouseButton1Down and see if that works any better.
Already tried activated and here is the hierarchy: https://gyazo.com/fb637d494f1894801fc65e3504bf1f2c
I just looked at my place that has a working one and the mouse also doesn’t go black. Although this behavior is still strange. Perhaps there is another GUI element on top of the button that is blocking input?
Here is the part hierarchy, however, none of those SurfaceGUIs should be interfering as they don’t have the same face. https://gyazo.com/9c11dd807f72ff43937a6cb8a8e33d3e
Also, thought I should add that even deleting everything except the menu doesn’t make it work.
That is a good point. If you could send the rbxl for the SurfaceGUI that would be immensely helpful.
If you’re not comfortable with that it’s fine. However we will keep going back and forth. The next thing I would suggest is messing with the z index values
I’ll send you the file without the scripts. 2 seconds.
Make sure it’s actually a TextButton and not the TextLabel, that’s the only thing I can think of. Good luck 
Already checked, thanks though!
1 Like
Ticking the CHARACTER button’s “Active” property worked for me.
2 Likes
Hey, out of confusion, is this the full script because I’m not seeing the variable for the debounce?
1 Like