recursive billing of objects within containers. */
| 3384 | |
| 3385 | /* recursive billing of objects within containers. */ |
| 3386 | staticfn void |
| 3387 | bill_box_content( |
| 3388 | struct obj *obj, |
| 3389 | boolean ininv, |
| 3390 | boolean dummy, |
| 3391 | struct monst *shkp) |
| 3392 | { |
| 3393 | struct obj *otmp; |
| 3394 | |
| 3395 | if (SchroedingersBox(obj)) |
| 3396 | return; |
| 3397 | for (otmp = obj->cobj; otmp; otmp = otmp->nobj) { |
| 3398 | if (otmp->oclass == COIN_CLASS) |
| 3399 | continue; |
| 3400 | |
| 3401 | /* the "top" box is added in addtobill() */ |
| 3402 | if (!otmp->no_charge) |
| 3403 | add_one_tobill(otmp, dummy, shkp); |
| 3404 | if (Has_contents(otmp)) |
| 3405 | bill_box_content(otmp, ininv, dummy, shkp); |
| 3406 | } |
| 3407 | } |
| 3408 | |
| 3409 | DISABLE_WARNING_FORMAT_NONLITERAL |
| 3410 |
no test coverage detected