add a basic Player class
This commit is contained in:
1 parent
2c7e454ca8
commit
a568ab8fa8
2 files changed
+27
No files matched your search
@@ -0,0 +1,9 @@
|
|||||||
|
|
||||||
|
#include "Player.h"
|
||||||
|
|
||||||
|
Player::Player()
|
||||||
|
{
|
||||||
|
x = 0.0;
|
||||||
|
y = 0.0;
|
||||||
|
direction = 0.0;
|
||||||
|
}
|
||||||
@@ -0,0 +1,18 @@
|
|||||||
|
|
||||||
|
#ifndef PLAYER_H
|
||||||
|
#define PLAYER_H
|
||||||
|
|
||||||
|
#include <string>
|
||||||
|
|
||||||
|
class Player
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
std::string name;
|
||||||
|
double x;
|
||||||
|
double y;
|
||||||
|
double direction; /* 0 = East, M_PI_2 = North, M_PI = West, ... */
|
||||||
|
|
||||||
|
Player();
|
||||||
|
};
|
||||||
|
|
||||||
|
#endif
|
||||||
Reference in new issue
Block a user