git-svn-id: https://aklabs.dyndns.org/svn/aklabs/trunk/games/spaceshooter@52 eb184899-6090-47d4-a65b-558f62f6ea1c
26 lines
573 B
C++
26 lines
573 B
C++
#ifndef __STARFIELDBACKGROUND_H__
|
|
#define __STARFIELDBACKGROUND_H__
|
|
|
|
#include <libgame/libgame.h>
|
|
|
|
class StarfieldBackground : public Actor
|
|
{
|
|
protected:
|
|
SDL_Surface *canvas;
|
|
unsigned int lockedFPS;
|
|
unsigned int lastTime;
|
|
std::vector<Vector> starpoints;
|
|
std::vector<Vector> starvelocities;
|
|
std::vector<SDL_Color> starcolors;
|
|
public:
|
|
StarfieldBackground();
|
|
~StarfieldBackground();
|
|
SDL_Surface *nextFrame();
|
|
void lockFPS(unsigned int fps);
|
|
void initStarfield(int w, int h);
|
|
void update();
|
|
};
|
|
|
|
|
|
#endif // __STARFIELDBACKGROUND_H__
|