Boopbot
|
  |
| Joined: 11 Jul 2008 |
| Total Posts: 2284 |
|
|
| 21 Oct 2014 09:43 PM |
I first tried it with just loading it onto a humanoid object, and that worked, but only in Edit mode. Once I ran a test server it wouldn't start the animation, but it said in the output that it was reaching different keyframes.
Next I looked at the wiki and loaded the animation onto an AnimationController, and the same thing happened, it showed that it was reaching keyframes but the guy wasn't moving.
Is there a good script for NPC animation that I can look at? |
|
|
| Report Abuse |
|
|
|
| 21 Oct 2014 09:51 PM |
You should be able to do it with the humanoid, there are some bugs with running animations on the server that resurface from time to time
guise i have a siggy |
|
|
| Report Abuse |
|
|
Boopbot
|
  |
| Joined: 11 Jul 2008 |
| Total Posts: 2284 |
|
| |
|
|
| 21 Oct 2014 10:16 PM |
function runAnim(npc,id) local anim = Instance.new'Animation'; anim.AnimationId = id; local controller = Instance.new('AnimationController',npc); local track = controller:LoadAnimation(anim); anim:Play(); track:Destroy(); end;
runAnim(game.Workspace.NPC,'rbxassetid://1'); |
|
|
| Report Abuse |
|
|
|
| 21 Oct 2014 10:17 PM |
whoops:
function runAnim(npc,id) xpcall(function() npc['AnimationController']:Destroy'' end, function return 'Error: 'end); local anim = Instance.new'Animation'; anim.AnimationId = id; local controller = Instance.new('AnimationController',npc); local track = controller:LoadAnimation(anim); track:Play(); end;
runAnim(game.Workspace.NPC,'rbxassetid://1'); |
|
|
| Report Abuse |
|
|
|
| 21 Oct 2014 10:19 PM |
kpt, there's no need to overcomplicate things, it's just a bug on roblox's end.
guise i have a siggy |
|
|
| Report Abuse |
|
|
|
| 21 Oct 2014 10:20 PM |
'Is there a good script for NPC animation that I can look at?'; Also, I'm not over-complicating things. Do you think he would rather have nothing or something. No offense intended. :)
semicolons are love, semicolons are life |
|
|
| Report Abuse |
|
|