Crossfire Server, Branch 1.12  R12190
Data Fields
pl Struct Reference

One player. More...

#include <player.h>

Collaboration diagram for pl:
Collaboration graph
[legend]

Data Fields

sint16 bed_x
sint16 bed_y
 x,y - coordinates of respawn (savebed).
sint8 blocked_los [MAP_CLIENT_X][MAP_CLIENT_Y]
 Array showing what spaces the player can see.
bowtype_t bowtype
 Which firemode?
uint32 braced:1
 Will not move if braced, only attack.
uint32 count
 Any numbers typed before a command.
sint16 digestion
 Any bonuses/penalties to digestion.
uint32 do_los:1
 If true, need to call update_los() in draw(), and clear.
sint16 encumbrance
 How much our player is encumbered.
uint32 explore:1
 if True, player is in explore mode.
uint32 fire_on:1
 Player should fire object, not move.
sstring followed_player
 Player the DM is following.
sint16 gen_grace
 Bonuses to regeneration speed of grace.
sint16 gen_hp
 Bonuses to regeneration speed of hp.
sint16 gen_sp
 Bonuses to regeneration speed of sp.
sint16 gen_sp_armour
 Penalty to sp regen from armour.
uint32 golem_count
 To track the golem.
uint32 has_hit:1
 If set, weapon_sp instead of speed will count.
uint32 hidden:1
 If True, player (DM) is hidden from view.
char input_buf [MAX_BUF]
 Holds command to run.
const char * invis_race
 What race invisible to?
sint16 item_power
 Total item power of objects equipped.
char killer [BIG_NAME]
 Who killed this player.
int language
 The language the player wishes to use.
uint16 last_flags
 Fire/run on flags for last tick.
sint8 last_level
 Last level we sent to client.
uint32 last_path_attuned
 Last spell attunment sent to client.
uint32 last_path_denied
 Last spell denied sent to client.
uint32 last_path_repelled
 Last spell repelled sent to client.
sint16 last_resist [NROFATTACKS]
 last resist values sent to client.
sint64 last_skill_exp [NUM_SKILLS]
 Last exp sent to client.
object * last_skill_ob [NUM_SKILLS]
 Exp objects sent to client.
float last_speed
 Last speed as sent to client.
living last_stats
 Last stats as sent to client.
char last_tell [MAX_NAME]
 last player that told you something [mids 01/14/2002].
object * last_used
 Pointer to object last picked or applied.
uint32 last_used_id
 Safety measures to be sure it's the same.
float last_weapon_sp
 if diff than weapon_sp, update client.
sint32 last_weight
 Last weight as sent to client; -1 means do not send weight.
sint32 last_weight_limit
 Last weight limit transmitted to client.
sint8 levgrace [11]
 What grace bonus the player gained on that level.
sint8 levhp [11]
 What hp bonus the player gained on that level.
sint8 levsp [11]
 What sp bonus the player gained on that level.
uint8 listening
 Which priority will be used in info_all.
char maplevel [MAX_BUF]
 On which level is the player?
object * mark
 Marked object.
uint32 mark_count
 Count of marked object.
uint32 mode
 Mode of player for pickup.
uint32 name_changed:1
 If true, the player has set a name.
char new_password [16]
 2 (seed) + 11 (crypted) + 1 (EOS) + 2 (safety) = 16
struct plnext
 Pointer to next player, NULL if this is last.
uint32 no_shout:1
 if True, player is *not *able to use shout command.
object * ob
 The object representing the player.
living orig_stats
 Permanent real stats of player.
Output_Buf outputs [NUM_OUTPUT_BUFS]
 Holds output strings to send to client.
uint16 outputs_count
 Print if this count is exceeded.
uint16 outputs_sync
 How often to print, no matter what.
char own_title [MAX_NAME]
 Title the player has chosen for themself.
partylistparty
 Party this player is part of.
partylistparty_to_join
 Used when player wants to join a party but we will have to get password first so we have to remember which party to join.
char password [16]
 2 (seed) + 11 (crypted) + 1 (EOS) + 2 (safety) = 16
uint32 peaceful:1
 If set, won't attack friendly creatures.
petmode_t petmode
 Which petmode?
object * ranges [range_size]
 Object for each range.
party_rejoin_mode rejoin_party
 Whether to rejoin or not party at login.
