CrystalPoint.h 680 B

1234567891011121314151617181920212223242526272829303132333435363738394041424344
  1. #pragma once
  2. class WorldHandler;
  3. class SoundSystem;
  4. class Player;
  5. #include "Vector.h"
  6. #include "SoundSystem.h"
  7. #include "ControllerHandler.h"
  8. class KeyboardState
  9. {
  10. public:
  11. bool keys[256];
  12. bool special[256];
  13. bool control, shift, alt;
  14. KeyboardState();
  15. };
  16. class CrystalPoint
  17. {
  18. public:
  19. void init();
  20. void draw();
  21. void update();
  22. WorldHandler* worldhandler;
  23. Player* player;
  24. ControllerHandler controller;
  25. static int width, height;
  26. KeyboardState keyboardState;
  27. KeyboardState prevKeyboardState;
  28. Vec2f mouseOffset;
  29. Vec2f mousePosition;
  30. float lastFrameTime;
  31. static SoundSystem& GetSoundSystem() { return sound_system; }
  32. private:
  33. static SoundSystem sound_system;
  34. };