|
SDLGameEngine
|
Parallax scrolling world with camera. More...
Go to the source code of this file.
Data Structures | |
| struct | SGELAYER |
| information about a layer More... | |
| struct | SGESTAGE |
| information about the stage More... | |
Defines | |
| #define | ABSOLUTE 0 |
| #define | RELATIVE 1 |
| #define | sgeStageGetSpriteGroup(stage, group) sgeArrayGet(stage->spriteGroups, group) |
| get a sprite group from the stage | |
Functions | |
| SGELAYER * | sgeLayerNew (SGESPRITE *sprite) |
| create a new layer from a sprite | |
| void | sgeLayerDestroy (SGELAYER *l) |
| destroy a layer and free the resources | |
| SGESTAGE * | sgeStageNew (int width, int height) |
| create a new stage | |
| void | sgeStageDestroy (SGESTAGE *s) |
| destroy a stage and free resources | |
| int | sgeStageAddLayer (SGESTAGE *s, SGESPRITE *sprite, int x, int y) |
| add a sprite as new layer to the stage | |
| void | sgeStageSetLayerHeight (SGESTAGE *s, int layer, int height) |
| change the height of a layer in the stage | |
| void | sgeStageSetLayerWidth (SGESTAGE *s, int layer, int width) |
| change the width of a layer in the stage | |
| void | sgeStageDrawLayer (SGESTAGE *s, SDL_Surface *dest, int layer) |
| draw a layer | |
| int | sgeStageAddSpriteGroup (SGESTAGE *s, SGESPRITEGROUP *g) |
| add a sprite group to the stage | |
| int | sgeStageAddSprite (SGESTAGE *s, int spriteGroup, SGESPRITE *sprite) |
| add a sprite to the stage | |
| void | sgeStageDrawSpriteGroup (SGESTAGE *s, int spriteGroup) |
| draw a sprite group to the screen | |
| void | sgeStageDrawSpriteGroups (SGESTAGE *s) |
| draw all sprite groups on the screen | |
| int | sgeStageSpriteGroupCollideSprite (SGESTAGE *s, int b, SGESPRITE *a, int orientation) |
| test if a sprite collides a sprite group | |
| int | sgeStageSpriteGroupCollideSpriteGroup (SGESTAGE *s, int a, int b, int orientationa) |
| test if two sprite groups within a scene have a collision | |
| SGEPOSITION * | sgeStageScreenToReal (SGESTAGE *s, int x, int y) |
| calculate thie position of a coordinate on screen within the stage | |
Parallax scrolling world with camera.
Definition in file sgestage.h.