-
Notifications
You must be signed in to change notification settings - Fork 0
/
config.h
201 lines (160 loc) · 6.42 KB
/
config.h
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
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
/*
* Local configuration file. All of these parameters are modifiable
* per-site. However, some of them probably shouldn't be.
*/
// vi:ts=4:sw=4:ai:
#include "copyright.h"
#include "command.h"
#ifndef _Config_h_
#define _Config_h_
/*
* General bits and pieces for game debugging
*/
#define CAST dynamic_cast
/*
* Things that used to be in the makefile, but aren't any more, because
* they're in here now, so as to take them out of the makefile, because
* that was too big. So now they're here, so this is bigger, but at
* least the makefile is smaller.
*/
#define STARTUP /* Look for .startup and .shutdown in #4 */
#define LOG_FAILED_COMMANDS /* Log all instances of failed commands */
#define RESTRICTED_BUILDING /* Need a BUILDER flag to build */
#define HACK_HUNTING /* Log use of wizard @chpids not set W */
#define LOG_RECURSION /* Log recursion overruns */
#define QUIET_WHISPER /* Other people's whispers are not shown */
#define ALIASES /* Are aliases operational? */
#define ABORT_FUSES /* Abort fuses are allowed */
#undef DARK_PLAYERS /* Dark players are allowed */
#undef LOG_COMMANDS /* Log _all_ commands. _BIG_ output */
#undef LOG_COMMAND_LINES /* Log only top-level commands - Not quite so big */
#undef CONCENTRATOR /* If the concentrator is to be used */
#undef LOG_NAME_CHANGES /* Log all player name changes */
#define LOG_WALLS /* Log all usage of @wall */
#undef LOCAL_CONNECTIONS_ONLY /* For use with the concentrator */
#undef DEBUG /* For debugging */
#undef MATCH_DEBUG /* Match debug lines */
#undef ID_MATCH_NEEDS_CONTROL_FOR_READ /* Do you need controls-for-read on something to use a #id on it? */
#define BUFFER_LEN ((MAX_COMMAND_LEN)*4)
/* Name change time in seconds */
#define NAME_TIME 300
#define STANDARD_ROOM_MASS 0
#define STANDARD_ROOM_VOLUME 0
#define STANDARD_ROOM_MASS_LIMIT HUGE_VAL
#define STANDARD_ROOM_VOLUME_LIMIT HUGE_VAL
#define STANDARD_ROOM_GRAVITY 0
#define STANDARD_PLAYER_MASS 70
#define STANDARD_PLAYER_VOLUME 75
#define STANDARD_PLAYER_MASS_LIMIT 15
#define STANDARD_PLAYER_VOLUME_LIMIT 400
#define STANDARD_PLAYER_GRAVITY 1
#define STANDARD_THING_MASS 0 /* Non-zero so that players can't have an easy life */
#define STANDARD_THING_VOLUME 0 /* with mass and volume - Lee */
#define STANDARD_THING_MASS_LIMIT 0
#define STANDARD_THING_VOLUME_LIMIT 0
#define STANDARD_THING_GRAVITY 1
#define NUM_INHERIT (-HUGE_VAL) /* if we come across this number it means inherit from parent */
#define LIMBO 0
#define GOD_ID 1
#define PLAYER_START 3
#define COMMAND_LAST_RESORT 4
/* minimum cost to create various things */
#define ALARM_COST 100
#define ARRAY_COST 10
#define COMMAND_COST 10
#define DICTIONARY_COST 10
#define EXIT_COST 1
#define FUSE_COST 10
#define LINK_COST 1
#define PROPERTY_COST 1
#define PUPPET_COST 200
#define ROOM_COST 20
#define THING_COST 10
#define VARIABLE_COST 3
/* cost to do a scan */
#define LOOKUP_COST 0
#define FIND_COST 0
#define PAGE_COST 0
#define ALARM_EXECUTE_COST 0
#define FUSE_EXECUTE_COST 0
/* magic cookies */
#define NOT_TOKEN '!'
#define LOOKUP_TOKEN '*'
#define NUMBER_TOKEN '#'
#define AND_TOKEN '&'
#define OR_TOKEN '|'
/* magic command cookies */
#define SAY_TOKEN '"'
#define ALT_SAY_TOKEN '\''
#define POSE_TOKEN ':'
#define NOTIFY_TOKEN ';'
#define COMMAND_TOKEN '@'
#define EXIT_DELIMITER ';'
#define TELL_TOKEN '>'
#define TELL_EMOTE_TOKEN '<'
#define MAX_BUILDING_POINTS 5000
/* timing stuff */
#define DUMP_INTERVAL 2400 /* seconds between dumps (may be overridden on command line) */
#define COMMAND_TIME_MSEC 250 /* time slice length in milliseconds */
#define COMMAND_BURST_SIZE 2 /* commands per user in a burst */
#define COMMANDS_PER_TIME 1 /* commands/time slice after burst */
#define ALARM_RESOLUTION_SECONDS 5 /* The resolution of alarms */
/* Maximum number of compound commands executed in response to one user-typed command */
#define COMPOUND_COMMAND_BASE_LIMIT 100
#define COMPOUND_COMMAND_MAXIMUM_LIMIT 1500
/* maximum amount of queued output */
#define MAX_OUTPUT 16384
/* Absolute nice level at which to run mud */
#define MUD_NICE_LEVEL 0
/* Maximum number of users permitted */
#define MAX_USERS 120
#define TINYPORT 6239
#define WELCOME_MESSAGE "\n\tWelcome to UglyMUG!\nTo connect to your existing character, use \"connect name password\".\nTo create a new character, use \"create name password\".\n\nDisconnect with \"QUIT\", which must be capitalized as shown.\n\n\"WHO\" finds out who is currently active.\n\n"
#define LEAVE_MESSAGE "\nBye - see you soon!\n"
#define CONC_PORT 16309
#define CONC_MACHINE 0x82580dbe /* pasteur.cs.man.ac.uk */
#define QUIT_COMMAND "QUIT"
#define WHO_COMMAND "WHO"
#define INFO_COMMAND "INFO"
#define IDLE_COMMAND "IDLE"
#define PREFIX_COMMAND "OUTPUTPREFIX"
#define SUFFIX_COMMAND "OUTPUTSUFFIX"
#define HALFQUIT_COMMAND "HALFQUIT"
/* The amount of time that the IDLE command increases your idle to in seconds */
#define IDLE_TIME_INCREASE 180
#define WELCOME_FILE "motd.txt"
#define SMD_FILE "smd.list"
#define EMAIL_FILE "email.list"
/* This is the address that all non-player specific logs go to. */
#define LOG_EMAIL "otherlogs@uglymug.org.uk"
const unsigned int MAX_MORTAL_ARRAY_ELEMENTS=100;
const unsigned int MAX_WIZARD_ARRAY_ELEMENTS=750;
#define MAX_MORTAL_DICTIONARY_ELEMENTS 100
/* Increased to make help work as everyone is too lazy to fix it. */
#define MAX_WIZARD_DICTIONARY_ELEMENTS 750
#define MAX_MORTAL_DESC_SIZE 2048
#define MAX_WIZARD_DESC_SIZE 2048
#define MAX_NAME_LENGTH 20
#define MAX_ALIASES 5
#define MIN_ALIAS_LENGTH 3
#define MAX_ALIAS_LENGTH MAX_NAME_LENGTH
#define MAX_WHO_STRING 80
#define DEFAULT_RECALL_LINES 50
#define MAX_RECALL_LINES 400
#define CURRENCY_NAME "Drogna"
/* The termcap compat libraries on linux are becoming increasingly unsupported.
* I recommend using this so you don't have to link with two versions of libc
* which seems rather dodgy. -Abs
*/
#define USE_TERMINFO
/* Chat channels.*/
#define CHANNEL_MAGIC_COOKIE '#'
#define CHANNEL_INVITE_FREQUENCY 60
/* Acceptable character set (currently ISO-8859-15).
For systems that don't support this standard, use the second definition below. */
inline bool is_printable(const unsigned char c) { return ((c >= 0x20) && (c <= 0x7e)) || (c >=0xa0); }
/*
#define is_printable(c) (((unsigned char)(c)>=0x20 && (unsigned char)(c)<=0x7e) \
|| ((unsigned char)(c)>=0xa0 && (unsigned char)(c)<=0xff))*/
/*#define is_printable(c) isprint((c))*/
#endif