-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathACKDATA.C
149 lines (124 loc) · 2.55 KB
/
ACKDATA.C
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
//#include <windows.h>
#include <stdio.h>
#include "ACK3D.H"
#include "ACKENG.H"
int32_t scPtr;
UCHAR *bmWall;
int32_t bmDistance;
int32_t BackDropRows;
USHORT ScreenOffset;
int32_t xPglobal;
int32_t yPglobal;
int32_t xBegGlobal;
int32_t yBegGlobal;
ACKENG *aeGlobal;
USHORT *xGridGlobal;
USHORT *yGridGlobal;
int32_t xPglobalHI;
int32_t yPglobalHI;
ULONG *rbaTable;
short rsHandle;
int32_t LastX1;
int32_t LastY1;
int32_t iLastX;
int32_t iLastY;
int32_t x_xPos;
int32_t x_yPos;
int32_t x_xNext;
int32_t x_yNext;
int32_t y_xPos;
int32_t y_yPos;
int32_t y_xNext;
int32_t y_yNext;
short MaxDistance;
short LightFlag;
short ErrorCode;
int32_t xMapPosn;
int32_t yMapPosn;
USHORT *Grid;
USHORT *ObjGrid;
SLICE Slice[VIEW_WIDTH];
SLICE *sPtr;
short TotalSpecial;
short DistanceTable[MAX_DISTANCE + 1];
int32_t *AdjustTable;
short xSecretmPos;
short xSecretmPos1;
short xSecretColumn;
short ySecretmPos;
short ySecretmPos1;
short ySecretColumn;
short TotalSecret;
short ViewColumn;
int32_t *SinTable;
int32_t *CosTable;
int32_t *LongTanTable;
int32_t *LongInvTanTable;
int32_t InvCosTable[INT_ANGLE_360];
int32_t InvSinTable[INT_ANGLE_360];
int32_t *LongCosTable;
int32_t *ViewCosTable;
int32_t *xNextTable;
int32_t *yNextTable;
short LastFloorAngle = -1;
short LastFloorX;
short LastFloorY;
short LastMapPosn;
short LastObjectHit;
short TotalObjects;
short FoundObjectCount;
UCHAR ObjectsSeen[MAX_OBJECTS + 1];
short MoveObjectCount;
UCHAR MoveObjectList[MAX_OBJECTS + 1];
UCHAR ObjNumber[MAX_OBJECTS + 1];
USHORT ObjRelDist[MAX_OBJECTS + 1];
short ObjColumn[MAX_OBJECTS + 1];
short ObjAngle[MAX_OBJECTS + 1];
short DirAngle[] =
{INT_ANGLE_270, INT_ANGLE_315, 0,
INT_ANGLE_45, INT_ANGLE_90,
INT_ANGLE_135, INT_ANGLE_180,
INT_ANGLE_225};
UCHAR WorkPalette[768];
UCHAR *BackArray[INT_ANGLE_360];
short Resolution;
int32_t Flooru;
int32_t Floorv;
int32_t Floordu;
int32_t Floordv;
int32_t Floorkx;
int32_t Floorky;
int32_t Floorku;
int32_t Floorkv;
int32_t Floorkdu;
int32_t Floorkdv;
UCHAR *Floorbm;
UCHAR *Floorscr;
UCHAR *FloorscrTop;
UCHAR *Floorptr2;
UCHAR *Floors1;
UCHAR *Floors2;
int32_t Floorht;
int32_t Floorwt;
short Floorvht;
short Flooreht;
int32_t FloorLastbNum;
int32_t FloorLastbm;
short ViewHeight = 31;
short CeilingHeight = 31;
short LastWallHeight;
short PlayerAngle;
short ViewAngle;
USHORT SysFlags;
UCHAR **WallbMaps;
UCHAR *VidTop;
UCHAR *VidBottom;
short BotRowTable[320];
USHORT FloorMap[4096];
USHORT CeilMap[4096];
UCHAR HitMap[4096];
UCHAR *VidSeg;
char *scantables[96];
UCHAR AckKeys[128]; // Buffer for keystrokes
int32_t AckTimerCounter;
// **** End of Data ****