Archived

This topic is now archived and is closed to further replies.

Quino

Character animations

Recommended Posts

Quino    122
Hello all, I have an alright skill with opengl, and would prefereably liek to know how to do this: How can i load multiple character animations from one picture? Like, with little fighter 2( www.lf2.com i do beleive), It gives you the pictures of the sprites. each picture has about 25 o so poses, and I was wondering, how do they load each pose and make animations out of it? I have a few ideas, but I cant quite code them, and also, i wouldnt mind if anyone out there could tell me how? I think it is just loading textures from different parts of the picture, but how would i load from a specific part of the picture??????

Share this post


Link to post
Share on other sites
jhavna    122
One way to do it is to draw the frame bitmap onto a hidden surface and then copy out the rectangle for each frame. You will need to know the dimensions of each frame and keep a reference to the frame numbers. Once you have copied them all out, you can get rid of the original imgage, as your frame data is stored in memory now.

hope that helps

Share this post


Link to post
Share on other sites