Go to the documentation of this file.
39 #include <sys/types.h>
41 #include <netinet/in.h>
42 #include <netinet/tcp.h>
82 LOG(
llevError,
"Buffer overflow in send_skill_info, not sending all skill information\n");
115 LOG(
llevError,
"Buffer overflow in send_skill_extra, not sending all skill information\n");
143 LOG(
llevError,
"Buffer overflow in send_spell_paths, not sending all spell information\n");
168 LOG(
llevError,
"Buffer overflow in send_exp_table, not sending all information\n");
181 #define AddShortAttr(New, Type) \
183 SockList_AddChar(sl, Type); \
184 SockList_AddShort(sl, New); \
237 const char *
value, *value1;
238 char *lasts, *mychoices, *
token;
242 snprintf(
buf,
MAX_BUF,
"race_choice_description_%d", i);
247 snprintf(
buf,
MAX_BUF,
"class_choice_description_%d", i);
253 if (
value && value1) {
268 token = strtok_r(mychoices,
" ", &lasts);
276 strlen(
arch->clone.name));
280 token = strtok_r(NULL,
" ", &lasts);
314 SockList_AddPrintf(sl,
"|%s", race->name);
328 static int sl_initialized = 0;
330 if (!sl_initialized) {
349 LOG(
llevError,
"send_race_info: IP '%s' sent bogus race_info command.\n", ns->
host);
380 SockList_AddPrintf(sl,
"|%s", cl->name);
394 static int sl_initialized = 0;
396 if (!sl_initialized) {
415 LOG(
llevError,
"send_class_info: IP '%s' sent bogus class_info request.\n", ns->
host);
449 SockList_AddChar(&sl, INFO_MAP_ARCH_NAME);
450 SockList_AddLen16Data(&sl, m->name, strlen(m->name));
452 SockList_AddChar(&sl, INFO_MAP_NAME);
453 SockList_AddLen16Data(&sl, m->clone.name, strlen(m->clone.name));
459 SockList_AddChar(&sl, INFO_MAP_DESCRIPTION);
460 SockList_AddLen16Data(&sl, m->clone.msg, strlen(m->clone.msg));
484 if (!strcmp(
file,
"motd"))
486 else if (!strcmp(
file,
"rules"))
488 else if (!strcmp(
file,
"news"))
494 fp = fopen(
buf,
"r");
551 snprintf(
buf,
MAX_BUF,
"R class requestinfo");
554 snprintf(
buf,
MAX_BUF,
"O startingmap requestinfo");
void SockList_AddInt64(SockList *sl, uint64_t data)
static void build_race_list_reply(SockList *sl)
void LOG(LogLevel logLevel, const char *format,...)
void send_skill_extra(socket_struct *ns, char *params)
static void build_class_list_reply(SockList *sl)
void safe_strcat(char *dest, const char *orig, size_t *curlen, size_t maxlen)
arch
DIALOGCHECK MINARGS 1 MAXARGS 1
const char *const spellpathnames[NRSPELLPATHS]
void SockList_AddString(SockList *sl, const char *data)
uint8_t starting_stat_max
void send_new_char_info(socket_struct *ns)
static void send_arch_info(SockList *sl, const object *op)
void SockList_AddLen16Data(SockList *sl, const void *data, size_t len)
void SockList_Reset(SockList *sl)
const char * object_get_value(const object *op, const char *const key)
AssetsManager * getManager()
size_t SockList_Avail(const SockList *sl)
const char *const short_stat_name[NUM_STATS]
static event_registration m
void send_file(socket_struct *ns, const char *file)
Player Stats effect how well a character can survie and interact inside the crossfire world This section discusses the various what they and how they effect the player s actions Also in this section are the stat modifiers that specific classes professions bring Player and sps the current and maximum the Current and Maximum The Current Sp can go somewhat negative When Sp is negative not all spells can be and a more negative Sp makes spell casting less likey to succeed can affect Damage and how the characters as well as how often the character can attack this affects the prices when buying and selling items if this drops the player will start losing hit points cl
void esrv_send_face(socket_struct *ns, const Face *face, int nocache)
void SockList_AddShort(SockList *sl, uint16_t data)
void send_race_info(socket_struct *ns, char *params)
void SockList_AddChar(SockList *sl, unsigned char c)
const char * skill_names[MAX_SKILLS]
#define CS_STAT_SKILLINFO
Archetypes * archetypes()
void send_spell_paths(socket_struct *ns)
void SockList_Init(SockList *sl)
void SockList_Term(SockList *sl)
void send_skill_info(socket_struct *ns, char *params)
void SockList_AddData(SockList *sl, const void *data, size_t len)
void each(std::function< void(T *)> op)
uint8_t starting_stat_min
const Face * skill_faces[MAX_SKILLS]
void send_map_info(socket_struct *ns)
void SockList_AddLen8Data(SockList *sl, const void *data, size_t len)
#define AddShortAttr(New, Type)
void send_class_list(socket_struct *ns)
void send_class_info(socket_struct *ns, char *params)
sstring skill_messages[MAX_SKILLS]
archetype * try_find_archetype(const char *name)
void send_exp_table(socket_struct *ns)
uint8_t starting_stat_points
void Send_With_Handling(socket_struct *ns, SockList *sl)
void SockList_AddPrintf(SockList *sl, const char *format,...)
void send_race_list(socket_struct *ns)