identify spell is in error

Posted by Fester on Mon 14 Jan 2002 02:37 AM — 2 posts, 12,422 views.

#0
Whenever identify is cast the spell shows every wear flag
*BUT* the one that is actually on the item.

if i'm not mistaken this would be the chunk of code that is responsible for this problem.

magic.c
line 3196

if ( obj->item_type != ITEM_LIGHT && obj->wear_flags-1 > 0 )
ch_printf( ch, ", with wear location: %s\n\r", flag_string(obj->wear_flags-1, w_flags) );
else
send_to_char( ".\n\r", ch );

however bieng somewhat new to smaug and a poor coder at best
i'm afraid that i'm stuck.;(

Any help would be appreciated. Thanx in advance ;)

-Edit-
is smaug v1.4a for windows compiled under cygwin
Amended on Mon 14 Jan 2002 02:43 AM by Fester
#1
Fixed the problem on my own after all ;)

changed
if ( obj->item_type != ITEM_LIGHT && obj->wear_flags-1 > 0 )
ch_printf( ch, ", with wear location: %s\n\r", flag_string(obj->wear_flags-1, w_flags) );

to this
if ( obj->item_type != ITEM_LIGHT && obj->wear_flags-1 > 0 )
ch_printf( ch, ", with wear location: %s\n\r", flag_string(obj->wear_flags, w_flags) );