Skip to content

How do I add new character animations? #66

Answered by TrianglyRU
KauanGamer2130 asked this question in Q&A
Discussion options

You must be logged in to vote

You need an additional animation implemented. Do not edit what exist, extend and implement new things if needed.

Basically you'd need to do something like

if input_down.up
{
    animation = ANI_LOOKUP;
}
else if input_down.down
{
    animation = ANI_DUCK;
}
else if animation == ANI_LOOKUP && gsp == 0 && PlayerType == PLAYER_SONIC
{
    animation = ANI_LOOKUP_END
}
else
{
    animation = ANI_IDLE;
}

Then, in scr_player_animate script:

        // Handle animation ending
	if ani_get_ended()
	{
		switch animation
		{
			case ANI_BOUNCE: 
			case ANI_BREATHE: 
			case ANI_FLIP:
			case ANI_TRANSFORM: 
				animation = ANI_MOVE;
			break;
			
                        // A NEW CASE FOR OUR NEW AN…

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@KauanGamer2130
Comment options

Answer selected by KauanGamer2130
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants