you place a script inside the “StarterCharacterScripts”, you then write this
local char = script.Parent
local root = char:WaitForChild("HumanoidRootPart")
local hum = char:WaitForChild("Humanoid")
local anim = char:WaitForChild("Animate")
while true do
if root and hum and anim then
anim:Destroy()
break
end
task.wait()
end
or if you don’t want to destroy the animate script, you simply replace the destroy function with a disabled one instead
This property sets the priority of an AnimationTrack. Depending on what this is set to, playing multiple animations at once will look to this property to figure out which KeyframePoses should be played over one another.
local function DisableHandOut(character)
local Animator = character.Animate
local Animation = Instance.new("Animation")
Animation.AnimationId = "http://www.roblox.com/asset/?id=0"
local ToolNone = Animator:FindFirstChild("toolnone")
if ToolNone then
local NewTool = Instance.new("StringValue")
NewTool.Name = "toolnone"
Animation.Name = "ToolNoneAnim"
Animation.Parent = NewTool
ToolNone:Destroy()
NewTool.Parent = Animator
end
end
game.Players.PlayerAdded:Connect(function(player)
player.CharacterAdded:Connect(function(character)
DisableHandOut(character)
end)
end)
you have to simply make a new animation from scratch using either the default animator plugin, in that plugin you simply create a keyframe for the upper torso, lower torso, head so it does not wiggle around
export the animations (or combine the idle gun hold with this too) then replace the ID in your custom thing
it’s because of your upper torso moving, when you make an animation and don’t include a part (with keyframes) in the animating board it will not be effected but will effect the relative positions of the part it has connected to, you have to make the uppertorso and lower torso stop moving
So how do I go about making a weapon sway animation, do I just play separate animations is x key is held down? Like (a) left sway animation, (d) right sway etc?
i don’t know where you’re going with the topic since this is unrelated but i don’t know what weapon sway exactly means, i googled it and i saw on reddit weapon sway is the process of the weapon moving on all its own while you ADS (aim down sights)
i don’t know anything else that’ll help solve this issue apart from my other suggestions since R15 is a glitchy rig since it uses 15 exact bones
I’m just asking questions about animations at this point.
Weapon sway is when you’re moving (both ads and non ads) it’s just your arm basically slightly rotating. Ever played a fps? Your gun rotates slightly in the direction you’re moving. If you move left, gun rotates to the left slightly while left key is down and vice versa.
yeah this is possible and easy to do, you basically use CFrames instead of animation to make this easier, you basically have to get the extended X-axis of your humanoid root part’s velocity and apply it on your gun (make sure to balance the calculation), you don’t have to do some adjustments like (if walkingright or walking left then) thing
i also suggest using Lerp as it is smooth and unlike linear CFrames don’t lifelessly move
you get the velocity of the humanoidRootPart and see if the humanoid’s move magnitude is above 0, you lerp the weapon’s CFrame offset
of the humanoidRootPart’s velocity i mentioned earlier, make sure to divide and clamp it to a maximum (like 1.5 studs)
Sorry for late reply I completely forgot about this thread.
To set to a higher priority go to your animation editor.
Click the options button in the upper-left section of the editor window.
Choose an option from the Set Animation Priority menu. In a game, if you play an animation with a higher priority than one that’s already playing, the new animation will override the old.
Alternatively simply change the animation priority via script.
local AnimationTrack = Animator:LoadAnimation(Animation)
AnimationTrack.Priority = Enum.AnimationPriority.Action
the only issue that you have is the torso and uppertorso moving making the arm basically stupid looking, you have to add a keyframe for the uppertorso, lower torso (you dont need to move them btw but that’ll make them stay in place)