I'm using a script in SSS for a gui where once you click, it adds something to your character. Everything works, but it just doesn't do anything or print after I reset.
code:
game.Players.PlayerAdded:Connect(function(Player)
Player.CharacterAdded:connect(function()
local Button = Player.PlayerGui:WaitForChild("O1").main.EFrame.J2.TextButton
local vp = Player.PlayerGui:WaitForChild("O1").main.EFrame.J2.ViewportFrame
local Debounce = false
local Event = game:GetService("ReplicatedStorage"):WaitForChild("EventsFolder").ChangerEvent
local function lerp(start, goal, alpha)
return start + alpha * (goal - start)
end
local mouseOver = false
Button.MouseButton1Click:Connect(function(hit)
if Debounce == false then
if Player and Player.Character.Humanoid.Health>=0 then
Event:Fire(Player, Button.G1.Value)
Debounce = true
wait(.5)
Debounce = false
end
end
end)
end)
end)
