Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
COMMUNITY QUESTION

Animation through Scripts?

Is it possible to create animations through a script? I know a guy who made an entire script for a script builder where you could press a button and your player does stuff. I "animate" in a different way, by moving the joints inside a torso, but the problem is; when I walk it still plays the default animation right over the rotated joint, is there another way to actually animate?

3 comments

0

I really want to animate, without any plugin of the sort.

0

He mention something called 'Linear Interpolation'

0

I guess you could weld the parts and move them slightly for each frame, of the animation, but this will be incredibly tedious.

1 answer

If I'm correct, what you're wanting to do is make it so the default animations don't play over yours.

To remove the animation script when someone enters the game, use this code:

game.Players.PlayerAdded:connect(function(p) -- hook up to PlayerAdded
	p.CharacterAdded:connect(function(c) -- hook up to CharacterAdded from the Player object
		c:WaitForChild'Animate'.Disabled = true  -- make it so the script doesn't error
		c:WaitForChild'Animate':remove() -- remove the script
	end)
	repeat wait() until p.Character
	p.Character:WaitForChild'Animate'.Disabled = true -- repeat this, because the event has already fired before we connected it.
	p.Character:WaitForChild'Animate':remove()
end)

And to manipulate CFrames, use CFrame:lerp() .

Hope this helped!

This discussion is preserved as it was. New answers, comments, and votes are closed.