Today... on line 3..
"19:01:05.347 - Workspace.Teleport button.Part.Teleport Script:3: attempt to compare number with string"
what does this mean?
script.Parent.ClickDetector.MouseClick:Connect(function(plr)
if plr.leaderstats.Money.Value > 1 then plr.Character.HumanoidRootPart.CFrame = CFrame.new(281, 30.6, -26) end
end)
just another thing, where is a good place to look for learning how to script and all the properties of the roblox studio, is the roblox wiki good for that?
It seems that plr.leaderstats.Money
is a StringValue
object. Try changing it to be a IntValue
or NumberValue
object.
Roblox Development Hub is a great place to read on scripting, and also contains the API for all properties and objects in the game.
Seems like the leaderstats money value is a string. If your using a string value, use NumberValue or IntValue instead