Fixed shops no longer displaying unlimited and affect flags off by 1 (128 bit). --Rumble

This commit is contained in:
Rumble 2007-05-15 00:40:55 +00:00
parent 76d1d89597
commit bfa47111db
3 changed files with 31 additions and 31 deletions

View file

@ -858,9 +858,12 @@ void do_stat_character(struct char_data *ch, struct char_data *k)
CCGRN(ch, C_NRM), GET_MANA(k), GET_MAX_MANA(k), mana_gain(k), CCNRM(ch, C_NRM), CCGRN(ch, C_NRM), GET_MANA(k), GET_MAX_MANA(k), mana_gain(k), CCNRM(ch, C_NRM),
CCGRN(ch, C_NRM), GET_MOVE(k), GET_MAX_MOVE(k), move_gain(k), CCNRM(ch, C_NRM)); CCGRN(ch, C_NRM), GET_MOVE(k), GET_MAX_MOVE(k), move_gain(k), CCNRM(ch, C_NRM));
send_to_char(ch, "Gold: [%9d], Bank: [%9d] (Total: %d), Questpoints: [%d]\r\n", send_to_char(ch, "Gold: [%9d], Bank: [%9d] (Total: %d), ",
GET_GOLD(k), GET_BANK_GOLD(k), GET_GOLD(k) + GET_BANK_GOLD(k), GET_QUESTPOINTS(k)); GET_GOLD(k), GET_BANK_GOLD(k), GET_GOLD(k) + GET_BANK_GOLD(k));
if (!IS_NPC(k))
send_to_char(ch, "Questpoints: [%d]\r\n", GET_QUESTPOINTS(k));
send_to_char(ch, "AC: [%d%+d/10], Hitroll: [%2d], Damroll: [%2d], Saving throws: [%d/%d/%d/%d/%d]\r\n", send_to_char(ch, "AC: [%d%+d/10], Hitroll: [%2d], Damroll: [%2d], Saving throws: [%d/%d/%d/%d/%d]\r\n",
GET_AC(k), dex_app[GET_DEX(k)].defensive, k->points.hitroll, GET_AC(k), dex_app[GET_DEX(k)].defensive, k->points.hitroll,
k->points.damroll, GET_SAVE(k, 0), GET_SAVE(k, 1), GET_SAVE(k, 2), k->points.damroll, GET_SAVE(k, 0), GET_SAVE(k, 1), GET_SAVE(k, 2),

View file

@ -306,9 +306,6 @@ int same_obj(struct obj_data *obj1, struct obj_data *obj2)
if (GET_OBJ_COST(obj1) != GET_OBJ_COST(obj2)) if (GET_OBJ_COST(obj1) != GET_OBJ_COST(obj2))
return (FALSE); return (FALSE);
if (GET_OBJ_EXTRA(obj1) != GET_OBJ_EXTRA(obj2))
return (FALSE);
for (aindex = 0; aindex < MAX_OBJ_AFFECT; aindex++) for (aindex = 0; aindex < MAX_OBJ_AFFECT; aindex++)
if ((obj1->affected[aindex].location != obj2->affected[aindex].location) || if ((obj1->affected[aindex].location != obj2->affected[aindex].location) ||
(obj1->affected[aindex].modifier != obj2->affected[aindex].modifier)) (obj1->affected[aindex].modifier != obj2->affected[aindex].modifier))
@ -820,8 +817,7 @@ char *list_object(struct obj_data *obj, int cnt, int aindex, int shop_nr, struct
} }
CAP(itemname); CAP(itemname);
snprintf(result, sizeof(result), " %2d) %9s %-*s %6d\r\n", aindex, quantity, snprintf(result, sizeof(result), " %2d) %9s %-*s %6d\r\n", aindex, quantity, 48 - count_color_chars(itemname), itemname, buy_price(obj, shop_nr, keeper, ch));
48 - count_color_chars(itemname), itemname, buy_price(obj, shop_nr, keeper, ch));
return (result); return (result);
} }

View file