uint32 run_on:1
 Player should keep moving in dir until run is off.
char savebed_map [MAX_BUF]
 Map where player will respawn after death.
char search_str [MAX_BUF]
 Item we are looking for.
rangetype shoottype
 Which range-attack is being used by player.
socket_struct socket
 Socket information for this player.
client_spellspell_state
 Spell information sent to client.
char spellparam [MAX_BUF]
 What param to add to spells.
tag_t * stack_items
 Item stack for patch/dump/...
int stack_position
 Current stack position, 0 for no item.
uint8 state
 Input state of the player (name, password, etc).
int Swap_First
 First stat player has selected to swap.
char title [BIG_NAME]
 Default title, like fighter, wizard, etc.
uint32 tmp_invis:1
 Will invis go away when we attack?
object * transport
 Transport the player is in.
unapplymode unapply
 Method for auto unapply.
usekeytype usekeys
 Method for finding keys for doors.
float weapon_sp
 Penalties to speed when fighting w speed >ws/10.
char write_buf [MAX_BUF]
 Holds arbitrary input from client.

Detailed Description

One player.

Definition at line 146 of file player.h.


Field Documentation

Definition at line 152 of file player.h.

Referenced by check_login(), and save_player().

x,y - coordinates of respawn (savebed).

Definition at line 152 of file player.h.

Referenced by check_login(), and save_player().

Array showing what spaces the player can see.

For maps smaller than MAP_CLIENT_.., the upper left is used.

Definition at line 210 of file player.h.

Referenced by look_at_cmd(), and make_sure_seen().

Which firemode?

Definition at line 155 of file player.h.

Referenced by check_login(), get_player(), and save_player().

Will not move if braced, only attack.

Definition at line 178 of file player.h.

Any numbers typed before a command.

Definition at line 163 of file player.h.

Referenced by new_player_cmd(), and remove_ob().

Any bonuses/penalties to digestion.

Definition at line 166 of file player.h.

Referenced by check_login(), and save_player().

If true, need to call update_los() in draw(), and clear.

Definition at line 180 of file player.h.

Referenced by get_player(), make_sure_not_seen(), move_ob(), turn_one_transport(), update_all_los(), and update_all_map_los().

How much our player is encumbered.

Definition at line 230 of file player.h.

if True, player is in explore mode.

Definition at line 187 of file player.h.

Referenced by check_login(), get_player(), and save_player().

Player should fire object, not move.

Definition at line 181 of file player.h.

Referenced by esrv_update_stats().

Player the DM is following.

Definition at line 253 of file player.h.

Referenced by process_players1().

Bonuses to regeneration speed of grace.

Definition at line 170 of file player.h.

Referenced by check_login(), and save_player().

Bonuses to regeneration speed of hp.

Definition at line 167 of file player.h.

Referenced by check_login(), and save_player().

Bonuses to regeneration speed of sp.

Definition at line 168 of file player.h.

Referenced by check_login(), and save_player().

Penalty to sp regen from armour.

Definition at line 169 of file player.h.

Referenced by get_player().

To track the golem.

Definition at line 160 of file player.h.

If set, weapon_sp instead of speed will count.

Definition at line 183 of file player.h.

Referenced by process_players2().

If True, player (DM) is hidden from view.

Definition at line 186 of file player.h.

Referenced by command_reply(), do_tell(), leave(), list_players(), metaserver_update(), and players_on_map().

Holds command to run.

Definition at line 226 of file player.h.

const char* pl::invis_race

What race invisible to?

Definition at line 189 of file player.h.

Total item power of objects equipped.

Definition at line 171 of file player.h.

Who killed this player.

Definition at line 222 of file player.h.

The language the player wishes to use.

Definition at line 255 of file player.h.

Referenced by check_login(), get_player(), and save_player().

Fire/run on flags for last tick.

Definition at line 196 of file player.h.

Referenced by esrv_update_stats().

Last level we sent to client.

Definition at line 175 of file player.h.

Referenced by esrv_update_stats(), and save_player().

Last spell attunment sent to client.

Definition at line 199 of file player.h.

Referenced by esrv_update_stats().

Last spell denied sent to client.

Definition at line 201 of file player.h.

Referenced by esrv_update_stats().

Last spell repelled sent to client.

Definition at line 200 of file player.h.

Referenced by esrv_update_stats().

last resist values sent to client.

