You can check for player state when the player jumps. If the new state is Enum.HumanoidStateType.Jumping, they're jumping! This means you can reselect another animation randomly each time they jumps.
Use LocalScript for this.
local plr = game.Players.LocalPlayer
local char = plr.Character or plr.CharacterAdded:Wait()
local hum = char:WaitForChild('Humanoid')
local anims = {
"rbxassetid://5620182994",
"rbxassetid://5620201065"
}
local animObj = animateScript.jump.JumpAnim
local changeAnimation = {
[Enum.HumanoidStateType.Jumping] = true
}
hum.StateChanged:Connect(function(_, newState)
if changeAnimation[newState] then
animObj.AnimationId = anims[math.random(1, #anims)]
end
end)
Just to make sure, you should use humanoid:LoadAnimation(animationObject) in case you want to play this animation yourself when the player jumps.
2 comments
Make 2 animations and put it in a folder then randomize it by writing a script.
I've tried that already, it only chooses one animation and then sticks with it the entire time