ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/deliantra/server/include/sproto.h
(Generate patch)

Comparing deliantra/server/include/sproto.h (file contents):
Revision 1.6 by root, Sun May 7 13:56:22 2006 UTC vs.
Revision 1.36 by root, Fri Jan 5 10:50:47 2007 UTC

1int same_party (partylist *a, partylist *b);
1/* alchemy.c */ 2/* alchemy.c */
3int need_identify (const object *obj);
4int apply_shop_mat (object *shop_mat, object *op);
5const char *cost_string_from_value(sint64 cost, int approx);
6void pay_player (object *pl, sint64 amount);
7sint64 pay_player_arch (object *pl, const char *arch, sint64 amount);
2void attempt_do_alchemy(object *caster, object *cauldron); 8void attempt_do_alchemy(object *caster, object *cauldron);
3int content_recipe_value(object *op); 9int content_recipe_value(object *op);
4int numb_ob_inside(object *op); 10int numb_ob_inside(object *op);
5object *attempt_recipe(object *caster, object *cauldron, int ability, recipe *rp, int nbatches); 11object *attempt_recipe(object *caster, object *cauldron, int ability, recipe *rp, int nbatches);
6void adjust_product(object *item, int lvl, int yield); 12void adjust_product(object *item, int lvl, int yield);
36int unapply_for_ob(object *who, object *op, int aflags); 42int unapply_for_ob(object *who, object *op, int aflags);
37int can_apply_object(object *who, object *op); 43int can_apply_object(object *who, object *op);
38int apply_special(object *who, object *op, int aflags); 44int apply_special(object *who, object *op, int aflags);
39int monster_apply_special(object *who, object *op, int aflags); 45int monster_apply_special(object *who, object *op, int aflags);
40int auto_apply(object *op); 46int auto_apply(object *op);
41void fix_auto_apply(mapstruct *m); 47void fix_auto_apply(maptile *m);
42void eat_special_food(object *who, object *food); 48void eat_special_food(object *who, object *food);
43void apply_lighter(object *who, object *lighter); 49void apply_lighter(object *who, object *lighter);
44void scroll_failure(object *op, int failure, int power); 50void scroll_failure(object *op, int failure, int power);
45void apply_changes_to_player(object *pl, object *change); 51void apply_changes_to_player(object *pl, object *change);
46void apply_item_transformer(object *pl, object *transformer); 52void apply_item_transformer(object *pl, object *transformer);
74int find_unused_connected_value(struct mapdef *map); 80int find_unused_connected_value(struct mapdef *map);
75int find_or_create_connection_for_map(object *pl, short x, short y, object *rune); 81int find_or_create_connection_for_map(object *pl, short x, short y, object *rune);
76object *get_connection_rune(object *pl, short x, short y); 82object *get_connection_rune(object *pl, short x, short y);
77object *get_msg_book(object *pl, short x, short y); 83object *get_msg_book(object *pl, short x, short y);
78object *get_wall(struct mapdef *map, int x, int y); 84object *get_wall(struct mapdef *map, int x, int y);
79void fix_walls(struct mapdef *map, int x, int y); 85void fix_walls(maptile *map, int x, int y);
86void fix_walls_around(maptile *map, int x, int y);
80void apply_builder_floor(object *pl, object *material, short x, short y); 87void apply_builder_floor(object *pl, object *material, short x, short y);
81void apply_builder_wall(object *pl, object *material, short x, short y); 88void apply_builder_wall(object *pl, object *material, short x, short y);
82void apply_builder_item(object *pl, object *item, short x, short y); 89void apply_builder_item(object *pl, object *item, short x, short y);
83void apply_builder_remove(object *pl, int dir); 90void apply_builder_remove(object *pl, int dir);
84void apply_map_builder(object *pl, int dir); 91void apply_map_builder(object *pl, int dir);
153int command_bug(object *op, char *params); 160int command_bug(object *op, char *params);
154void malloc_info(object *op); 161void malloc_info(object *op);
155void current_region_info(object *op); 162void current_region_info(object *op);
156void current_map_info(object *op); 163void current_map_info(object *op);
157int command_whereabouts(object *op, char *params); 164int command_whereabouts(object *op, char *params);
158int command_who(object *op, char *params);
159void display_who_entry(object *op, player *pl, const char *format);
160void get_who_escape_code_value(char *return_val, const char letter, player *pl);
161int command_afk(object *op, char *params); 165int command_afk(object *op, char *params);
162int command_malloc(object *op, char *params); 166int command_malloc(object *op, char *params);
163int command_mapinfo(object *op, char *params); 167int command_mapinfo(object *op, char *params);
164int command_whereami(object *op, char *params); 168int command_whereami(object *op, char *params);
165int command_maps(object *op, char *params); 169int command_maps(object *op, char *params);
221int command_southeast(object *op, char *params); 225int command_southeast(object *op, char *params);
222int command_southwest(object *op, char *params); 226int command_southwest(object *op, char *params);
223int command_west(object *op, char *params); 227int command_west(object *op, char *params);
224int command_stay(object *op, char *params); 228int command_stay(object *op, char *params);
225/* c_new.c */ 229/* c_new.c */
226int execute_newserver_command(object *pl, char *command); 230void execute_newserver_command(object *pl, char *command);
227int command_run(object *op, char *params); 231int command_run(object *op, char *params);
228int command_run_stop(object *op, char *params); 232int command_run_stop(object *op, char *params);
229int command_fire(object *op, char *params); 233int command_fire(object *op, char *params);
230int command_fire_stop(object *op, char *params); 234int command_fire_stop(object *op, char *params);
231int bad_command(object *op, char *params); 235int bad_command(object *op, char *params);
284int command_banish(object *op, char *params); 288int command_banish(object *op, char *params);
285int command_kick(object *op, char *params); 289int command_kick(object *op, char *params);
286int command_save_overlay(object *op, char *params); 290int command_save_overlay(object *op, char *params);
287int command_toggle_shout(object *op, char *params); 291int command_toggle_shout(object *op, char *params);
288int command_shutdown(object *op, char *params); 292int command_shutdown(object *op, char *params);
289int command_goto(object *op, char *params);
290int command_generate(object *op, char *params);
291int command_freeze(object *op, char *params); 293int command_freeze(object *op, char *params);
292int command_arrest(object *op, char *params); 294int command_arrest(object *op, char *params);
293int command_summon(object *op, char *params); 295int command_summon(object *op, char *params);
294int command_teleport(object *op, char *params); 296int command_teleport(object *op, char *params);
295int command_create(object *op, char *params); 297int command_create(object *op, char *params);
329int command_insert_into(object *op, char *params); 331int command_insert_into(object *op, char *params);
330/* commands.c */ 332/* commands.c */
331void init_commands(void); 333void init_commands(void);
332CommFunc find_oldsocket_command(char *cmd); 334CommFunc find_oldsocket_command(char *cmd);
333CommFunc find_oldsocket_command2(char *cmd); 335CommFunc find_oldsocket_command2(char *cmd);
334int parse_string(object *op, char *str);
335int parse_command(object *op, char *str);
336/* daemon.c */ 336/* daemon.c */
337FILE *BecomeDaemon(char *filename); 337FILE *BecomeDaemon(const char *filename);
338/* disease.c */ 338/* disease.c */
339int move_disease(object *disease); 339int move_disease(object *disease);
340int remove_symptoms(object *disease); 340int remove_symptoms(object *disease);
341object *find_symptom(object *disease); 341object *find_symptom(object *disease);
342int check_infection(object *disease); 342int check_infection(object *disease);
413void rec_sighup(int i); 413void rec_sighup(int i);
414void rec_sigquit(int i); 414void rec_sigquit(int i);
415void rec_sigpipe(int i); 415void rec_sigpipe(int i);
416void rec_sigbus(int i); 416void rec_sigbus(int i);
417void rec_sigterm(int i); 417void rec_sigterm(int i);
418void fatal_signal(int make_core, int close_sockets);
419void init_signals(void); 418void init_signals(void);
420void init_races(void); 419void init_races(void);
421void dump_races(void); 420void dump_races(void);
422void add_to_racelist(const char *race_name, object *op); 421void add_to_racelist(const char *race_name, object *op);
423racelink *get_racelist(void); 422racelink *get_racelist(void);
424racelink *find_racelink(const char *name); 423racelink *find_racelink(const char *name);
425/* login.c */ 424/* login.c */
426void emergency_save(int flag);
427void delete_character(const char *name, int new); 425void delete_character(const char *name);
428int verify_player(const char *name, char *password); 426int verify_player(const char *name, char *password);
429int check_name(player *me, const char *name); 427int check_name(player *me, const char *name);
430int create_savedir_if_needed(char *savedir); 428int create_savedir_if_needed(char *savedir);
431void destroy_object(object *op); 429void destroy_object(object *op);
432int save_player(object *op, int flag);
433void copy_file(const char *filename, FILE *fpout); 430void copy_file(const char *filename, FILE *fpout);
434void check_login(object *op);
435/* main.c */ 431/* main.c */
432void server_tick ();
436void version(object *op); 433void version(object *op);
437void info_keys(object *op); 434void info_keys(object *op);
438void start_info(object *op);
439char *crypt_string(char *str, char *salt); 435char *crypt_string(char *str, char *salt);
440int check_password(char *typed, char *crypted); 436int check_password(char *typed, char *crypted);
441void enter_player_savebed(object *op); 437void enter_player_savebed(object *op);
442void leave_map(object *op); 438void leave_map(object *op);
443void set_map_timeout(mapstruct *oldmap); 439void set_map_timeout(maptile *oldmap);
444char *clean_path(const char *file); 440char *clean_path(const char *file);
445char *unclean_path(const char *src); 441char *unclean_path(const char *src);
446void enter_exit(object *op, object *exit_ob); 442void enter_exit(object *op, object *exit_ob);
447void process_active_maps(void);
448void process_players1(mapstruct *map);
449void process_players2(mapstruct *map);
450void process_events(mapstruct *map); 443void process_events();
451void clean_tmp_files(void); 444void clean_tmp_files(void);
452void cleanup(void);
453void leave(player *pl, int draw_exit); 445void leave(player *pl,int draw_exit);
454int forbid_play(void); 446int forbid_play(void);
455void do_specials(void); 447void do_specials(void);
456int main(int argc, char **argv); 448int main(int argc, char **argv);
457/* monster.c */ 449/* monster.c */
458object *check_enemy(object *npc, rv_vector *rv); 450object *check_enemy(object *npc, rv_vector *rv);
486void pace_movev(object *ob); 478void pace_movev(object *ob);
487void pace_moveh(object *ob); 479void pace_moveh(object *ob);
488void pace2_movev(object *ob); 480void pace2_movev(object *ob);
489void pace2_moveh(object *ob); 481void pace2_moveh(object *ob);
490void rand_move(object *ob); 482void rand_move(object *ob);
491void check_earthwalls(object *op, mapstruct *m, int x, int y); 483void check_earthwalls(object *op, maptile *m, int x, int y);
492void check_doors(object *op, mapstruct *m, int x, int y); 484void check_doors(object *op, maptile *m, int x, int y);
493void communicate(object *op, const char *txt); 485void communicate(object *op, const char *txt);
494int talk_to_npc(object *op, object *npc, const char *txt); 486int talk_to_npc(object *op, object *npc, const char *txt);
495int talk_to_wall(object *pl, object *npc, const char *txt); 487int talk_to_wall(object *pl, object *npc, const char *txt);
496object *find_mon_throw_ob(object *op); 488object *find_mon_throw_ob(object *op);
497int can_detect_enemy(object *op, object *enemy, rv_vector *rv); 489int can_detect_enemy(object *op, object *enemy, rv_vector *rv);
501int move_object(object *op, int dir); 493int move_object(object *op, int dir);
502int move_ob(object *op, int dir, object *originator); 494int move_ob(object *op, int dir, object *originator);
503int transfer_ob(object *op, int x, int y, int randomly, object *originator); 495int transfer_ob(object *op, int x, int y, int randomly, object *originator);
504int teleport(object *teleporter, uint8 tele_type, object *user); 496int teleport(object *teleporter, uint8 tele_type, object *user);
505void recursive_roll(object *op, int dir, object *pusher); 497void recursive_roll(object *op, int dir, object *pusher);
506int try_fit(object *op, mapstruct *m, int x, int y); 498int try_fit(object *op, maptile *m, int x, int y);
507int roll_ob(object *op, int dir, object *pusher); 499int roll_ob(object *op, int dir, object *pusher);
508int push_ob(object *who, int dir, object *pusher); 500int push_ob(object *who, int dir, object *pusher);
509/* pets.c */ 501/* pets.c */
510object *get_pet_enemy(object *pet, rv_vector *rv); 502object *get_pet_enemy(object *pet, rv_vector *rv);
511void terminate_all_pets(object *owner); 503void terminate_all_pets(object *owner);
512void remove_all_pets(mapstruct *map); 504void remove_all_pets(maptile *map);
513void follow_owner(object *ob, object *owner); 505int follow_owner(object *ob, object *owner);
514void pet_move(object *ob); 506void pet_move(object *ob);
515object *fix_summon_pet(archetype *at, object *op, int dir, int is_golem); 507object *fix_summon_pet(archetype *at, object *op, int dir, int is_golem);
516void move_golem(object *op); 508void move_golem(object *op);
517void control_golem(object *op, int dir); 509void control_golem(object *op, int dir);
518int summon_golem(object *op, object *caster, int dir, object *spob); 510int summon_golem(object *op, object *caster, int dir, object *spob);
525player *find_player_partial_name(const char *plname); 517player *find_player_partial_name(const char *plname);
526void display_motd(const object *op); 518void display_motd(const object *op);
527void send_rules(const object *op); 519void send_rules(const object *op);
528void send_news(const object *op); 520void send_news(const object *op);
529int playername_ok(const char *cp); 521int playername_ok(const char *cp);
530int add_player(NewSocket *ns);
531archetype *get_player_archetype(archetype *at); 522archetype *get_player_archetype(archetype *at);
532object *get_nearest_player(object *mon); 523object *get_nearest_player(object *mon);
533int path_to_player(object *mon, object *pl, unsigned mindiff); 524int path_to_player(object *mon, object *pl, unsigned mindiff);
534void give_initial_items(object *pl, treasurelist *items); 525void give_initial_items(object *pl, treasurelist *items);
535void get_name(object *op); 526void get_name(object *op);
536void get_password(object *op); 527void get_password(object *op);
537void play_again(object *op); 528void play_again(object *op);
538int receive_play_again(object *op, char key); 529int receive_play_again(object *op, char key);
539void confirm_password(object *op); 530void confirm_password(object *op);
540void get_party_password(object *op, partylist *party); 531void get_party_password(object *op, partylist *party);
541int roll_stat(void);
542void roll_stats(object *op);
543void Roll_Again(object *op); 532void Roll_Again(object *op);
544void Swap_Stat(object *op, int Swap_Second); 533void Swap_Stat(object *op, int Swap_Second);
545int key_roll_stat(object *op, char key); 534int key_roll_stat(object *op, char key);
546int key_change_class(object *op, char key); 535int key_change_class(object *op, char key);
547int key_confirm_quit(object *op, char key); 536int key_confirm_quit(object *op, char key);
584void *cfapi_get_hooks(int *type, ...); 573void *cfapi_get_hooks(int *type, ...);
585int plugins_remove_plugin(const char *id); 574int plugins_remove_plugin(const char *id);
586crossfire_plugin *plugins_find_plugin(const char *id); 575crossfire_plugin *plugins_find_plugin(const char *id);
587void plugins_display_list(object *op); 576void plugins_display_list(object *op);
588void *cfapi_system_find_animation(int *type, ...); 577void *cfapi_system_find_animation(int *type, ...);
589void *cfapi_system_strdup_local(int *type, ...); 578void *cfapi_system_strdup(int *type, ...);
590void *cfapi_system_register_global_event(int *type, ...); 579void *cfapi_system_register_global_event(int *type, ...);
591void *cfapi_system_unregister_global_event(int *type, ...); 580void *cfapi_system_unregister_global_event(int *type, ...);
592void *cfapi_system_add_string(int *type, ...);
593void *cfapi_system_remove_string(int *type, ...);
594void *cfapi_system_check_path(int *type, ...); 581void *cfapi_system_check_path(int *type, ...);
595void *cfapi_system_re_cmp(int *type, ...); 582void *cfapi_system_re_cmp(int *type, ...);
596void *cfapi_system_directory(int *type, ...); 583void *cfapi_system_directory(int *type, ...);
597void *cfapi_map_get_map(int *type, ...); 584void *cfapi_map_get_map(int *type, ...);
598void *cfapi_map_has_been_loaded(int *type, ...); 585void *cfapi_map_has_been_loaded(int *type, ...);
676int trap_see(object *op, object *trap); 663int trap_see(object *op, object *trap);
677int trap_show(object *trap, object *where); 664int trap_show(object *trap, object *where);
678int trap_disarm(object *disarmer, object *trap, int risk, object *skill); 665int trap_disarm(object *disarmer, object *trap, int risk, object *skill);
679void trap_adjust(object *trap, int difficulty); 666void trap_adjust(object *trap, int difficulty);
680/* shop.c */ 667/* shop.c */
668int get_payment(object *pl);
681uint64 query_cost(const object *tmp, object *who, int flag); 669sint64 query_cost(const object *tmp, object *who, int flag);
682const char *query_cost_string(const object *tmp, object *who, int flag); 670const char *query_cost_string(const object *tmp, object *who, int flag);
683uint64 query_money(const object *op); 671sint64 query_money(const object *op);
684int pay_for_amount(uint64 to_pay, object *pl); 672int pay_for_amount(sint64 to_pay, object *pl);
685int pay_for_item(object *op, object *pl); 673int pay_for_item(object *op, object *pl);
686int can_pay(object *pl); 674int can_pay(object *pl);
687int get_payment(object *pl, object *op);
688void sell_item(object *op, object *pl); 675void sell_item(object *op, object *pl);
689double shopkeeper_approval(const mapstruct *map, const object *player); 676double shopkeeper_approval(const maptile *map, const object *player);
690int describe_shop(const object *op); 677int describe_shop(const object *op);
691void shop_listing(object *op); 678void shop_listing(object *op);
679bool is_in_shop (object *o);
680bool is_in_shop (maptile *map, int x, int y);
692/* skills.c */ 681/* skills.c */
693int steal(object *op, int dir, object *skill); 682int steal(object *op, int dir, object *skill);
694int pick_lock(object *pl, int dir, object *skill); 683int pick_lock(object *pl, int dir, object *skill);
695int hide(object *op, object *skill); 684int hide(object *op, object *skill);
696int jump(object *pl, int dir, object *skill); 685int jump(object *pl, int dir, object *skill);
784/* spell_util.c */ 773/* spell_util.c */
785object *find_random_spell_in_ob(object *ob, const char *skill); 774object *find_random_spell_in_ob(object *ob, const char *skill);
786void set_spell_skill(object *op, object *caster, object *spob, object *dest); 775void set_spell_skill(object *op, object *caster, object *spob, object *dest);
787void init_spells(void); 776void init_spells(void);
788void dump_spells(void); 777void dump_spells(void);
789void spell_effect(object *spob, int x, int y, mapstruct *map, object *originator); 778void spell_effect(object *spob, int x, int y, maptile *map, object *originator);
790int min_casting_level(object *caster, object *spell); 779int min_casting_level(object *caster, object *spell);
791int caster_level(object *caster, object *spell); 780int caster_level(object *caster, object *spell);
792sint16 SP_level_spellpoint_cost(object *caster, object *spell, int flags); 781sint16 SP_level_spellpoint_cost(object *caster, object *spell, int flags);
793int SP_level_dam_adjust(object *caster, object *spob); 782int SP_level_dam_adjust(object *caster, object *spob);
794int SP_level_duration_adjust(object *caster, object *spob); 783int SP_level_duration_adjust(object *caster, object *spob);
795int SP_level_range_adjust(object *caster, object *spob); 784int SP_level_range_adjust(object *caster, object *spob);
796object *check_spell_known(object *op, const char *name); 785object *check_spell_known(object *op, const char *name);
797object *lookup_spell_by_name(object *op, const char *spname); 786object *lookup_spell_by_name(object *op, const char *spname);
798int reflwall(mapstruct *m, int x, int y, object *sp_op); 787int reflwall(maptile *m, int x, int y, object *sp_op);
799int cast_create_obj(object *op, object *caster, object *new_op, int dir); 788int cast_create_obj(object *op, object *caster, object *new_op, int dir);
800int ok_to_put_more(mapstruct *m, sint16 x, sint16 y, object *op, int immune_stop); 789int ok_to_put_more(maptile *m, sint16 x, sint16 y, object *op, int immune_stop);
801int fire_arch_from_position(object *op, object *caster, sint16 x, sint16 y, int dir, object *spell); 790int fire_arch_from_position(object *op, object *caster, sint16 x, sint16 y, int dir, object *spell);
802void regenerate_rod(object *rod); 791void regenerate_rod(object *rod);
803void drain_rod_charge(object *rod); 792void drain_rod_charge(object *rod);
804object *find_target_for_friendly_spell(object *op, int dir); 793object *find_target_for_friendly_spell(object *op, int dir);
805int spell_find_dir(mapstruct *m, int x, int y, object *exclude); 794int spell_find_dir(maptile *m, int x, int y, object *exclude);
806void put_a_monster(object *op, const char *monstername); 795void put_a_monster(object *op, const char *monstername);
807int summon_hostile_monsters(object *op, int n, const char *monstername); 796int summon_hostile_monsters(object *op, int n, const char *monstername);
808void shuffle_attack(object *op, int change_face); 797void shuffle_attack(object *op, int change_face);
809void prayer_failure(object *op, int failure, int power); 798void prayer_failure(object *op, int failure, int power);
810void spell_failure(object *op, int failure, int power, object *skill); 799void spell_failure(object *op, int failure, int power, object *skill);
816/* swamp.c */ 805/* swamp.c */
817void walk_on_deep_swamp(object *op, object *victim); 806void walk_on_deep_swamp(object *op, object *victim);
818void move_deep_swamp(object *op); 807void move_deep_swamp(object *op);
819/* swap.c */ 808/* swap.c */
820void read_map_log(void); 809void read_map_log(void);
821void swap_map(mapstruct *map); 810void swap_map(maptile *map);
822void check_active_maps(void); 811void check_active_maps(void);
823mapstruct *map_least_timeout(char *except_level); 812maptile *map_least_timeout(char *except_level);
824void swap_below_max(char *except_level); 813void swap_below_max(char *except_level);
825int players_on_map(mapstruct *m, int show_all); 814int players_on_map(maptile *m, int show_all);
826void flush_old_maps(void); 815void flush_old_maps(void);
827/* time.c */ 816/* time.c */
828void remove_door(object *op); 817void remove_door(object *op);
829void remove_door2(object *op); 818void remove_door2(object *op);
830void generate_monster_inv(object *gen); 819void generate_monster_inv(object *gen);
837void move_timed_gate(object *op); 826void move_timed_gate(object *op);
838void move_detector(object *op); 827void move_detector(object *op);
839void animate_trigger(object *op); 828void animate_trigger(object *op);
840void move_hole(object *op); 829void move_hole(object *op);
841object *stop_item(object *op); 830object *stop_item(object *op);
842void fix_stopped_item(object *op, mapstruct *map, object *originator); 831void fix_stopped_item(object *op, maptile *map, object *originator);
843object *fix_stopped_arrow(object *op); 832object *fix_stopped_arrow(object *op);
844void move_arrow(object *op); 833void move_arrow(object *op);
845void change_object(object *op); 834void change_object(object *op);
846void move_teleporter(object *op); 835void move_teleporter(object *op);
847void move_player_changer(object *op); 836void move_player_changer(object *op);
856void cftimer_process_event(object *ob); 845void cftimer_process_event(object *ob);
857int cftimer_create(int id, long delay, object *ob, int mode); 846int cftimer_create(int id, long delay, object *ob, int mode);
858int cftimer_destroy(int id); 847int cftimer_destroy(int id);
859int cftimer_find_free_id(void); 848int cftimer_find_free_id(void);
860/* weather.c */ 849/* weather.c */
861void set_darkness_map(mapstruct *m); 850void set_darkness_map(maptile *m);
862void tick_the_clock(void); 851void tick_the_clock(void);
863void init_weather(void); 852void init_weather(void);
864void weather_effect(const char *filename); 853void weather_effect(const char *filename);
865int worldmap_to_weathermap(int x, int y, int *wx, int *wy, mapstruct *m); 854int worldmap_to_weathermap(int x, int y, int *wx, int *wy, maptile *m);
866int real_world_temperature(int x, int y, mapstruct *m); 855int real_world_temperature(int x, int y, maptile *m);
867int similar_direction(int a, int b); 856int similar_direction(int a, int b);

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines