|
|
1.1 root 1: #ifndef __AMMAP_H__
2: #define __AMMAP_H__
3:
4: #pragma once
5:
6: // For use if I do walls with outsides/insides
7: #define REDS 12*8
8: #define REDRANGE 1//16
9: #define BLUES (256-4*16+8)
10: #define BLUERANGE 1//8
11: #define GREENS (33*8)
12: #define GREENRANGE 1//16
13: #define GRAYS (5*8)
14: #define GRAYSRANGE 1//16
15: #define BROWNS (14*8)
16: #define BROWNRANGE 1//16
17: #define YELLOWS 10*8
18: #define YELLOWRANGE 1
19: #define BLACK 0
20: #define WHITE 4*8
21: #define PARCH 13*8-1
22: #define BLOODRED 150
23: #define BLUEKEY 197
24: #define YELLOWKEY 144
25: #define GREENKEY 220
26:
27: // Automap colors
28: #define BACKGROUND PARCH
29: #define YOURCOLORS WHITE
30: #define YOURRANGE 0
31: #define WALLCOLORS REDS
32: #define WALLRANGE REDRANGE
33: #define TSWALLCOLORS GRAYS
34: #define TSWALLRANGE GRAYSRANGE
35: #define FDWALLCOLORS BROWNS
36: #define FDWALLRANGE BROWNRANGE
37: #define CDWALLCOLORS YELLOWS
38: #define CDWALLRANGE YELLOWRANGE
39: #define THINGCOLORS GREENS
40: #define THINGRANGE GREENRANGE
41: #define SECRETWALLCOLORS WALLCOLORS
42: #define SECRETWALLRANGE WALLRANGE
43: #define GRIDCOLORS (GRAYS + GRAYSRANGE/2)
44: #define GRIDRANGE 0
45: #define XHAIRCOLORS GRAYS
46:
47: // drawing stuff
48: #define FB 0
49:
50: #define KEY_TAB 9
51: #define AM_PANDOWNKEY KEY_DOWNARROW
52: #define AM_PANUPKEY KEY_UPARROW
53: #define AM_PANRIGHTKEY KEY_RIGHTARROW
54: #define AM_PANLEFTKEY KEY_LEFTARROW
55: //#define AM_PANDOWNKEY SC_DOWNARROW
56: //#define AM_PANUPKEY SC_UPARROW
57: //#define AM_PANRIGHTKEY SC_RIGHTARROW
58: //#define AM_PANLEFTKEY SC_LEFTARROW
59:
60: #define AM_ZOOMINKEY '='
61: //#define AM_ZOOMINKEY 13
62: //#define AM_ZOOMOUTKEY 12
63: #define AM_ZOOMOUTKEY '-'
64: #define AM_STARTKEY KEY_TAB
65: #define AM_ENDKEY KEY_TAB
66: #define AM_GOBIGKEY '0'
67: //#define AM_GOBIGKEY 11
68: //#define AM_FOLLOWKEY 33
69: //#define AM_GRIDKEY 34
70: #define AM_FOLLOWKEY 'f'
71: #define AM_GRIDKEY 'g'
72:
73: #define AM_NUMMARKPOINTS 10
74:
75: #define AM_MSGHEADER (('a'<<24)+('m'<<16))
76: #define AM_MSGENTERED (AM_MSGHEADER | ('e'<<8))
77: #define AM_MSGEXITED (AM_MSGHEADER | ('x'<<8))
78:
79: #define INITSCALEMTOF (.2*FRACUNIT) // scale on entry
80: // how much the automap moves window per tic in frame-buffer coordinates
81: #define F_PANINC 4 // moves 140 pixels in 1 second
82: // how much zoom-in per tic
83: #define M_ZOOMIN ((int) (1.02*FRACUNIT)) // goes to 2x in 1 second
84: // how much zoom-out per tic
85: #define M_ZOOMOUT ((int) (FRACUNIT/1.02)) // pulls out to 0.5x in 1 second
86:
87: // translates between frame-buffer and map distances
88: #define FTOM(x) FixedMul(((x)<<16),scale_ftom)
89: #define MTOF(x) (FixedMul((x),scale_mtof)>>16)
90: // translates between frame-buffer and map coordinates
91: #define CXMTOF(x) (f_x + MTOF((x)-m_x))
92: #define CYMTOF(y) (f_y + (f_h - MTOF((y)-m_y)))
93:
94: // the following is crap
95: #define LINE_NEVERSEE ML_DONTDRAW
96:
97: typedef struct
98: {
99: int x, y;
100: } fpoint_t;
101:
102: typedef struct
103: {
104: fpoint_t a, b;
105: } fline_t;
106:
107: typedef vertex_t mpoint_t;
108:
109: typedef struct
110: {
111: mpoint_t a, b;
112: } mline_t;
113:
114: typedef struct
115: {
116: fixed_t slp, islp;
117: } islope_t;
118:
119: // extern int f_x, f_y, f_w, f_h;
120:
121: #endif
This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.