 |
Crossfire Client, Trunk
|
Go to the documentation of this file.
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",
"auto_afk",
46 #define FREE_AND_CLEAR(xyz) { free(xyz); xyz=NULL; }
55 LOG(
LOG_WARNING,
"common::VersionCmd",
"Differing C->S version numbers (%d,%d)",
59 cp = strchr(data,
' ');
65 LOG(
LOG_WARNING,
"common::VersionCmd",
"Differing S->C version numbers (%d,%d)",
68 cp = strchr(cp + 1,
' ');
70 LOG(
LOG_DEBUG,
"common::VersionCmd",
"Playing on server type %s", cp);
85 GString *app_config_dir = g_string_new(g_get_user_config_dir());
86 g_string_append(app_config_dir,
"/crossfire");
87 config_dir = g_string_free(app_config_dir, FALSE);
90 GString *app_cache_dir = g_string_new(g_get_user_cache_dir());
91 g_string_append(app_cache_dir,
"/crossfire");
92 cache_dir = g_string_free(app_cache_dir, FALSE);
gint16 skill_level[MAX_SKILL]
Level of known skills.
@ LOG_WARNING
Warning that something might not work.
#define CONFIG_PORT
Is this useful any more?
gint64 skill_exp[MAX_SKILL]
Experience points for skills.
char title[MAX_BUF]
Title of character.
#define CONFIG_SERVER_TICKS
guint16 command_received
These are used for the newer 'windowing' method of commands - number of last command sent,...
void client_reset()
Clear client variables between connections to different servers.
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 init_commands()
Fills some internal arrays.
#define FREE_AND_CLEAR(xyz)
int command_time
Time (in ms) players commands currently take to execute.
Face_Information face_info
gint16 maxgrace
Maximum spell points.
#define CONFIG_GRAD_COLOR
guint16 count_left
count for commands
char input_text[MAX_BUF]
keys typed (for long commands)
int sc_version
Server versions of these.
gint16 want_config[CONFIG_NUMS]
char VERSION_INFO[MAX_BUF]
int last_used_skills[MAX_SKILL+1]
maps position to skill id with trailing zero as stop mark.
#define CONFIG_NUMS
This should always be the last value in the CONFIG_xxx list.
item * container
open container
void SendAddMe(ClientSocket csock)
gint32 speed
Speed (is displayed as a float)
const char *const config_names[CONFIG_NUMS]
See common/init.c - number mapping used when loading/saving the values.
gint16 maxhp
Maximum hit points.
char last_command[MAX_BUF]
Last command entered.
item * ranges[range_size]
Object that is used for that.
void mapdata_free(void)
Deallocate map data.
char range[MAX_BUF]
Range attack chosen.
gint16 maxsp
Maximum spell points.
#define CONFIG_MAPSCROLL
Use bitmap operations for map scrolling.
#define MAX_SKILL
How many skill types server supports/client will get sent to it.
void LOG(LogLevel level, const char *origin, const char *format,...)
Log messages of a certain importance to stderr.
int cs_print_string(GSocketConnection *fd, const char *str,...)
Send a printf-formatted packet to the socket.
guint8 * magicmap
Magic map data.
static void init_config()
Initialize client settings with built-in defaults.
void SendVersion(ClientSocket csock)
static void reset_vars_common()
Initialize or reset client variables.
Basic support for socket communications, including the file descriptor, input buffer,...
guint8 showmagic
If 0, show the normal map, otherwise show the magic map.
Client_Player cpl
Player object.
void reset_player_data()
Reset player experience data.
item * below
Items below the player (pl.below->inv)
#define COMMAND_WINDOW
Do not send more than this many outstanding commands to the server this is only a default value.
#define CONFIG_APPLY_CONTAINER
Reapply container.
void client_init()
Called ONCE during client startup to initialize configuration and other variables to reasonable defau...
gint16 use_config[CONFIG_NUMS]
char * skill_names[MAX_SKILL]
@ LOG_DEBUG
Useful debugging information.
void VersionCmd(char *data, int len)
Race_Class_Info * classes
#define CONFIG_DISPLAYMODE