diff options
author | Jon Bergli Heier <snakebite@jvnv.net> | 2011-06-12 17:52:31 +0200 |
---|---|---|
committer | Jon Bergli Heier <snakebite@jvnv.net> | 2011-06-12 17:52:31 +0200 |
commit | d289e0eacbd00538ee2bcaedeba4366cc1e98231 (patch) | |
tree | 16d49421b24520c1728149f96a63635340e2e4a2 /player.h | |
parent | d94e9e78af4e59e27524556b828291c1dfb72407 (diff) |
Handle and render players with a placeholder texture.
Diffstat (limited to 'player.h')
-rw-r--r-- | player.h | 38 |
1 files changed, 38 insertions, 0 deletions
diff --git a/player.h b/player.h new file mode 100644 index 0000000..c5f558d --- /dev/null +++ b/player.h @@ -0,0 +1,38 @@ +#ifndef PLAYER_H +#define PLAYER_H + +#include "gl.h" +#include "vector.h" + +#include <boost/shared_ptr.hpp> +#include <boost/cstdint.hpp> + +#include <FTGL/ftgl.h> + +#include <list> + +class Player { + private: + uint32_t id; + std::string name; + Vector3 pos; + + float t; + + public: + typedef boost::shared_ptr<Player> p; + + Player(uint32_t id, Vector3& pos, const std::string name); + + uint32_t get_id(); + std::string get_name(); + Vector3 get_pos(); + + void set_pos(Vector3& pos); + + void render(FTFont *font, unsigned int steps, GLuint texture); +}; + +typedef std::list<Player::p> PlayerList; + +#endif |