File objsave.c
Included Files
#include "structs.h"
#include "comm.h"
#include "handler.h"
#include "db.h"
#include "interpreter.h"
#include "utils.h"
#include "spells.h"
Preprocessor definitions
#define RENT_FACTOR 1
#define CRYO_FACTOR 4
Global Variable receptionist
char ( receptionist)(struct char_data* ch,void* me,int cmd,char* argument)
- Visible in:
-
- objsave.c
Global Variable cryogenicist
char ( cryogenicist)(struct char_data* ch,void* me,int cmd,char* argument)
- Visible in:
-
- objsave.c
External Variables
str_app
extern struct str_app_type str_app[]
- Defined in:
-
- constants.c
world
extern struct room_data* world
- Defined in:
-
- db.c
mob_index
extern struct index_data* mob_index
- Defined in:
-
- db.c
obj_index
extern struct index_data* obj_index
- Defined in:
-
- db.c
descriptor_list
extern struct descriptor_data* descriptor_list
- Defined in:
-
- comm.c
player_table
extern struct player_index_element* player_table
- Defined in:
-
- db.c
top_of_p_table
extern int top_of_p_table
- Defined in:
-
- db.c
min_rent_cost
extern int min_rent_cost
- Defined in:
-
- config.c
rent_file_timeout
extern int rent_file_timeout
- Defined in:
-
- config.c
crash_file_timeout
extern int crash_file_timeout
- Defined in:
-
- config.c
max_obj_save
extern int max_obj_save
- Defined in:
-
- config.c
free_rent
extern int free_rent
- Defined in:
-
- config.c
Global Function Crash_calculate_rent()
void Crash_calculate_rent ( struct obj_data* obj, int* cost )
- Calls:
-
- Crash_calculate_rent() : objsave.c
- MAX() : utils.c
- Called by:
-
- Crash_calculate_rent() : objsave.c
- Crash_idlesave() : objsave.c
Global Function Crash_clean_file()
int Crash_clean_file ( char* name )
- Prototyped in:
-
- handler.h
- Calls:
-
- Crash_delete_file() : objsave.c
- basic_mud_log() : utils.c
- get_filename() : utils.c
- fclose(), feof(), fopen(), fread(), perror(), sprintf(), strcpy(), time()
- Called by:
-
- update_obj_file() : objsave.c
- References Variables:
-
- crash_file_timeout : config.c
- rent_file_timeout : config.c
- buf, buf
Global Function Crash_crashsave()
void Crash_crashsave ( struct char_data* ch )
- Prototyped in:
-
- handler.h
- Calls:
-
- Crash_restore_weight() : objsave.c
- Crash_save() : objsave.c
- Crash_write_rentcode() : objsave.c
- get_filename() : utils.c
- fclose(), fopen(), time()
- Called by:
-
- Crash_save_all() : objsave.c
- check_idling() : limits.c
- do_save() : act.other.c
Global Function Crash_cryosave()
void Crash_cryosave ( struct char_data* ch, int cost )
- Calls:
-
- Crash_extract_norents() : objsave.c
- Crash_extract_objs() : objsave.c
- Crash_save() : objsave.c
- Crash_write_rentcode() : objsave.c
- MAX() : utils.c
- get_filename() : utils.c
- obj_to_char() : handler.c
- unequip_char() : handler.c
- fclose(), fopen(), time()
- Called by:
-
- gen_receptionist() : objsave.c
Global Function Crash_delete_crashfile()
int Crash_delete_crashfile ( struct char_data* ch )
- Prototyped in:
-
- handler.h
- Calls:
-
- Crash_delete_file() : objsave.c
- get_filename() : utils.c
- fclose(), feof(), fopen(), fread(), perror(), sprintf()
- Called by:
-
- extract_char() : handler.c
- References Variables:
-
- buf
Global Function Crash_delete_file()
int Crash_delete_file ( char* name )
- Prototyped in:
-
- handler.h
- Calls:
-
- get_filename() : utils.c
- fclose(), fopen(), perror(), sprintf(), unlink()
- Called by:
-
- Crash_clean_file() : objsave.c
- Crash_delete_crashfile() : objsave.c
- Crash_idlesave() : objsave.c
- nanny() : interpreter.c
- References Variables:
-
- buf
Global Function Crash_extract_expensive()
void Crash_extract_expensive ( struct obj_data* obj )
- Calls:
-
- extract_obj() : handler.c
- Called by:
-
- Crash_idlesave() : objsave.c
Global Function Crash_extract_norents()
void Crash_extract_norents ( struct obj_data* obj )
- Calls:
-
- Crash_extract_norents() : objsave.c
- Crash_is_unrentable() : objsave.c
- extract_obj() : handler.c
- Called by:
-
- Crash_cryosave() : objsave.c
- Crash_extract_norents() : objsave.c
- Crash_idlesave() : objsave.c
- Crash_rentsave() : objsave.c
Global Function Crash_extract_objs()
void Crash_extract_objs ( struct obj_data* obj )
- Calls:
-
- Crash_extract_objs() : objsave.c
- extract_obj() : handler.c
- Called by:
-
- Crash_cryosave() : objsave.c
- Crash_extract_objs() : objsave.c
- Crash_idlesave() : objsave.c
- Crash_rentsave() : objsave.c
Global Function Crash_idlesave()
void Crash_idlesave ( struct char_data* ch )
- Prototyped in:
-
- handler.h
- Calls:
-
- Crash_calculate_rent() : objsave.c
- Crash_delete_file() : objsave.c
- Crash_extract_expensive() : objsave.c
- Crash_extract_norents() : objsave.c
- Crash_extract_objs() : objsave.c
- Crash_save() : objsave.c
- Crash_write_rentcode() : objsave.c
- get_filename() : utils.c
- obj_to_char() : handler.c
- unequip_char() : handler.c
- fclose(), fopen(), time()
- Called by:
-
- check_idling() : limits.c
Global Function Crash_is_unrentable()
int Crash_is_unrentable ( struct obj_data* obj )
- Called by:
-
- Crash_extract_norents() : objsave.c
- Crash_report_rent() : objsave.c
- Crash_report_unrentables() : objsave.c
Global Function Crash_listrent()
void Crash_listrent ( struct char_data* ch, char* name )
- Prototyped in:
-
- handler.h
- Calls:
-
- extract_obj() : handler.c
- get_filename() : utils.c
- read_object() : db.c
- real_object() : db.c
- send_to_char() : comm.c
- fclose(), feof(), ferror(), fopen(), fread(), sprintf(), strcat()
- Called by:
-
- do_show() : act.wizard.c
Global Function Crash_load()
int Crash_load ( struct char_data* ch )
- Prototyped in:
-
- handler.h
- Calls:
-
- Crash_write_rentcode() : objsave.c
- MAX() : utils.c
- Obj_from_store() : objsave.c
- get_filename() : utils.c
- mudlog() : utils.c
- obj_to_char() : handler.c
- save_char() : db.c
- send_to_char() : comm.c
- fclose(), feof(), ferror(), fopen(), fread(), perror(), rewind(), sprintf(), time()
- Called by:
-
- nanny() : interpreter.c
- References Variables:
-
- buf, buf
Global Function Crash_offer_rent()
int Crash_offer_rent ( struct char_data* ch, struct char_data* receptionist, int display, int factor )
- Calls:
-
- Crash_rent_deadline() : objsave.c
- Crash_report_rent() : objsave.c
- Crash_report_unrentables() : objsave.c
- act() : comm.c
- sprintf()
- Called by:
-
- gen_receptionist() : objsave.c
- References Variables:
-
- max_obj_save : config.c
- min_rent_cost : config.c
Global Function Crash_rent_deadline()
void Crash_rent_deadline ( struct char_data* ch, struct char_data* recep, long cost )
- Calls:
-
- act() : comm.c
- sprintf()
- Called by:
-
- Crash_offer_rent() : objsave.c
- gen_receptionist() : objsave.c
- References Variables:
-
- buf
Global Function Crash_rentsave()
void Crash_rentsave ( struct char_data* ch, int cost )
- Calls:
-
- Crash_extract_norents() : objsave.c
- Crash_extract_objs() : objsave.c
- Crash_save() : objsave.c
- Crash_write_rentcode() : objsave.c
- get_filename() : utils.c
- obj_to_char() : handler.c
- unequip_char() : handler.c
- fclose(), fopen(), time()
- Called by:
-
- gen_receptionist() : objsave.c
Global Function Crash_report_rent()
void Crash_report_rent ( struct char_data* ch, struct char_data* recep, struct obj_data* obj, long* cost, long* nitems, int display, int factor )
- Calls:
-
- Crash_is_unrentable() : objsave.c
- Crash_report_rent() : objsave.c
- MAX() : utils.c
- act() : comm.c
- sprintf()
- Called by:
-
- Crash_offer_rent() : objsave.c
- Crash_report_rent() : objsave.c
- References Variables:
-
- weather_info : db.c
- world : db.c
Global Function Crash_report_unrentables()
int Crash_report_unrentables ( struct char_data* ch, struct char_data* recep, struct obj_data* obj )
- Calls:
-
- Crash_is_unrentable() : objsave.c
- Crash_report_unrentables() : objsave.c
- act() : comm.c
- sprintf()
- Called by:
-
- Crash_offer_rent() : objsave.c
- Crash_report_unrentables() : objsave.c
- References Variables:
-
- weather_info : db.c
- world : db.c
Global Function Crash_restore_weight()
void Crash_restore_weight ( struct obj_data* obj )
- Calls:
-
- Crash_restore_weight() : objsave.c
- Called by:
-
- Crash_crashsave() : objsave.c
- Crash_restore_weight() : objsave.c
Global Function Crash_save()
int Crash_save ( struct obj_data* obj, FILE* fp )
- Calls:
-
- Crash_save() : objsave.c
- Obj_to_store() : objsave.c
- Called by:
-
- Crash_crashsave() : objsave.c
- Crash_cryosave() : objsave.c
- Crash_idlesave() : objsave.c
- Crash_rentsave() : objsave.c
- Crash_save() : objsave.c
Global Function Crash_save_all()
void Crash_save_all ( void )
- Prototyped in:
-
- handler.h
- Calls:
-
- Crash_crashsave() : objsave.c
- save_char() : db.c
- Called by:
-
- heartbeat() : comm.c
- References Variables:
-
- descriptor_list : comm.c
Global Function Crash_write_rentcode()
int Crash_write_rentcode ( struct char_data* ch, FILE* fl, struct rent_info* rent )
- Calls:
-
- fwrite(), perror()
- Called by:
-
- Crash_crashsave() : objsave.c
- Crash_cryosave() : objsave.c
- Crash_idlesave() : objsave.c
- Crash_load() : objsave.c
- Crash_rentsave() : objsave.c
Global Function Obj_from_store()
struct obj_data* Obj_from_store ( struct obj_file_elem object )
- Calls:
-
- read_object() : db.c
- real_object() : db.c
- Called by:
-
- Crash_load() : objsave.c
- House_listrent() : house.c
- House_load() : house.c
Global Function Obj_to_store()
int Obj_to_store ( struct obj_data* obj, FILE* fl )
- Calls:
-
- fwrite(), perror()
- Called by:
-
- Crash_save() : objsave.c
- House_save() : house.c
- References Variables:
-
- obj_index : db.c
Global Function cryogenicist()
int ( cryogenicist) ( struct char_data* ch, void* me, int cmd, char* argument )
- Calls:
-
- gen_receptionist() : objsave.c
Global Function gen_receptionist()
int gen_receptionist ( struct char_data* ch, struct char_data* recep, int cmd, char* arg, int mode )
- Calls:
-
- Crash_cryosave() : objsave.c
- Crash_offer_rent() : objsave.c
- Crash_rent_deadline() : objsave.c
- Crash_rentsave() : objsave.c
- MAX() : utils.c
- act() : comm.c
- extract_char() : handler.c
- find_command() : interpreter.c
- mudlog() : utils.c
- number() : utils.c
- save_char() : db.c
- send_to_char() : comm.c
- sprintf(), strcmp()
- Called by:
-
- cryogenicist() : objsave.c
- receptionist() : objsave.c
- References Variables:
-
- cmd_info : interpreter.c
- free_rent : config.c
- weather_info : db.c
- world : db.c
- buf
Global Function receptionist()
int ( receptionist) ( struct char_data* ch, void* me, int cmd, char* argument )
- Calls:
-
- gen_receptionist() : objsave.c
Global Function update_obj_file()
void update_obj_file ( void )
- Calls:
-
- Crash_clean_file() : objsave.c
- Called by:
-
- boot_db() : db.c
- References Variables:
-
- player_table : db.c
- top_of_p_table : db.c