Answers for "gui button roblox"

1

how to execute scripts when a button gui is pressed roblox

function leftClick()
	print("Left mouse click")
end
 
function rightClick()
	print("Right mouse click")
end
 
script.Parent.MouseButton1Click:Connect(leftClick)
script.Parent.MouseButton2Click:Connect(rightClick)
Posted by: Guest on July-29-2020
0

gui button roblox

local button = script.Parent
 
local function onButtonActivated()
	print("Button activated!")
	-- Perform expected button action(s) here
 
end
 
button.Activated:Connect(onButtonActivated)
Posted by: Guest on October-25-2021

Browse Popular Code Answers by Language