I’d also like to say that you should do sanity checks on the server when receiving the event, so exploiters can’t abuse the event.
For example, check if the speed isn’t something absurd, or invalid, such as:
local stoneSpeed = 16*4
--vv Change this line
REMOTEEVENTHERE.OnServerEvent:Connect(function(plr, newSpeed, toolName))
if (newSpeed == stoneSpeed) and (plr.Character:FindFirstChild(toolName)) then
-- Code here
end)
But if that’s the only other speed they can go you might as well just not have a newSpeed argument, and only check for the tool’s presence.
local P = Plr.Character.HumanoidRootPart:FindFirstChild("ParticleEmitter")
if P then
P.Parent = script.Parent.Handle
script.Parent.Handle:WaitForChild("ParticleEmitter").Enabled = false
end