home *** CD-ROM | disk | FTP | other *** search
/ Collection of Hack-Phreak Scene Programs / cleanhpvac.zip / cleanhpvac / WD_SRC.ZIP / SOURCE / GLOBALS.HPP < prev    next >
C/C++ Source or Header  |  1995-01-12  |  2KB  |  85 lines

  1.  
  2. // By using BAMS, it's very fast to mask off and wrap angles.
  3. #define SIN(x)    ( SIN_TABLE[x] )
  4. #define COS(x)    ( SIN_TABLE[x+SIN_TO_COS_ADDER] )
  5. #define SAFE_SIN(x)    ( SIN_TABLE[x&ANGLE_MASK] )
  6. #define SAFE_COS(x)    ( SIN_TABLE[ (x+SIN_TO_COS_ADDER) & ANGLE_MASK ] )
  7. extern Fixed SIN_TABLE[ANGLE_RES];
  8.  
  9. // ArcCosine table, used for lighting calculations.
  10. extern Fixed ACOS_TABLE[ANGLE_RES];
  11.  
  12. // An ArcTangent lookup table.  Goes from atan(0) to atan(1).
  13. // Values are in fixed-point.  See BSP_GEN's GetAngle for an
  14. // example of using this table.
  15. extern Angle ATAN_TABLE[ANGLE_RES];
  16.  
  17. // Tells which video mode we're in:
  18. // 0 = 320x200
  19. // 1 = 320x240
  20. // 2 = 360x360
  21. // 3 = 360x480
  22. // 4 = 400x600
  23. extern WORD videoMode;
  24.  
  25. // These are what the routines in DRAW consider the screen boundaries.
  26. extern DWORD    s_DrawWidth, s_DrawHeight;
  27. extern DWORD    s_MinX, s_MaxX, s_MinY, s_MaxY;
  28.  
  29. // The screen width and height.
  30. extern DWORD s_Width, s_Height;
  31.  
  32. // The width (what you multiply Y coordinates by) in paged VGA.
  33. // In linear VGA, this is the same as s_Width;
  34. extern DWORD s_PagedWidth;
  35.  
  36. // A loopup table the size of s_Width to get the position in the screen memory
  37. // for a certain x coordinate.
  38. extern DWORD *s_PageLookup;
  39.  
  40. // The size of the screen in bytes.
  41. extern DWORD s_SizeBytes;
  42.  
  43. // A pointer to the offscreen buffer.
  44. extern BYTE *pScreenMem;
  45.  
  46. // The pointer to the actual VGA buffer.
  47. extern BYTE *pVgaMem;
  48.  
  49. // Number of colors in the palette maps.
  50. extern WORD nPaletteColors;
  51.  
  52. // Number of palette maps.
  53. extern WORD nPaletteMaps;
  54.  
  55. // The palette lookup table.
  56. extern BYTE **pPaletteMaps;
  57.  
  58. // The transparancy lookup.
  59. extern BYTE **pTranspal;
  60.  
  61. // What palette map to use on the parallaxing sky.
  62. extern WORD parallaxMap;
  63.  
  64. // The palette for making everything black and white.
  65. extern BYTE blackWhitePal[256];
  66.  
  67. // Tells if everything will be black and white.
  68. extern BOOL bBlackAndWhite;
  69.  
  70. // The distance away from you that things fade out at.
  71. extern WORD zFadeOut;
  72.  
  73. // Just stores the current level.
  74. extern Level curLevel;
  75.  
  76. // The player..
  77. extern Player player;
  78.  
  79. // Incremented every clock tick.
  80. extern DWORD timeCount;
  81.  
  82.  
  83. // Displays points at all the vertices.
  84. extern BOOL bDisplayProjectionPoints;
  85.