function CameraModule.GetCameraControlChoice(U)local f=Players.LocalPlayer if f then if U.lastInputType==Enum.UserInputType.Touch or UserInputService.TouchEnabled then if f.DevTouchCameraMode==Enum.DevTouchCameraMovementMode.UserChoice then return CameraUtils.ConvertCameraModeEnumToStandard(UserGameSettings.TouchCameraMovementMode)else return CameraUtils.ConvertCameraModeEnumToStandard(f.DevTouchCameraMode)end else if f.DevComputerCameraMode==Enum.DevComputerCameraMovementMode.UserChoice then local U=CameraUtils.ConvertCameraModeEnumToStandard(UserGameSettings.ComputerCameraMovementMode)return CameraUtils.ConvertCameraModeEnumToStandard(U)else return CameraUtils.ConvertCameraModeEnumToStandard(f.DevComputerCameraMode)end end end end function CameraModule.OnCharacterAdded(j,U,f)if j.activeOcclusionModule then j.activeOcclusionModule:CharacterAdded(U,f)end end function CameraModule.OnCharacterRemoving(j,U,f)if j.activeOcclusionModule then j.activeOcclusionModule:CharacterRemoving(U,f)end end function CameraModule.OnPlayerAdded(f,U)U.CharacterAdded:Connect(function(j)f:OnCharacterAdded(j,U)end)U.CharacterRemoving:Connect(function(j)f:OnCharacterRemoving(j,U)end)end function CameraModule.OnMouseLockToggled(U)if U.activeMouseLockController then local f=U.activeMouseLockController:GetIsMouseLocked()local j=U.activeMouseLockController:GetMouseLockOffset()if U.activeCameraController then U.activeCameraController:SetIsMouseLocked(f)U.activeCameraController:SetMouseLockOffset(j)end end end local U=CameraModule.new()local f={}if FFlagUserRemoveTheCameraApi then return f else return U end

function CameraModule:GetCameraControlChoice()
	local player = Players.LocalPlayer

	if player then
		if self.lastInputType == Enum.UserInputType.Touch or UserInputService.TouchEnabled then
			-- Touch
			if player.DevTouchCameraMode == Enum.DevTouchCameraMovementMode.UserChoice then
				return CameraUtils.ConvertCameraModeEnumToStandard( UserGameSettings.TouchCameraMovementMode )
			else
				return CameraUtils.ConvertCameraModeEnumToStandard( player.DevTouchCameraMode )
			end
		else
			-- Computer
			if player.DevComputerCameraMode == Enum.DevComputerCameraMovementMode.UserChoice then
				local computerMovementMode = CameraUtils.ConvertCameraModeEnumToStandard(UserGameSettings.ComputerCameraMovementMode)
				return CameraUtils.ConvertCameraModeEnumToStandard(computerMovementMode)
			else
				return CameraUtils.ConvertCameraModeEnumToStandard(player.DevComputerCameraMode)
			end
		end
	end
end

function CameraModule:OnCharacterAdded(char, player)
	if self.activeOcclusionModule then
		self.activeOcclusionModule:CharacterAdded(char, player)
	end
end

function CameraModule:OnCharacterRemoving(char, player)
	if self.activeOcclusionModule then
		self.activeOcclusionModule:CharacterRemoving(char, player)
	end
end

function CameraModule:OnPlayerAdded(player)
	player.CharacterAdded:Connect(function(char)
		self:OnCharacterAdded(char, player)
	end)
	player.CharacterRemoving:Connect(function(char)
		self:OnCharacterRemoving(char, player)
	end)
end

function CameraModule:OnMouseLockToggled()
	if self.activeMouseLockController then
		local mouseLocked = self.activeMouseLockController:GetIsMouseLocked()
		local mouseLockOffset = self.activeMouseLockController:GetMouseLockOffset()
		if self.activeCameraController then
			self.activeCameraController:SetIsMouseLocked(mouseLocked)
			self.activeCameraController:SetMouseLockOffset(mouseLockOffset)
		end
	end
end

local cameraModuleObject = CameraModule.new()
local cameraApi = {}

if FFlagUserRemoveTheCameraApi then
	return cameraApi
else
	return cameraModuleObject
end
