Changeset 345

Show
Ignore:
Timestamp:
07/14/07 12:23:51 (1 year ago)
Author:
ajps
Message:

Only mark things as squelchable if we know the 'flavour' through ID or whatever. Closes #220.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • branches/angband-3.0.8/src/squelch.c

    r294 r345  
    320320        int num = -1; 
    321321 
     322        object_kind *k_ptr = &k_info[o_ptr->k_idx]; 
    322323        bool fullid = object_known_p(o_ptr); 
    323324        bool sensed = (o_ptr->ident & IDENT_SENSE) || fullid; 
     
    332333                return TRUE; 
    333334 
    334         /* Do squelching by sval, if the tval's allowed */ 
    335         if (k_info[o_ptr->k_idx].squelch) 
    336         { 
     335        /* Do squelching by sval, if we 'know' the flavour. */ 
     336        if (k_ptr->squelch && (k_ptr->flavor == 0 || k_ptr->aware)) 
     337        { 
     338                /* Only squelch if the tval's allowed */ 
    337339                for (i = 0; i < N_ELEMENTS(sval_dependent); i++) 
    338340                {