On Wed, 28 May 1998, Pheonix Shadowflame wrote:
->While adding a few eq positions as I saw the "!RESERVED!" keywords for
->eq I logged on to my mud and typed wear bread !.
After checking in stock bpl 12 I have determined that this bug is
indeed present, but easily solvable (and mostly harmless). The
problem is with the wear_bitvectors[] array in perform_wear().
int wear_bitvectors[] = {
ITEM_WEAR_HOLD, ...
};
Note that just above this it is mentioned that ITEM_WEAR_TAKE is used
for objects that don't require any special bits to be put into that
particular position -- so the problem should have been obvious from
looking at the code. Hmm, but everyone missed it, so...
Anyway, the solution, and a bit of hack it is, is to make sure that
you don't light anything that's not a light.
if (!CAN_WEAR(obj, wear_bitvectors[where])) {
.
.
.
}
Should be changed to,
if (!CAN_WEAR(obj, wear_bitvectors[where]) ||
(where == WEAR_LIGHT && GET_OBJ_TYPE(obj) != ITEM_LIGHT)) {
.
.
.
}
This is rather cheap, but it doesn't require any more ITEM_WEAR_
flags to be added, and is functional. Alternatively, you can hack
find_eq_pos() to make sure it doesn't find the reserved entries,
if ((where = search_block(arg, keywords, FALSE)) < 0) {
.
.
} else (!str_cmp(keywords[where], "!RESERVED!"))
where = -1;
-dak
+------------------------------------------------------------+
| Ensure that you have read the CircleMUD Mailing List FAQ: |
| http://democracy.queensu.ca/~fletcher/Circle/list-faq.html |
+------------------------------------------------------------+
This archive was generated by hypermail 2b30 : 12/15/00 PST