Thread Rating:
  • 1 Vote(s) - 5 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Tutorial Animations
#1
Hello

Another tutorial, this time is for animations, Smile . All of this is taken from _animatedmodels.gsc, _destructible_types.gsc and _load.gsc.

Lets begin, first you need to load a animtree, load it at the beggining of a gsc file(is not necesary to be at top, but I recomend):

Code:
#using_animtree( "animtree name" );

Here is a list of animtree names(only a few work on MP):

Code:
ac130
animated_props
chair
civilian
destructibles
dog
door
drones
fastrope
generic_human
mg42
multiplayer
player
player_3rd_person
script_model
vehicles

Find a anim you want on that animtree and now, is time to precache it, use this command on Init() in your mod:

Code:
PrecacheMpAnim("animation you want");

Now, you can play your animation with this commands, use first just to play it:

Code:
entity ScriptModelPlayAnim( "animation you precached" ); //play animation
Code:
entity willNeverChange(); //makes the animation never change, it will only play the anim you gave it before.
Code:
entity scriptModelClearAnim( "animation you were using" ); //stop the animation that is being played
Code:
destructible_anim( get_precached_anim( "generator_explode" ), #animtree, "setanimknob", undefined, undefined, "generator_explode" ); //This is what destructibles use for animations, first selects the anim, then load animtrees(the one that you loaded,destructibles use animtree destructibles), the it sets this different play anim command: setanimknob, then it allow you to play on different tags and then the animation you want.

This is basically all, Wink

Credits:

- Se7en, he was the first in finding this, but he never released, Sad
Reply

#2
Stop Spamming Omg!!! Jokes, Nice tutorials keep it up Big Grin
Reply

#3
Ty! Big Grin
[Image: Aim_Le_Zzz.jpg]
Reply

#4
Nice OMA boi.
Reply

#5
OMA
Reply

#6
You should have added the list of animations type without them in your tutorial it will be no use for those who don't know where to find the animations.
eg.

ScriptModelPlayAnim("pb_sprint");

also the "#using_animtree( "animtree name" );" is not that necessary
since it's already added in most of the includes files.
The animations works without this include file.

just a tip for everyone...
Reply

#7
(12-02-2011, 06:50)ghilllie Wrote: You should have added the list of animations type without them in your tutorial it will be no use for those who don't know where to find the animations.
eg.

ScriptModelPlayAnim("pb_sprint");

also the "#using_animtree( "animtree name" );" is not that necessary
since it's already added in most of the includes files.
The animations works without this include file.

just a tip for everyone...

http://www.itsmods.com/forum/Thread-Rele...-List.html
Reply



Possibly Related Threads…
Thread Author Replies Views Last Post
  Exporting models to maya + bones work how about animations? sayedishot47 11 9,120 04-04-2012, 11:23
Last Post: Nekochan
Brick [Release] [Blender 3D] Create models & animations for CoD with Blender (without Maya)! CoDEmanX 16 12,124 01-12-2012, 04:41
Last Post: Sanya
Rainbow [Tutorial] New playeranimtypes | Setting other animations Nekochan 15 10,707 10-16-2011, 18:33
Last Post: Nekochan
Rainbow [Tutorial] "Importing" animations from CoDs Nekochan 44 22,797 09-09-2011, 23:34
Last Post: d0h!
  Tard needs help with animations and bullet penetrations elmopio 0 1,829 08-16-2011, 14:24
Last Post: elmopio
Rainbow [Release] Finding ALL COD4 animations Scripts18 2 4,402 08-06-2011, 15:53
Last Post: Yamato
  Sounds/Animations/ANYTHING!! Eekhoorn 20 11,813 06-15-2011, 20:06
Last Post: iAegle

Forum Jump:


Users browsing this thread:
1 Guest(s)

Forum Powered By MyBB, Theme by © 2002-2024 Melroy van den Berg.