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

Comparing deliantra/server/include/object.h (file contents):
Revision 1.56 by root, Mon Dec 18 02:35:01 2006 UTC vs.
Revision 1.59 by root, Tue Dec 19 05:41:21 2006 UTC

285 285
286 // info must hold 256 * 3 bytes currently 286 // info must hold 256 * 3 bytes currently
287 const char *debug_desc (char *info) const; 287 const char *debug_desc (char *info) const;
288 const char *debug_desc () const; 288 const char *debug_desc () const;
289 289
290 bool is_weapon () const { return type == ARROW || type == BOW || type == WEAPON; }
291 bool is_armor () const { return type == ARMOUR || type == SHIELD || type == HELMET
292 || type == CLOAK || type == BOOTS || type == GLOVES
293 || type == BRACERS || type == GIRDLE; }
294 bool is_alive () const { return (type == PLAYER
295 || flags [FLAG_MONSTER]
296 || (flags [FLAG_ALIVE] && !flags [FLAG_GENERATOR] && type != DOOR))
297 && !flags [FLAG_IS_A_TEMPLATE]; }
298 bool is_arrow () const { return type == ARROW
299 || (type == SPELL_EFFECT
300 && (subtype == SP_BULLET || subtype == SP_MAGIC_MISSILE)); }
301
302 /* This return true if object has still randomitems which
303 * could be expanded.
304 */
305 bool has_random_items () const { return randomitems && !flags [FLAG_IS_A_TEMPLATE]; }
306
290 // fully recursive iterator 307 // fully recursive iterator
291 struct iterator_base 308 struct iterator_base
292 { 309 {
293 object *item; 310 object *item;
294 311
382extern int nrofallocobjects; 399extern int nrofallocobjects;
383 400
384/* This returns TRUE if the object is something that 401/* This returns TRUE if the object is something that
385 * should be displayed in the look window 402 * should be displayed in the look window
386 */ 403 */
387#define LOOK_OBJ(ob) (!ob->invisible && ob->type!=PLAYER && ob->type!=EVENT_CONNECTOR) 404#define LOOK_OBJ(ob) (!ob->invisible && ob->type != PLAYER && ob->type != EVENT_CONNECTOR)
388 405
389/* Used by update_object to know if the object being passed is 406/* Used by update_object to know if the object being passed is
390 * being added or removed. 407 * being added or removed.
391 */ 408 */
392#define UP_OBJ_INSERT 1 409#define UP_OBJ_INSERT 1

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines