So I coded a WalkToPoint function that has you move to a certain point, it works for me fine inside and outside studio, although my friend joined and it doesn't work for him. I cant figure it out but here's the code.
local ui = script.Parent.Parent.Parent
local PlayerModule = require(game.Players.LocalPlayer.PlayerScripts:WaitForChild("PlayerModule"))
local Controls = PlayerModule:GetControls()
local RunService = game:GetService("RunService")
local Players = game:GetService("Players")
local point1 = game.Workspace.Point1.Position
local localPlayer = Players.LocalPlayer
character = game.Workspace:WaitForChild(localPlayer.Name)
function leftClick()
ui.Enabled = false
print(point1.X)
character.Humanoid.WalkToPoint = point1
wait(1)
Controls:Enable()
print("No Button Pressed")
end
script.Parent.MouseButton1Click:Connect(leftClick)

2 comments
is it in a local script?
Yes.