toolbar.h 2.6 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273
  1. ////////////////////////////////////////////////////////////////////////////////
  2. //
  3. // Copyright 2016 RWS Inc, All Rights Reserved
  4. //
  5. // This program is free software; you can redistribute it and/or modify
  6. // it under the terms of version 2 of the GNU General Public License as published by
  7. // the Free Software Foundation
  8. //
  9. // This program is distributed in the hope that it will be useful,
  10. // but WITHOUT ANY WARRANTY; without even the implied warranty of
  11. // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  12. // GNU General Public License for more details.
  13. //
  14. // You should have received a copy of the GNU General Public License along
  15. // with this program; if not, write to the Free Software Foundation, Inc.,
  16. // 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
  17. //
  18. // toolbar.h
  19. // Project: Nostril (aka Postal)
  20. //
  21. // This module augments the CDude class, which used to be soley responsible for
  22. // updating player and weapon status. It currently graphically manages the
  23. // toolbars and sound reactions. (Still need to add sounds)
  24. ////////////////////////////////////////////////////////////////////////////////
  25. //
  26. // History:
  27. //
  28. // 08/06/97 JRD Started. Set bars to load in the realm
  29. //
  30. // 08/08/97 JRD Changed methodology to a proprietary data format and abandoning
  31. // attempts of a one to one interface with postal. Tollbar will
  32. // update an internal map of the weapon states based on events
  33. // passed.
  34. //
  35. // 08/08/97 JRD Completely revamped and finalized the class structure.
  36. // Added the first hook to draw the entire bar.
  37. // Added aliased functions to reduce header dependencies.
  38. // 08/09/97 JRD Added all functionality except a hook to refresh on event.
  39. //
  40. // 08/25/97 JMI Moved gsStatus* here from score.cpp.
  41. //
  42. ////////////////////////////////////////////////////////////////////////////////
  43. #ifndef TOOL_BAR_H
  44. #define TOOL_BAR_H
  45. #include "RSPiX.h"
  46. #include "hood.h"
  47. // Because I do NOT yet want to be forced to put the entire clas in the header, I
  48. // am ALIASING the hooks to the toolbar so recompiles will be minimal:
  49. // This should be done everytime the hood's palette changes.
  50. extern short ToolBarInit(CHood* pHood);
  51. // This does a FULL regeneration of the toolbar and draws it in yout area.
  52. // It returns false if it isn't time to render.
  53. extern bool ToolBarRender(
  54. CHood* pHood,
  55. RImage* pimDst,
  56. short sDstX,
  57. short sDstY,
  58. CDude* pDude,
  59. bool bForceRender = false
  60. );
  61. extern short gsStatusFontForeIndex;
  62. extern short gsStatusFontBackIndex;
  63. extern short gsStatusFontShadowIndex;
  64. extern short gsStatusFontForeDeadIndex;
  65. #endif