generic image
Processing...
  • Games
  • Catalog
  • Develop
  • Robux
  • Search in Players
  • Search in Games
  • Search in Catalog
  • Search in Groups
  • Search in Library
  • Log In
  • Sign Up
  • Games
  • Catalog
  • Develop
  • Robux
   
ROBLOX Forum » Game Creation and Development » Scripting Helpers
Home Search
 

Re: Animation won't clone? HELP!

Previous Thread :: Next Thread 
speedydude900 is online. speedydude900
Joined: 02 Feb 2010
Total Posts: 788
08 May 2014 11:42 PM
It's not working :(, suppose to clone an animation into your character when you click the gui and play it.

player = script.Parent.Parent.Parent.Parent.Parent
anim = game.ServerStorage:findFirstChild("SleepAnim") -- put the excact weapon name here. the weapon has to be in game ServerStorage


function buy()
local animTrack = player.Humanoid:LoadAnimation(SleepAnim) -- info dissapears also
local a = anim:clone()
a.Parent = player.Humanoid
animTrack:Play()

end
script.Parent.MouseButton1Down:connect(buy)
Report Abuse
speedydude900 is online. speedydude900
Joined: 02 Feb 2010
Total Posts: 788
09 May 2014 12:21 AM
:l
Bump.
Report Abuse
lama321 is not online. lama321
Joined: 18 Dec 2011
Total Posts: 300
09 May 2014 12:28 AM
I think your problem is that you try to load the 'SleepAnim' animation without referencing what it is, fix it by doing this

function buy()
local a = anim:clone()
a.Parent = player.Humanoid
local animTrack = player.Humanoid:LoadAnimation(a) -- info dissapears also
animTrack:Play()

end
script.Parent.MouseButton1Down:connect(buy)
Report Abuse
Previous Thread :: Next Thread 
Page 1 of 1
 
 
ROBLOX Forum » Game Creation and Development » Scripting Helpers
   
 
   
  • About Us
  • Jobs
  • Blog
  • Parents
  • Help
  • Terms
  • Privacy

©2017 Roblox Corporation. Roblox, the Roblox logo, Robux, Bloxy, and Powering Imagination are among our registered and unregistered trademarks in the U.S. and other countries.



Progress
Starting Roblox...
Connecting to Players...
R R

Roblox is now loading. Get ready to play!

R R

You're moments away from getting into the game!

Click here for help

Check Remember my choice and click Launch Application in the dialog box above to join games faster in the future!

Gameplay sponsored by:
Loading 0% - Starting game...
Get more with Builders Club! Join Builders Club
Choose Your Avatar
I have an account
generic image