ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/deliantra/server/include/preprocess
Revision: 1.28
Committed: Thu May 17 14:14:55 2007 UTC (17 years ago) by root
Branch: MAIN
Changes since 1.27: +0 -2 lines
Log Message:
remove superfluous/broken settings and related code

- COZY_SERVER:
  enabled most msall adjustments, changed digestion formula to the original one,
  party member treament w.r.t. pets enforced.
- PROHIBIT_PLAYERKILL: default
- real_wiz: removed and enforced
- create_home_portals: removed and enforced
- casting_time: removed and forced to be off (was crashing anyways)
- was_wiz flag removed and treated as off usually unless it was used
  in place of flag_wiz.
- do not save or restore wiz, wizcast and wizpass flags.

File Contents

# User Rev Content
1 root 1.1 #!/opt/bin/perl
2    
3 root 1.8 my %ARG = @ARGV;
4    
5 root 1.3 use List::Util;
6    
7 root 1.1 # todo: gather dynamically
8     my @kw = qw(
9 root 1.4 no_pass
10     walk_on
11     walk_off
12     fly_on
13     fly_off
14     flying
15    
16 root 1.25 attack_skill
17     ranged_skill
18    
19 root 1.1 ac
20     activate_on_push
21     activate_on_release
22     alive
23     anim_speed
24     animation
25     applied
26     arch
27     armour
28     attach
29     attack_movement
30     attacktype
31     auto_apply
32     been_applied
33     berserk
34     blocksview
35     body_range
36     body_arm
37     body_torso
38     body_head
39     body_neck
40     body_skill
41     body_finger
42     body_shoulder
43     body_foot
44     body_hand
45     body_wrist
46     body_waist
47 root 1.27 body_shield
48     body_combat
49 root 1.1 can_apply
50     can_cast_spell
51     can_roll
52     can_see_in_dark
53     can_use_armour
54     can_use_bow
55     can_use_horn
56     can_use_range
57     can_use_ring
58     can_use_rod
59     can_use_scroll
60     can_use_shield
61     can_use_skill
62     can_use_wand
63     can_use_weapon
64     carrying
65     casting_time
66     cha
67     changing
68     client_type
69     con
70     confused
71     connected
72     container
73     cursed
74     custom_name
75     dam
76     dam_modifier
77     damned
78 root 1.12 destroy_on_death
79 root 1.1 dex
80     direction
81     duration
82     duration_modifier
83     editable
84     editor_folder
85     elevation
86     end
87     endlore
88     endmsg
89     exp
90     expmul
91     face
92     food
93     friendly
94     gen_sp_armour
95     generator
96     glow_radius
97     grace
98     has_ready_bow
99     has_ready_scroll
100     has_ready_skill
101     has_ready_weapon
102 root 1.7 has_ready_range
103 root 1.1 hitback
104     hp
105     identified
106     immune
107 root 1.23 inherit
108 root 1.1 int
109     inv_locked
110     invisible
111     is_animated
112     is_blind
113     is_buildable
114     is_cauldron
115 root 1.7 is_dust
116 root 1.1 is_floor
117     is_hilly
118     is_lightable
119     is_thrown
120     is_turnable
121     is_used_up
122     is_water
123     is_wooded
124     item_power
125     known_cursed
126     known_magical
127     last_eat
128     last_grace
129     last_heal
130     last_sp
131     level
132     lifesave
133     lore
134     luck
135     magic
136     make_invisible
137     material
138     materialname
139     maxgrace
140     maxhp
141     maxsp
142     monster
143     more
144     move_allow
145     move_block
146     move_off
147     move_on
148     move_slow
149     move_slow_penalty
150     move_state
151     move_type
152     msg
153     name
154     name_pl
155     neutral
156     no_attack
157     no_damage
158     no_drop
159     no_fix_player
160     no_magic
161     no_pick
162     no_skill_ident
163     no_steal
164     no_strength
165     nrof
166 root 1.13 obj_original
167 root 1.1 object
168     oid
169     one_hit
170     only_attack
171     other_arch
172     overlay_floor
173     path_attuned
174     path_denied
175     path_repelled
176     perm_exp
177     pick_up
178 root 1.7 player_sold
179 root 1.1 pow
180 root 1.24 precious
181 root 1.1 protected
182     race
183     random_move
184     random_movement
185     randomitems
186     range
187     range_modifier
188     reflect_missile
189     reflect_spell
190     reflecting
191     resist_acid
192     resist_blind
193     resist_cancellation
194     resist_chaos
195     resist_cold
196     resist_confusion
197     resist_counterspell
198     resist_death
199     resist_deplete
200     resist_disease
201     resist_drain
202     resist_electricity
203     resist_fear
204     resist_fire
205     resist_ghosthit
206     resist_godpower
207     resist_holyword
208     resist_internal
209     resist_life_stealing
210     resist_magic
211     resist_paralyze
212     resist_physical
213     resist_poison
214     resist_slow
215     resist_turn_undead
216     resist_weaponmagic
217     run_away
218     scared
219     see_anywhere
220     see_invisible
221     skill
222     slaying
223     sleep
224     slow_move
225     smoothlevel
226     sp
227     speed
228     speed_left
229     splitting
230     stand_still
231     startequip
232     state
233     stealth
234     str
235     subtype
236     tear_down
237     title
238     tooltype
239 root 1.24 treasure_env
240 root 1.1 type
241     unaggressive
242     undead
243     unique
244     unpaid
245     use_content_on_gen
246 root 1.6 uuid
247 root 1.1 value
248     vulnerable
249     wc
250     weapontype
251     weight
252     will_apply
253     wis
254     x
255     xrays
256     y
257 root 1.5
258 root 1.9 maplore
259     endmaplore
260     enter_x
261     enter_y
262     width
263     height
264     reset_timeout
265     reset_time
266     swap_time
267     difficulty
268     darkness
269     fixed_resettime
270     per_player
271     per_party
272     region
273     shopitems
274     shopgreed
275     shopmin
276     shopmax
277     shoprace
278     outdoor
279     tile_path_1
280     tile_path_2
281     tile_path_3
282     tile_path_4
283    
284     file_format_version
285    
286     temp
287     pressure
288     humid
289     windspeed
290     winddir
291     sky
292 root 1.10
293     map
294     savebed_map
295     bed_x
296     bed_y
297     password
298     bowtype
299     petmode
300     gen_hp
301     gen_sp
302     gen_grace
303     listening
304     peaceful
305     digestion
306     pickup
307     outputs_sync
308     outputs_count
309     usekeys
310     unapply
311     weapon_sp
312     lev_array
313     endplst
314 root 1.14
315     visibility
316     magicmap
317    
318 root 1.21 match
319 root 1.14 parent
320     longname
321 root 1.15 jail_map
322     jail_x
323     jail_y
324 root 1.14 fallback
325     nomore
326 root 1.16
327     chance
328     mods
329     diff
330     saves
331     description
332     density
333     damage
334 root 1.17
335     anim
336     mina
337     facings
338 root 1.18 player
339 root 1.19
340     allowed
341     keycode
342     trans
343     yield
344     ingred
345     cauldron
346    
347     Str
348     Dex
349     Con
350     Wis
351     Cha
352     Int
353     Pow
354 root 1.22
355     treasure
356     treasureone
357     list
358     change_name
359     change_title
360     change_slaying
361     yes
362     no
363 root 1.1 );
364    
365 root 1.8 open GPERF, "|-", "exec $ARG{GPERF} -m50 >kw_hash.h"
366     or die "$ARGV{GPERF}: $!";
367 root 1.1
368     print GPERF <<EOF;
369     %language=C++
370     %enum
371     %define class-name kw_lex
372     %define lookup-function-name match
373     %struct-type
374     %compare-strncmp
375     %delimiters=,
376 root 1.2 struct keyword_idx { const char *name; enum keyword index; };
377 root 1.1 %%
378     EOF
379    
380     for (@kw) {
381 root 1.3 printf GPERF "%s,%s\n", $_, "KW_$_";
382 root 1.1 }
383    
384     print GPERF <<EOF;
385     %%
386 root 1.3 extern const char *const keyword_str [] = {
387 root 1.1 "<EOF>",
388     "<ERROR>",
389     EOF
390    
391     for (@kw) {
392     printf GPERF " \"%s\",\n", $_;
393     }
394    
395 root 1.3 print GPERF "};\n";
396    
397     printf GPERF "\nextern const unsigned char keyword_len [] = { 5, 7, %s };\n\n",
398     join ", ", map length, @kw;
399 root 1.1
400 root 1.8 close GPERF
401     or die "$ARG{GPERF}: failed to run";
402    
403 root 1.1 open KW, ">", "keyword.h";
404    
405     print KW <<EOF;
406     #ifndef KW_H__
407     #define KW_H__
408    
409     enum keyword {
410 root 1.7 KW_NULL = 0,
411     KW_EOF = 0,
412     KW_ERROR,
413 root 1.1 EOF
414    
415     for (@kw) {
416 root 1.3 printf KW " %s,\n", "KW_$_",
417 root 1.1 }
418    
419     print KW <<EOF;
420     NUM_KEYWORD,
421     };
422    
423     extern const char *const keyword_str [];
424 root 1.3 extern const unsigned char keyword_len [];
425    
426     EOF
427    
428     printf KW "#define MAX_KEYWORD_LEN %d\n", List::Util::max map length, @kw;
429    
430     print KW <<EOF;
431 root 1.1
432     #endif
433    
434     EOF
435