function PlayerConverter.SpeederToPlayer(n,b)LoadCharacter:FireServer()PlayerConverter:SpeederToPlayerClient(b)end function PlayerConverter.SpeederToPlayerServer(n,b)b:LoadCharacter()LoadCharacter:FireClient(b)end function PlayerConverter.SpeederToPlayerClient(n,b)if b==nil then b=true end if b and UserInputService.MouseBehavior~=Enum.MouseBehavior.Default then ExitSound:Play()end UserInputService.MouseBehavior=Enum.MouseBehavior.Default UserInputService.MouseIconEnabled=true RemoveActivePlayer:FireServer()local Q=game:GetService("\080\108\097\121\101\114\115")local X=Q.LocalPlayer local P=X:FindFirstChild("\080\108\097\121\101\114\071\117\105")if IS_MOBILE then local b=P:WaitForChild("\084\111\117\099\104\071\117\105")b.Enabled=true end local J=P:WaitForChild("\084\111\112\066\097\114")J.Enabled=false end function PlayerConverter.UnlockPlayerControls(b)UserInputService.MouseBehavior=Enum.MouseBehavior.Default UserInputService.MouseIconEnabled=true RemoveActivePlayer:FireServer()local n=game:GetService("\080\108\097\121\101\114\115")local Q=n.LocalPlayer local X=Q:FindFirstChild("\080\108\097\121\101\114\071\117\105")if IS_MOBILE then local b=X:WaitForChild("\084\111\117\099\104\071\117\105")b.Enabled=true end local P=X:WaitForChild("\084\111\112\066\097\114")P.Enabled=false end

function PlayerConverter:SpeederToPlayer(playSound)
	-- LoadCharacter has to be fired server-side, so fire a RemoteEvent
	-- to get it there
	LoadCharacter:FireServer()
	PlayerConverter:SpeederToPlayerClient(playSound)
end -- PlayerConverter:SpeederToPlayer()

function PlayerConverter:SpeederToPlayerServer(player)
	player:LoadCharacter()
	
	LoadCharacter:FireClient(player)
end -- PlayerConverter:SpeederToPlayer()

function PlayerConverter:SpeederToPlayerClient(playSound)
	if playSound == nil then playSound = true end
	
	-- Play sounds
	if playSound and (UserInputService.MouseBehavior ~= Enum.MouseBehavior.Default) then
		ExitSound:Play()
	end
	
	-- Unlock and show mouse
	UserInputService.MouseBehavior = Enum.MouseBehavior.Default
	UserInputService.MouseIconEnabled = true
	
	-- Remove user from race ActivePlayer's list (if racing)
	RemoveActivePlayer:FireServer()
	
	-- Enable touch control GUIs on mobile devices
	local Players = game:GetService("Players")
	local player = Players.LocalPlayer
	local PlayerGui = player:FindFirstChild("PlayerGui")
	if IS_MOBILE then
		local TouchGui = PlayerGui:WaitForChild("TouchGui")
		
		TouchGui.Enabled = true
	end	
	
	local TopBar = PlayerGui:WaitForChild("TopBar")
	TopBar.Enabled = false	
end -- PlayerConverter:SpeederToPlayerClient()

function PlayerConverter:UnlockPlayerControls()
	UserInputService.MouseBehavior = Enum.MouseBehavior.Default
	UserInputService.MouseIconEnabled = true
	
	-- Remove user from race ActivePlayer's list (if racing)
	RemoveActivePlayer:FireServer()
	
	-- Enable touch control GUIs on mobile devices
	local Players = game:GetService("Players")
	local player = Players.LocalPlayer
	local PlayerGui = player:FindFirstChild("PlayerGui")
	if (IS_MOBILE) then
		local TouchGui = PlayerGui:WaitForChild("TouchGui")
		
		TouchGui.Enabled = true
	end	
	
	local TopBar = PlayerGui:WaitForChild("TopBar")
	TopBar.Enabled = false
end -- PlayerConverter:UnlockPlayerControls()