Download presentation
Presentation is loading. Please wait.
Published byJimmy Durrance Modified over 9 years ago
1
UNIVERSITY OF KARACHI DEPARTMENT OF COMPUTER SCIENCE BSCS 514 KING OF FIGHTER GROUP MEMBER MUHAMMAD NOMAN SIDDQUI SYED BILAL RAZA TAHA HASSAN
2
TABLE OF CONTENTS BACKGROUND ANIMATION SPRITE SHEET ANIMATION MULTIPLE PRESS/RELEASE KEY COLLISION DETECTION FLIPPING THE CHARACTER BACKGROUND SOUND
3
HEADERS FILES HERO.H GLUT.H BMP.H RBGA.H MATH.H TIME.H WINDOWS.H
4
BACKGROUND ANIMATION Two ways to animate the background Moving the viewport Moving the texture
5
ANIMATION OF SPRITE SHEET WE HAVE ANIMATED_SPRITE CLASS FOR CHARACTER ANIMATION. THERE WERE TWO WAYS FOR CHARACTER ANIMATION USING SPRITE SHEET WITH UNEVEN FRAMES. ONE WAY WAS TO SAVE CORIDNATES OF FRAME PIXELS IN A NOTEPAD FILE AND THEN USE IT ACCORDINGLY. ANOTHER WAY WAS TO EQUAL THE FRAME OF CHARACTER SHEET BY USING IMAGE EDITTING SOFTWARE.
6
EVEN FRAME
7
UNEVEN FRAMES
8
MULTIPLE PRESS AND RELEASE KEY Two characters individual keys Using the technique of buffer and bool. We use an array of bool type and using it accordingly. Handling the movement of other character with this array.
9
FLIPPING THE CHARACTER Introducing a new technique for the other character of the game. Making a function “ultasprite” We invert the frame of sprite sheet. Flipping the the texture coordinates.
10
COLLISION DETECTION Several ways to detect the collision in the game Pixel perfect collision Box bounding collision Box bounding collision using vector The distance technique
11
BOX BOUNDING COLLISION DETECTION
12
SOME FLAWS OF DETECTION AND CHOOSING THE SUITABLE TECHNIQUE Which technique to use…….. Pixel perfect too complex Box bounding using vector is insufficient A little innovation in box bounding …… Using the distance formula according to the game…………..
Similar presentations
© 2025 SlidePlayer.com. Inc.
All rights reserved.