I've recently been making a game where I need a part to follow my mouse. One problem I've been encountering is that whenever two players are on the game and have a part following their mouse, the server begins to lag, freezing the part from following the mouse temporarily. Right now my code looks like this:

local connection
			
			local function Changed(input, engine_processed)
				
				if engine_processed then
					return
				end

				if input.UserInputType == Enum.UserInputType.MouseMovement and plr.Backpack.Values.Launched.Value == 1 then
					MouseSend()
				elseif input.UserInputType == Enum.UserInputType.MouseMovement and plr.Backpack.Values.Launched.Value == 0 then
					connection:Disconnect()
				end
			end
			
			connection = UIS.InputChanged:Connect(Changed)

MouseSend() essentially fires a RemoteEvent with multiple parameters such as Mouse.Hit.p, and it's XYZ values. What I've tried to do here is make the client only send the mouse when it moves, but the problem is that when it does move, it fires the RemoteEvent a lot. Around 300 times just by moving the mouse around for a few seconds. What would be a way to make this code more efficient and potentially stop server lag?