Definition at line 206 of file player.h.

Referenced by esrv_update_stats(), and get_player().

Last exp sent to client.

If != exp. obj update client.

Definition at line 192 of file player.h.

Referenced by esrv_update_stats(), and get_player().

Exp objects sent to client.

Definition at line 191 of file player.h.

Referenced by esrv_update_stats(), and get_player().

Last speed as sent to client.

Definition at line 205 of file player.h.

Referenced by esrv_update_stats(), and get_player().

Last stats as sent to client.

Definition at line 204 of file player.h.

Referenced by esrv_update_stats(), and get_player().

last player that told you something [mids 01/14/2002].

Definition at line 223 of file player.h.

Referenced by command_reply(), and do_tell().

object* pl::last_used

Pointer to object last picked or applied.

Definition at line 208 of file player.h.

Safety measures to be sure it's the same.

Definition at line 209 of file player.h.

if diff than weapon_sp, update client.

Definition at line 195 of file player.h.

Referenced by esrv_update_stats(), and get_player().

Last weight as sent to client; -1 means do not send weight.

Definition at line 197 of file player.h.

Referenced by do_server(), esrv_new_player(), and get_player().

Last weight limit transmitted to client.

Definition at line 198 of file player.h.

Referenced by esrv_update_stats().

What grace bonus the player gained on that level.

Definition at line 220 of file player.h.

Referenced by check_login(), and save_player().

What hp bonus the player gained on that level.

Definition at line 218 of file player.h.

Referenced by check_login(), and save_player().

What sp bonus the player gained on that level.

Definition at line 219 of file player.h.

Referenced by check_login(), and save_player().

Which priority will be used in info_all.

Definition at line 174 of file player.h.

Referenced by check_login(), do_tell(), get_player(), and save_player().

On which level is the player?

Definition at line 150 of file player.h.

Referenced by check_login(), and emergency_save().

object* pl::mark

Marked object.

Definition at line 248 of file player.h.

Referenced by inscribe_scroll_cmd(), and mark_item_cmd().

Count of marked object.

Definition at line 247 of file player.h.

Referenced by inscribe_scroll_cmd(), and mark_item_cmd().

Mode of player for pickup.

Definition at line 164 of file player.h.

Referenced by check_login(), esrv_send_pickup(), and save_player().

If true, the player has set a name.

Definition at line 184 of file player.h.

Referenced by check_login(), and save_player().

char pl::new_password[16]

2 (seed) + 11 (crypted) + 1 (EOS) + 2 (safety) = 16

Definition at line 228 of file player.h.

struct pl* pl::next

if True, player is *not *able to use shout command.

Definition at line 188 of file player.h.

Referenced by check_login(), get_player(), and save_player().

object* pl::ob

The object representing the player.

Definition at line 207 of file player.h.

Referenced by add_player(), append_spell(), apply_cmd(), basic_emote(), cfapi_object_get_property(), cfapi_object_move(), cfapi_object_set_property(), cflogger_globalEventListener(), cfpython_globalEventListener(), check_login(), check_name(), command_abil(), command_addexp(), command_arrest(), command_banish(), command_follow(), command_freeze(), command_kick(), command_possess(), command_reply(), command_reset(), command_stats(), command_summon(), command_teleport(), command_toggle_shout(), command_whereabouts(), Crossfire_Party_GetPlayers(), decrease_ob_nr(), dm_stack_peek(), dm_stack_pop(), dm_stack_push(), do_server(), do_tell(), draw_ext_info(), emergency_save(), esrv_add_spells(), esrv_new_player(), esrv_remove_spell(), esrv_update_spells(), esrv_update_stats(), examine_cmd(), ext_info_map(), ext_info_map_except(), ext_info_map_except2(), find_player(), find_player_partial_name(), findPlayer(), fix_luck(), fix_weight(), free_player(), get_dm_object(), get_nearest_player(), get_other_player_from_name(), get_player(), get_who_escape_code_value(), globalEventListener(), handle_client(), increase_ob_nr(), inscribe_scroll_cmd(), is_legal_2ways_exit(), leave(), list_players(), lock_item_cmd(), look_at_cmd(), make_sure_not_seen(), make_sure_seen(), mark_item_cmd(), metaserver_update(), move_cmd(), new_player_cmd(), play_sound_map(), play_sound_player_only(), players_on_map(), process_players1(), process_players2(), receive_play_again(), reply_cmd(), send_changed_object(), send_party_message(), share_exp(), START_TEST(), swap_map(), update_all_los(), and update_all_map_los().

