How can i copy animation of an model to a clone using cframes or other methods?

i want to make a model replicate its animations to a clone, is copying cframes over a good way of doing it and how would i do it? And how would i replicate it to the rest of the model, not just the primarypart

3 Likes
RenderStepped:Connect(function()
ToolEquipped.PrimaryPart.CFrame = ViewModel.ItemHook.CFrame

this doesnt work but its the thing am going for

1 Like

Its one way.

But iirc, the Motor6Ds on the rig has a hidden Property called Transform that allows you to copy it’s CFrame during the Animation, allowing you to replicate it on (lets say a viewmodel.)

There are probably more efficient ways to doing it that I cant really think off atm.
One way I can think off is copying the id of the animation that its playing, and playing it at a certain timestamp.

1 Like

Am using transform for the viewmodel rig but how this works is when a tool is equipped it clones it to the viewmodel

i cant finda good way to use transform on the tools because there’s no way to replicate the grip position automatically, i’ve just put a block on the end of the viewmodel arm called Itemhook and running this on renderedstepped

ToolEquipped.PrimaryPart.Position = ViewModel.ItemHook.Position

the animation id thing i might do as last resort but i’d like to find a simple way just copying over the cframes position and rotation

1 Like

You could try:

for _, instance in pairs(Model:GetDescendants()) do

if instance:IsA(“BasePart”) then

local instanceClone = instance:Clone()

game:GetService(“RunService”).PreRender:Connect(function()

instanceClone.CFrame = instance.CFrame

end)

end

end
1 Like