@ -211,31 +211,32 @@
/* Affect bits: used in char_data.char_specials.saved.affected_by */ /* Affect bits: used in char_data.char_specials.saved.affected_by */
/* WARNING: In the world files, NEVER set the bits marked "R" ("Reserved") */ /* WARNING: In the world files, NEVER set the bits marked "R" ("Reserved") */
#define AFF_BLIND 0 /* (R) Char is blind */ #define AFF_DONTUSE 0 /* DON'T USE! */
#define AFF_INVISIBLE 1 /* Char is invisible */ #define AFF_BLIND 1 /* (R) Char is blind */
#define AFF_DETECT_ALIGN 2 /* Char is sensitive to align*/ #define AFF_INVISIBLE 2 /* Char is invisible */
#define AFF_DETECT_INVIS 3 /* Char can see invis chars */ #define AFF_DETECT_ALIGN 3 /* Char is sensitive to align */
#define AFF_DETECT_MAGIC 4 /* Char is sensitive to magic*/ #define AFF_DETECT_INVIS 4 /* Char can see invis chars */
#define AFF_SENSE_LIFE 5 /* Char can sense hidden life*/ #define AFF_DETECT_MAGIC 5 /* Char is sensitive to magic */
#define AFF_WATERWALK 6 /* Char can walk on water */ #define AFF_SENSE_LIFE 6 /* Char can sense hidden life */
#define AFF_SANCTUARY 7 /* Char protected by sanct */ #define AFF_WATERWALK 7 /* Char can walk on water */
#define AFF_GROUP 8 /* (R) Char is grouped */ #define AFF_SANCTUARY 8 /* Char protected by sanct */
#define AFF_CURSE 9 /* Char is cursed */ #define AFF_GROUP 9 /* (R) Char is grouped */
#define AFF_INFRAVISION 10 /* Char can see in dark */ #define AFF_CURSE 10 /* Char is cursed */
#define AFF_POISON 11 /* (R) Char is poisoned */ #define AFF_INFRAVISION 11 /* Char can see in dark */
#define AFF_PROTECT_EVIL 12 /* Char protected from evil */ #define AFF_POISON 12 /* (R) Char is poisoned */
#define AFF_PROTECT_GOOD 13 /* Char protected from good */ #define AFF_PROTECT_EVIL 13 /* Char protected from evil */
#define AFF_SLEEP 14 /* (R) Char magically asleep */ #define AFF_PROTECT_GOOD 14 /* Char protected from good */
#define AFF_NOTRACK 15 /* Char can't be tracked */ #define AFF_SLEEP 15 /* (R) Char magically asleep */
#define AFF_UNUSED16 16 /* Room for future expansion */ #define AFF_NOTRACK 16 /* Char can't be tracked */
#define AFF_UNUSED17 17 /* Room for future expansion */ #define AFF_UNUSED16 17 /* Room for future expansion */
#define AFF_SNEAK 18 /* Char can move quietly */ #define AFF_UNUSED17 18 /* Room for future expansion */
#define AFF_HIDE 19 /* Char is hidden */ #define AFF_SNEAK 19 /* Char can move quietly */
#define AFF_UNUSED20 20 /* Room for future expansion */ #define AFF_HIDE 20 /* Char is hidden */
#define AFF_CHARM 21 /* Char is charmed */ #define AFF_UNUSED20 21 /* Room for future expansion */
#define AFF_CHARM 22 /* Char is charmed */
/* Modes of connectedness: used by descriptor_data.state */ /* Modes of connectedness: used by descriptor_data.state */
#define CON_PLAYING 0 /* Playing - Nominal state */ #define CON_PLAYING 0 /* Playing - Nominal state */
#define CON_CLOSE 1 /* User disconnect, remove character. */ #define CON_CLOSE 1 /* User disconnect, remove character. */
#define CON_GET_NAME 2 /* By what name ..? */ #define CON_GET_NAME 2 /* By what name ..? */
#define CON_NAME_CNFRM 3 /* Did I get that right, x? */ #define CON_NAME_CNFRM 3 /* Did I get that right, x? */