Permanent real stats of player.

Definition at line 203 of file player.h.

Referenced by check_login(), command_abil(), and save_player().

Holds output strings to send to client.

Definition at line 244 of file player.h.

Print if this count is exceeded.

Definition at line 246 of file player.h.

Referenced by check_login(), get_player(), and save_player().

How often to print, no matter what.

Definition at line 245 of file player.h.

Referenced by check_login(), get_player(), and save_player().

Title the player has chosen for themself.

Note that for dragon players, this is filled in for them.

Definition at line 214 of file player.h.

Referenced by check_login(), get_who_escape_code_value(), and save_player().

Party this player is part of.

Definition at line 237 of file player.h.

Referenced by check_login(), command_party(), get_player(), list_players(), obsolete_parties(), remove_party(), and save_player().

Used when player wants to join a party but we will have to get password first so we have to remember which party to join.

Definition at line 238 of file player.h.

char pl::password[16]

2 (seed) + 11 (crypted) + 1 (EOS) + 2 (safety) = 16

Definition at line 227 of file player.h.

Referenced by save_player().

If set, won't attack friendly creatures.

Definition at line 185 of file player.h.

Referenced by check_login(), get_player(), get_who_escape_code_value(), and save_player().

Which petmode?

Definition at line 156 of file player.h.

Referenced by check_login(), get_player(), and save_player().

Object for each range.

Set up in fix_object(). Note That not all are used, it is just nice to map this 1:1 With the range names.

Definition at line 157 of file player.h.

Referenced by inscribe_scroll_cmd(), and player_unready_range_ob().

Whether to rejoin or not party at login.

Definition at line 242 of file player.h.

Referenced by check_login(), get_player(), and save_player().

Player should keep moving in dir until run is off.

Definition at line 182 of file player.h.

Referenced by esrv_update_stats().

Map where player will respawn after death.

Definition at line 151 of file player.h.

Referenced by check_login(), get_player(), and save_player().

Item we are looking for.

Definition at line 243 of file player.h.

Referenced by check_login().

Which range-attack is being used by player.

Definition at line 153 of file player.h.

Referenced by check_login(), get_player(), player_unready_range_ob(), and save_player().

Spell information sent to client.

Definition at line 250 of file player.h.

Referenced by clear_player(), esrv_update_spells(), and get_client_spell_state().

What param to add to spells.

Definition at line 154 of file player.h.

Referenced by check_login().

Item stack for patch/dump/...

commands.

Definition at line 252 of file player.h.

Referenced by clear_player(), command_stack_list(), dm_stack_peek(), dm_stack_pop(), dm_stack_push(), and get_dm_object().

Current stack position, 0 for no item.

Definition at line 254 of file player.h.

Referenced by clear_player(), command_stack_list(), dm_stack_peek(), dm_stack_pop(), dm_stack_push(), and get_dm_object().

Input state of the player (name, password, etc).

See the page on the login process for a description of its use.

Definition at line 172 of file player.h.

Referenced by check_login(), get_other_player_from_name(), get_player(), handle_client(), leave(), list_players(), metaserver_update(), new_player_cmd(), process_players1(), reply_cmd(), and save_player().

First stat player has selected to swap.

Definition at line 202 of file player.h.

Referenced by get_player().

Default title, like fighter, wizard, etc.

Definition at line 216 of file player.h.

Referenced by check_login(), get_player(), and get_who_escape_code_value().

Will invis go away when we attack?

Definition at line 179 of file player.h.

object* pl::transport

Transport the player is in.

Definition at line 249 of file player.h.

Referenced by leave().

Method for auto unapply.

Definition at line 162 of file player.h.

Referenced by check_login(), get_player(), and save_player().

Method for finding keys for doors.

Definition at line 161 of file player.h.

Referenced by check_login(), and save_player().

Penalties to speed when fighting w speed >ws/10.

Definition at line 194 of file player.h.

Referenced by check_login(), esrv_update_stats(), process_players2(), and save_player().

Holds arbitrary input from client.

Definition at line 225 of file player.h.

Referenced by check_login(), and reply_cmd().


The documentation for this struct was generated from the following file: