Open Source Tomb Raider Engine
Nevar pievienot vairāk kā 25 tēmas Tēmai ir jāsākas ar burtu vai ciparu, tā var saturēt domu zīmes ('-') un var būt līdz 35 simboliem gara.

Game.h 1.3KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970
  1. /*!
  2. * \file include/Game.h
  3. * \brief Game abstraction
  4. *
  5. * \author xythobuz
  6. */
  7. #ifndef _GAME_H_
  8. #define _GAME_H_
  9. #include <vector>
  10. #include "Camera.h"
  11. #include "global.h"
  12. #include "Render.h"
  13. #include "TombRaider.h"
  14. #include "World.h"
  15. /*!
  16. * \brief Game abstraction
  17. */
  18. class Game {
  19. public:
  20. Game();
  21. ~Game();
  22. int initialize();
  23. int loadLevel(const char *level);
  24. void destroy();
  25. void handleAction(ActionEvents action, bool isFinished);
  26. void handleMouseMotion(int xrel, int yrel);
  27. void display();
  28. int command(std::vector<char *> *args);
  29. //! \fixme should be private
  30. entity_t *mLara;
  31. Render *mRender;
  32. Camera *mCamera;
  33. private:
  34. void processPakSounds();
  35. void processTextures();
  36. void processSprites();
  37. void processMoveables();
  38. void processMoveable(int index, int i, int *ent,
  39. std::vector<skeletal_model_t *> &cache2,
  40. std::vector<unsigned int> &cache, int object_id);
  41. void processModels();
  42. void processRooms();
  43. void setupTextureColor(texture_tri_t *r_tri, float *colorf);
  44. bool mLoaded;
  45. char *mName;
  46. TombRaider mTombRaider;
  47. unsigned int mTextureStart;
  48. unsigned int mTextureLevelOffset;
  49. unsigned int mTextureOffset;
  50. };
  51. #endif