There is a noticeable delay in client-to-server replication only the very first time a specific animation track is played. Subsequent plays of the same animation replicate instantly. The animation is triggered and played on the client side, relying on Roblox’s default character network ownership for automatic replication.
I did some digging and I used ContentProvider on the server. This works fine for animations that does not require any tools. However, there is one animation that does, and I find that no matter what I do, there is still a noticeable delay.
Methods I have tried to fix this:
1,. Tried to pre-load the tool animation, which didnt work
2. Tried to play a ghost track, which didnt work either
3. Tried to equip and unequip the tool on the server, which sometimes work for some reason
So I think it could be something to do with the tool’s replication or physics, but I don’t know for sure.
Any help and insights to this issue will be much appreciated, thank you in advance!
Welding script below (To weld the weapon to the player, server-sided)
local Players = game:GetService("Players")
local ReplicatedStorage = game:GetService("ReplicatedStorage")
local tool = ReplicatedStorage.Tools:WaitForChild("Hammer")
Players.PlayerAdded:Connect(function(player)
player.CharacterAppearanceLoaded:Connect(function(character)
local clone = tool:Clone()
clone.Parent = player.Backpack
local weldTo = character:WaitForChild("Right Arm")
local bodyAttach = clone.BodyAttach
local weld = Instance.new("Motor6D")
weld.Parent = bodyAttach
weld.Part1 = bodyAttach
weld.Part0 = weldTo
weld.C1 = clone.GripCFrame.Value
weld.C0 = clone.C0.Value
end)
end)
Client script is just a simple press key to equip tool and play animation.