I have a simple script where it should print "clicked (true or false depending on a bool)" but it just returns this: attempt to concatenate string with boolean
Script:
local variables = game.Workspace:WaitForChild("Variables")
local fixedServers = variables:WaitForChild("FixedServers")
local totalServers = variables:WaitForChild("TotalServers")
local smoke = script.Parent.Smoke
local canUse = true
totalServers.Value = totalServers.Value + 1
local function OnClick(player)
print("clicked " .. canUse)
canUse = false
if canUse == true then
canUse = false
smoke:Destroy()
fixedServers = fixedServers + 1
end
end
script.Parent.ClickDetector.MouseClick:connect(OnClick)
