Was currently making a “select team” script (on my own) and everything was fine, but i didn’t want the player to move when selecting so I put the DevComputerMovementMode to Scriptable, but something is making it break and i cant figure it out.
(local) script:
local plr = game.Players.LocalPlayer
local char = plr.Character or plr.CharacterAdded:Wait()
local function CitizenClick()
plr.Team = game.Teams.Citizen
char.HumanoidRootPart.CFrame = workspace.CitizenSpawn.CFrame
script.Parent.Enabled = false
plr.DevComputerMovementMode = Enum.DevComputerMovementMode.UserChoice --i tried using enum to see if it solved anything
end
local function PoliceClick()
plr.Team = game.Teams.Police
char.HumanoidRootPart.CFrame = workspace.PoliceStation.PoliceSPawn.CFrame
script.Parent.Enabled = false
plr.DevComputerMovementMode = "UserChoice"
end
script.Parent.Citizen.MouseButton1Click:Connect(CitizenClick)
script.Parent.Police.MouseButton1Click:Connect(PoliceClick)