Sign in to follow this  
d000hg

Animation in a fighting/platform game

Recommended Posts

Although I've done a bunch of games programming, animation is an area I've never got into. I'm thinking about making a game with stick-men fighting (2D) and I'm not quite sure where to begin with the animation. I keep being tempted by complicated things like realistic physics, but all those games from 10 years ago must have used much simpler systems. Especially since I'm using vector art, I don't want to have to store sprites for each movement, but on the other hand I do want to keep it simple. Are there any good articles on related subjects you can recommend, or any information on how these types of games normally work?

Share this post


Link to post
Share on other sites
10-year old games usually stick (no pun intended) with spritesheets as far as I've seen. I'm not too familiar with vector art but I assume that a basic keyframe system, as seen in 3D models, would do just fine. Basically, you define the positions and orientations of these sticky man parts at certain points in time and interpolate between them for the frames in-between, hence the name key-frame.

Share this post


Link to post
Share on other sites
Quote:
Original post by d000hg
Is it normal to go as far as having separate animations for different body parts, so you can punch and run at the same time? I'm trying really hard not to get over-complicated.


yeah some games use sprites that are split between upper and lower body so they can animate seperately, some have the arm missing so it can swing independantly, some use a paper-doll like system so they can change different aspects of animation/appearance.

its all about what you want to do, what you've got to work with, etc.

Share this post


Link to post
Share on other sites
I'm doing a scrolling beat-em-up at the moment and trying to figure out the same thing at the moment. Currently I'm going for canned animation sequences (eg. a punch) defined in xml (including hit and vunerable boxes), and linking them together with a state machine in code. The state machine is getting a little hairy
though, so I might make it slightly more generic and move some of the state transition logic into data files so I don't end up with loads of code duplication for near identical attacks.

Personally to make things easier I'd use sprites in-game rather than vectors (although you could still draw with vectors and export to png or whatever).

Quote:
Original post by hogarth
basically it's not normal, you could look on the net for a "sprite" set for king of fighters or SFIII, just to use to learn from

Most sprite sheets from commercial games you'll find on the internet are made by fans piecing them together using output from emulators. It's highly unlikely they'll bear any resemblance to what was actually used by the code.

Share this post


Link to post
Share on other sites
Since its stick figures, I don't think it'd hurt to use canned animation. 2d fighting games tend to look weird when keyframes are tweened. I think it would help to try out some fighting games, like SFIII, CvS2 & MOTW. They've an insane number of animation frames.

Also check out MUGEN, see how it handles character animation and state machines. Learnt a lotta crap making one character for MUGEN.

I've been working on a 2d platformer/fighter for the longest time, it uses the paperdoll system but without keyframe interpolation. It doesn't have any advanced physics though.

You might wanna check out 'N'. The game even has 2d ragdoll physics.
http://www.harveycartel.org/metanet/tutorials.html

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this