ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/deliantra/server/include/player.h
(Generate patch)

Comparing deliantra/server/include/player.h (file contents):
Revision 1.105 by root, Sat Apr 10 04:54:09 2010 UTC vs.
Revision 1.112 by root, Wed Nov 14 06:18:13 2012 UTC

1/* 1/*
2 * This file is part of Deliantra, the Roguelike Realtime MMORPG. 2 * This file is part of Deliantra, the Roguelike Realtime MMORPG.
3 * 3 *
4 * Copyright (©) 2005,2006,2007,2008,2009,2010 Marc Alexander Lehmann / Robin Redeker / the Deliantra team 4 * Copyright (©) 2005,2006,2007,2008,2009,2010,2011,2012 Marc Alexander Lehmann / Robin Redeker / the Deliantra team
5 * Copyright (©) 2002 Mark Wedel & Crossfire Development Team 5 * Copyright (©) 2002 Mark Wedel & Crossfire Development Team
6 * Copyright (©) 1992 Frank Tore Johansen 6 * Copyright (©) 1992 Frank Tore Johansen
7 * 7 *
8 * Deliantra is free software: you can redistribute it and/or modify it under 8 * Deliantra is free software: you can redistribute it and/or modify it under
9 * the terms of the Affero GNU General Public License as published by the 9 * the terms of the Affero GNU General Public License as published by the
10 * Free Software Foundation, either version 3 of the License, or (at your 10 * Free Software Foundation, either version 3 of the License, or (at your
11 * option) any later version. 11 * option) any later version.
12 * 12 *
13 * This program is distributed in the hope that it will be useful, 13 * This program is distributed in the hope that it will be useful,
14 * but WITHOUT ANY WARRANTY; without even the implied warranty of 14 * but WITHOUT ANY WARRANTY; without even the implied warranty of
15 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 15 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16 * GNU General Public License for more details. 16 * GNU General Public License for more details.
17 * 17 *
18 * You should have received a copy of the Affero GNU General Public License 18 * You should have received a copy of the Affero GNU General Public License
19 * and the GNU General Public License along with this program. If not, see 19 * and the GNU General Public License along with this program. If not, see
20 * <http://www.gnu.org/licenses/>. 20 * <http://www.gnu.org/licenses/>.
21 * 21 *
22 * The authors can be reached via e-mail to <support@deliantra.net> 22 * The authors can be reached via e-mail to <support@deliantra.net>
23 */ 23 */
24 24
25#ifndef PLAYER_H_ 25#ifndef PLAYER_H_
26#define PLAYER_H_ 26#define PLAYER_H_
131 bool ACC (RW, dirty); // set if player is dirty (not reliable yet!) 131 bool ACC (RW, dirty); // set if player is dirty (not reliable yet!)
132 132
133 float ACC (RW, weapon_sp); /* Penalties to speed when fighting w speed >ws/10 */ 133 float ACC (RW, weapon_sp); /* Penalties to speed when fighting w speed >ws/10 */
134 float ACC (RW, weapon_sp_left); // same as speed_left, but for attacks 134 float ACC (RW, weapon_sp_left); // same as speed_left, but for attacks
135 living ACC (RO, orig_stats); /* Permanent real stats of player */ 135 living ACC (RO, orig_stats); /* Permanent real stats of player */
136 object_ptr last_skill_ob[NUM_SKILLS]; /* the exp object */ 136 object_ptr last_skill_ob[CS_NUM_SKILLS]; /* the exp object */
137 object_ptr ACC (RW, last_used); /* Pointer to object last picked or applied */ 137 object_ptr ACC (RW, last_used); /* Pointer to object last picked or applied */
138 138
139 object_ptr ACC (RW, combat_ob); // which weapon/bow/skill to use for direct attacks 139 object_ptr ACC (RW, combat_ob); // which weapon/bow/skill to use for direct attacks
140 object_ptr ACC (RW, ranged_ob); // which skill/item/spell to use for ranged attacks 140 object_ptr ACC (RW, ranged_ob); // which skill/item/spell to use for ranged attacks
141 object_ptr ACC (RW, golem); // the currently controlled golem 141 object_ptr ACC (RW, golem); // the currently controlled golem
157 157
158 object_ptr ACC (RW, killer); /* Who last tried to kill this player (this object is usually destroyed) */ 158 object_ptr ACC (RW, killer); /* Who last tried to kill this player (this object is usually destroyed) */
159 159
160 float speed_left_save; // spee doptimisation, see process_players[12] 160 float speed_left_save; // spee doptimisation, see process_players[12]
161 char write_buf[MAX_BUF]; /* Holds arbitrary input from client */ /* should go */ 161 char write_buf[MAX_BUF]; /* Holds arbitrary input from client */ /* should go */
162 char ACC (RW, password)[16]; /* 2 (seed) + 11 (crypted) + 1 (EOS) + 2 (safety) = 16 */ 162 char ACC (RW, password)[256]; /* 2 (seed) + 11 (crypted) + 1 (EOS) + 2 (safety) = 16 */
163 163
164 partylist *ACC (RW, party); /* Party this player is part of */ 164 partylist *ACC (RW, party); /* Party this player is part of */
165 partylist *ACC (RW, party_to_join); /* used when player wants to join a party */ 165 partylist *ACC (RW, party_to_join); /* used when player wants to join a party */
166 /* but we will have to get password first */ 166 /* but we will have to get password first */
167 /* so we have to remember which party to */ 167 /* so we have to remember which party to */
244 244
245 void do_destroy (); 245 void do_destroy ();
246 void gather_callbacks (AV *&callbacks, event_type event) const; 246 void gather_callbacks (AV *&callbacks, event_type event) const;
247 247
248 MTH dynbuf_text *expand_cfpod (const_utf8_string cfpod) const; 248 MTH dynbuf_text *expand_cfpod (const_utf8_string cfpod) const;
249 static dynbuf_text *expand_cfpod (int hintmode, int gender, const_utf8_string cfpod);
249 250
250 MTH void touch () { dirty = true; } // need to touch when logged out and changed 251 MTH void touch () { dirty = true; } // need to touch when logged out and changed
251 252
252 MTH void play_sound (faceidx sound, int dx = 0, int dy = 0) const 253 MTH void play_sound (faceidx sound, int dx = 0, int dy = 0) const
253 { 254 {
287 MTH void statusmsg (const_utf8_string msg, int color = NDI_BLACK); 288 MTH void statusmsg (const_utf8_string msg, int color = NDI_BLACK);
288 289
289 // a prominent box that signifies some error such as a failed 290 // a prominent box that signifies some error such as a failed
290 // improvement potion. should not be long. 291 // improvement potion. should not be long.
291 MTH void failmsg (const_utf8_string msg, int color = NDI_RED); 292 MTH void failmsg (const_utf8_string msg, int color = NDI_RED);
292 MTH void failmsgf (const_utf8_string format, ...); // always NDI_RED 293 void failmsgf (const_utf8_string format, ...); // always NDI_RED
293 294
294 MTH void update_spells () const 295 MTH void update_spells () const
295 { 296 {
296 if (ns) 297 if (ns)
297 ns->update_spells = true; 298 ns->update_spells = true;

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines