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

Comparing deliantra/server/common/object.C (file contents):
Revision 1.142 by root, Mon Apr 30 04:25:29 2007 UTC vs.
Revision 1.144 by root, Thu May 3 10:39:46 2007 UTC

447 */ 447 */
448 while (owner->owner) 448 while (owner->owner)
449 owner = owner->owner; 449 owner = owner->owner;
450 450
451 this->owner = owner; 451 this->owner = owner;
452}
453
454void
455object::set_weapon (object *ob)
456{
457 if (current_weapon == ob)
458 return;
459
460 current_weapon = ob;
461 new_draw_info_format (NDI_UNIQUE, 0, this, "You switch to your %s.", &ob->name);
462 update_stats ();
452} 463}
453 464
454/* Zero the key_values on op, decrementing the shared-string 465/* Zero the key_values on op, decrementing the shared-string
455 * refcounts and freeing the links. 466 * refcounts and freeing the links.
456 */ 467 */
2584} 2595}
2585 2596
2586const char * 2597const char *
2587object::debug_desc () const 2598object::debug_desc () const
2588{ 2599{
2589 static char info[256 * 4]; 2600 static char info[3][256 * 4];
2601 static int info_idx;
2602
2590 return debug_desc (info); 2603 return debug_desc (info [++info_idx % 3]);
2591}
2592
2593const char *
2594object::debug_desc2 () const
2595{
2596 static char info[256 * 4];
2597 return debug_desc (info);
2598} 2604}
2599 2605
2600struct region * 2606struct region *
2601object::region () const 2607object::region () const
2602{ 2608{

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines