Dreydahh Posted May 16, 2010 Share Posted May 16, 2010 To start animation in game, we have to use function G_SetAnim(). But when I executing this, player is doing this one time. I need to know how to loop animation. I have: G_SetAnim(ent, &ent->client->pers.cmd, SETANIM_TORSO, BOTH_STAND4, SETANIM_FLAG_OVERRIDE|SETANIM_FLAG_HOLD, 0); and I want to walk with BOTH_STAND4. How to do that? My second question is how to make sequence of animations. For example I want to run BOTH_SONICPAIN_START, BOTH_SONICPAIN_HOLD, BOTH_SONICPAIN_END. Sorry for my english. Link to comment Share on other sites More sharing options...
Kimberly Posted May 17, 2010 Share Posted May 17, 2010 To start animation in game, we have to use function G_SetAnim(). But when I executing this, player is doing this one time. I need to know how to loop animation. Im not sure I have never played with the animation but have you tried to search in the code for the console slicing code? g_utils.c Line: 01586 //keep them in the healing anim even when the healing debounce is not yet expired if (ent->client->ps.torsoAnim == BOTH_BUTTON_HOLD || ent->client->ps.torsoAnim == BOTH_CONSOLE1) { //extend the time ent->client->ps.torsoTimer = 500; } else { G_SetAnim( ent, NULL, SETANIM_TORSO, BOTH_BUTTON_HOLD,SETANIM_FLAG_OVERRIDE|SETANIM_FLAG_HOLD, 0 ); } I have: G_SetAnim(ent, &ent->client->pers.cmd, SETANIM_TORSO, BOTH_STAND4, SETANIM_FLAG_OVERRIDE|SETANIM_FLAG_HOLD, 0); and I want to walk with BOTH_STAND4. How to do that? How I said search the walking code and try to understand it My second question is how to make sequence of animations. For example I want to run BOTH_SONICPAIN_START, BOTH_SONICPAIN_HOLD, BOTH_SONICPAIN_END. I'm not sure but maybe you could play them one after another? { anim1 extend time anim2 extend time anim 3 extend time } -Kimmy Link to comment Share on other sites More sharing options...
Dreydahh Posted May 18, 2010 Author Share Posted May 18, 2010 Thanks, my anims re looped. I'm using G_SetAnim and torsoTimer=9999999 . But playing one after another doesn't work. If I set second anim's flag to OVERRIDE, it will override previous. But if flag isn't OVERRIDE, only first animation will show. (with extend time doesn't work too) Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.