Need help in replacing FPS fake arms by arms animation

So i was encountering some issues in letting the character remains in pose after the animation finished playing and i have watched some of the solutions on the devforum but none of them work for me. The purpose that i’m trying to do this is because i want to replace FPS fake arms with arms animation and this is the result:


It just doesn’t stay in the same pose after the animation has finished playing, i really need a solution for this problem.
Here is the code:
Local script

repeat

wait()

until game:IsLoaded()

local player = game.Players.LocalPlayer

local animation = script.Animation

repeat

wait()

until player.Character

local contextactionservice = game:GetService("ContextActionService")

local humanoid = player.Character:WaitForChild("Humanoid")

local FPS = humanoid:LoadAnimation(animation)

local function binding(name,inputstate,inputobject)
	if name =="pose" and inputstate == Enum.UserInputState.Begin then
		print("Play")
		FPS:Play()
		FPS.KeyframeReached:Connect(function(keyframe)
			if keyframe == "Frame2" then
				print("hi")
				FPS.TimePosition = FPS.Length
				FPS:AdjustSpeed(0)
			end
		end)
	end
end
contextactionservice:BindAction("pose",binding,true,Enum.KeyCode.E)

Instead of using FPS:AdjustSpeed(0) try to use FPS:Stop().

Nah, it still doesn’t work. Do you have any other suggestions?

I think you need to make a idle animation that is looped. When the keyframe is the second frame you can play the idle animation and stop the other one.

What do you mean by idle animation?

When do you play the ‘FPS’ animation you can make play another one that is simply a holding animation (Remember to loop the holding animation). If you don’t understand i can send you a video of what i mean.

yeah, i need that video to understand it

Here is the video:

yeah and where is the second animation ?

You have to make the second animation as demonstrated in the video.

so the second one is the equip pose animation and you have to loop it?

Exactly. It’s a pose animation.

so it only contains the last frame instead of two frames in the “FPS” animation?

Yes. it’s like that. The pose animation is the second frame.

1 Like

ok let me try and i’ll tell you the result

1 Like

wow, it works, thanks a lot for your help but i just discover that when the player move, the hand just shake so intensively and i do not want the gun just swing too much while walking so any suggestion?

can you pls wait, the video just take a little bit too long to convert into mp4 , the international connection in my country is broken so it might take several minutes to do that

ok so this is the video


as you can see, the hand after the animation just swing and i want it to hold still while moving. This is the problem that i mentioned

Yeah. It swings because you are using R15 instead of R6.

Unless you can duplicate the first frame of the holding animation.