Player.h 525 B

12345678910111213141516171819202122232425262728293031323334353637
  1. #pragma once
  2. #include "Vector.h"
  3. #include "Weapon.h"
  4. class Player
  5. {
  6. private:
  7. static Player* instance;
  8. void levelUp();
  9. public:
  10. Player();
  11. ~Player();
  12. void setCamera();
  13. void setPosition(float angle, float fac, bool height);
  14. void draw(void);
  15. static Player* getInstance(void);
  16. static void init(void);
  17. Vec3f position;
  18. Vec2f rotation;
  19. Weapon* leftWeapon;
  20. Weapon* rightWeapon;
  21. float health, maxHp;
  22. float xp, maxXp;
  23. int level;
  24. int crystals;
  25. float speed;
  26. void HpUp(int);
  27. void HpDown(int);
  28. void XpUp(int);
  29. };