… | |
… | |
450 | owner = owner->owner; |
450 | owner = owner->owner; |
451 | |
451 | |
452 | this->owner = owner; |
452 | this->owner = owner; |
453 | } |
453 | } |
454 | |
454 | |
|
|
455 | int |
|
|
456 | object::slottype () const |
|
|
457 | { |
|
|
458 | if (type == SKILL) |
|
|
459 | { |
|
|
460 | if (IS_COMBAT_SKILL (subtype)) return slot_combat; |
|
|
461 | if (IS_RANGED_SKILL (subtype)) return slot_ranged; |
|
|
462 | } |
|
|
463 | else |
|
|
464 | { |
|
|
465 | if (slot [body_combat].info) return slot_combat; |
|
|
466 | if (slot [body_range ].info) return slot_ranged; |
|
|
467 | } |
|
|
468 | |
|
|
469 | return slot_none; |
|
|
470 | } |
|
|
471 | |
455 | bool |
472 | bool |
456 | object::change_weapon (object *ob) |
473 | object::change_weapon (object *ob) |
457 | { |
474 | { |
458 | if (current_weapon == ob) |
475 | if (current_weapon == ob) |
459 | return true; |
476 | return true; |
… | |
… | |
483 | "You try to balance your applied items all at once, but the %s is too much. " |
500 | "You try to balance your applied items all at once, but the %s is too much. " |
484 | "You need to unapply some items first.", &ob->name); |
501 | "You need to unapply some items first.", &ob->name); |
485 | return false; |
502 | return false; |
486 | } |
503 | } |
487 | |
504 | |
488 | new_draw_info_format (NDI_UNIQUE, 0, this, "You switch to your %s.", &ob->name); |
505 | //new_draw_info_format (NDI_UNIQUE, 0, this, "You switch to your %s.", &ob->name); |
489 | } |
506 | } |
490 | else |
507 | else |
491 | new_draw_info_format (NDI_UNIQUE, 0, this, "You unwield your weapons."); |
508 | ;//new_draw_info_format (NDI_UNIQUE, 0, this, "You unwield your weapons."); |
492 | |
509 | |
493 | return true; |
510 | return true; |
494 | } |
511 | } |
495 | |
512 | |
496 | /* Zero the key_values on op, decrementing the shared-string |
513 | /* Zero the key_values on op, decrementing the shared-string |