-- Disable PickupInfo when player is seated

local runningWhenSeated = false
local function onCharacterAdded(character)
	local characterHumanoid = character:WaitForChild("Humanoid")
	characterHumanoid.Seated:Connect(function(isSeated)
		if isSeated and PickupInfoHandler.instance.isRunning then
			runningWhenSeated = true
			PickupInfoHandler.instance:stop()
		elseif not isSeated and not PickupInfoHandler.instance.isRunning and runningWhenSeated == true then
			runningWhenSeated = false
			PickupInfoHandler.instance:start()
		end
	end)
end

localPlayer.CharacterAdded:Connect(onCharacterAdded)
if localPlayer.Character then
	onCharacterAdded(localPlayer.Character)
end

return PickupInfoHandler
