Yes, make sure all station part names and button texts are exactly the same.
local stationSpawnList = game.Workspace.Stations
script.Parent.MouseButton1Down:Connect(function()
if stationSpawnList:FindFirstChild(script.Parent.Text) then
game.Players.LocalPlayer.Character:WaitForChild('HumanoidRootPart').CFrame = stationSpawnList:FindFirstChild(script.Parent.Text).CFrame
end
end)
Wouldn’t be a helpful alternative as no errors would print.
yes they would… you are teleporting the player to script.Parent.Text if roblox doesnt find it the code breaks
Yes, you’re correct in saying it will break, however it will not print any error if the text isn’t found. This topic has already been resolved.