31 NULL,
"download_all_images",
"echo_bindings",
32 "fasttcpsend",
"command_window",
"cacheimages",
"fog_of_war",
"iconscale",
33 "mapscale",
"popups",
"displaymode",
"showicon",
"tooltips",
"sound",
"splitinfo",
34 "split",
"show_grid",
"lighting",
"trim_info_window",
35 "map_width",
"map_height",
"foodbeep",
"darkness",
"port",
36 "grad_color_bars",
"resistances",
"smoothing",
"nosplash",
37 "auto_apply_container",
"mapscroll",
"sign_popups",
"message_timestamping" 42 #define FREE_AND_CLEAR(xyz) { free(xyz); xyz=NULL; } 51 LOG(
LOG_WARNING,
"common::VersionCmd",
"Differing C->S version numbers (%d,%d)",
55 cp = strchr(data,
' ');
61 LOG(
LOG_WARNING,
"common::VersionCmd",
"Differing S->C version numbers (%d,%d)",
64 cp = strchr(cp + 1,
' ');
66 LOG(
LOG_DEBUG,
"common::VersionCmd",
"Playing on server type %s", cp);
81 GString *app_config_dir = g_string_new(g_get_user_config_dir());
82 g_string_append(app_config_dir,
"/crossfire");
83 config_dir = g_string_free(app_config_dir, FALSE);
86 GString *app_cache_dir = g_string_new(g_get_user_cache_dir());
87 g_string_append(app_cache_dir,
"/crossfire");
88 cache_dir = g_string_free(app_cache_dir, FALSE);
void free_all_race_class_info(Race_Class_Info *data, int num_entries)
This function clears the data from the Race_Class_Info array.
void VersionCmd(char *data, int len)
void SendAddMe(ClientSocket csock)
#define COMMAND_WINDOW
Do not send more than this many outstanding commands to the server this is only a default value...
int command_time
Time (in ms) players commands currently take to execute.
void client_init()
Called ONCE during client startup to initialize configuration and other variables to reasonable defau...
gint16 want_config[CONFIG_NUMS]
gint64 skill_exp[MAX_SKILL]
Experience points for skills.
#define FREE_AND_CLEAR(xyz)
int sc_version
Server versions of these.
#define MAX_SKILL
How many skill types server supports/client will get sent to it.
gint16 maxsp
Maximum spell points.
#define CONFIG_DISPLAYMODE
Warning that something might not work.
gint32 speed
Speed (is displayed as a float)
Face_Information face_info
guint8 * magicmap
Magic map data.
char VERSION_INFO[MAX_BUF]
char * skill_names[MAX_SKILL]
#define CONFIG_MAPSCROLL
Use bitmap operations for map scrolling.
Basic support for socket communications, including the file descriptor, input buffer, server, server, version, etc.
void reset_player_data()
Reset player experience data.
void LOG(LogLevel level, const char *origin, const char *format,...)
Log messages of a certain importance to stderr.
void init_commands()
Fills some internal arrays.
Includes and prototypes for p_cmd.c for player-commands like '/magicmap'.
int cs_print_string(int fd, const char *str,...)
Send a printf-formatted packet to the socket.
gint16 use_config[CONFIG_NUMS]
void SendVersion(ClientSocket csock)
item * below
Items below the player (pl.below->inv)
Client_Player cpl
Player object.
#define CONFIG_GRAD_COLOR
item * container
open container
#define CONFIG_APPLY_CONTAINER
Reapply container.
void mapdata_init(void)
Initializes the module.
#define CONFIG_PORT
Is this useful any more?
char last_command[MAX_BUF]
Last command entered.
#define CONFIG_NUMS
This should always be the last value in the CONFIG_xxx list.
guint16 count_left
count for commands
int last_used_skills[MAX_SKILL+1]
maps position to skill id with trailing zero as stop mark.
gint16 skill_level[MAX_SKILL]
Level of known skills.
guint8 showmagic
If 0, show the normal map, otherwise show the magic map.
item * ranges[range_size]
Object that is used for that.
const char *const config_names[CONFIG_NUMS]
See common/init.c - number mapping used when loading/saving the values.
char range[MAX_BUF]
Range attack chosen.
int command_received
These are used for the newer 'windowing' method of commands - number of last command sent...
gint16 maxhp
Maximum hit points.
void client_reset()
Clear client variables between connections to different servers.
char title[MAX_BUF]
Title of character.
Includes various dependencies header files needed by most everything.
char input_text[MAX_BUF]
keys typed (for long commands)
Useful debugging information.
static void init_config()
Initialize client settings with built-in defaults.
static void reset_vars_common()
Initialize or reset client variables.
Race_Class_Info * classes
gint16 maxgrace
Maximum spell points.