/src/MenuEnemy.h

http://github.com/clintbellanger/flare · C Header · 53 lines · 25 code · 7 blank · 21 comment · 0 complexity · 44d8f3e9b12f2f4f885c3045af59948b MD5 · raw file

  1. /*
  2. Copyright 2011 Pavel Kirpichyov (Cheshire)
  3. This file is part of FLARE.
  4. FLARE is free software: you can redistribute it and/or modify it under the terms
  5. of the GNU General Public License as published by the Free Software Foundation,
  6. either version 3 of the License, or (at your option) any later version.
  7. FLARE is distributed in the hope that it will be useful, but WITHOUT ANY
  8. WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A
  9. PARTICULAR PURPOSE. See the GNU General Public License for more details.
  10. You should have received a copy of the GNU General Public License along with
  11. FLARE. If not, see http://www.gnu.org/licenses/
  12. */
  13. /**
  14. * MenuEnemy
  15. *
  16. * Handles the display of the Enemy info of the screen
  17. */
  18. #ifndef MENU_ENEMY_H
  19. #define MENU_ENEMY_H
  20. #include "StatBlock.h"
  21. #include "Utils.h"
  22. #include "FontEngine.h"
  23. #include "SharedResources.h"
  24. #include "Enemy.h"
  25. #include <SDL.h>
  26. #include <SDL_image.h>
  27. const int MENU_ENEMY_TIMEOUT = FRAMES_PER_SEC * 10;
  28. class MenuEnemy {
  29. private:
  30. SDL_Surface *background;
  31. SDL_Surface *bar_hp;
  32. public:
  33. MenuEnemy();
  34. ~MenuEnemy();
  35. Enemy *enemy;
  36. void loadGraphics();
  37. void handleNewMap();
  38. void logic();
  39. void render();
  40. int timeout;
  41. };
  42. #endif