Yes that will always be true but I’m wondering if its ok to edit motor6d’s on the client for the visual effect on animating my banana with my viewmodel.
I tried this in the viewmodel function below but nothing happened.
BananaRewarding
function Controller:RewardBanana()
local function character()
local bananaTrack = self.Animations.BananaReward
bananaTrack:Play()
return bananaTrack.Length
end
local function viewmodel() -- Viewmodel banana reward needs a motor6d in the hrp and bananamesh in the character, part0 = hrp, part1 = bananamesh
local newMesh = Components.Banana.BananaMesh:Clone()
newMesh.Parent = self.ViewModel
local motor6d = Instance.new("Motor6D")
motor6d.Parent = self.VRoot
motor6d.Part0 = self.VRoot
motor6d.Part1 = newMesh
local viewmodelBananaTrack = self.ViewModel.Humanoid.Animator:LoadAnimation(Animations.Reward)
viewmodelBananaTrack:Play()
task.delay(viewmodelBananaTrack.Length,function()
motor6d:Destroy()
newMesh:Destroy()
end)
end
viewmodel()
return character()
end
You can see I’m trying to animate my actual character and the ViewModel.
Animation Length might be 0 if the animation hasn’t loaded, aside from that, if you’re doing it only as a visual effect that only the client would see, then creating the motor6D on client only would be OK, if it is an animation all players would see, then creating on server would be the thing to do.