remove one instance of an item from a monster's inventory */
| 1159 | |
| 1160 | /* remove one instance of an item from a monster's inventory */ |
| 1161 | void |
| 1162 | m_useup(struct monst *mon, struct obj *obj) |
| 1163 | { |
| 1164 | if (obj->quan > 1L) { |
| 1165 | obj->quan--; |
| 1166 | obj->owt = weight(obj); |
| 1167 | } else { |
| 1168 | m_useupall(mon, obj); |
| 1169 | } |
| 1170 | } |
| 1171 | |
| 1172 | /* monster attempts ranged weapon attack against player */ |
| 1173 | void |
no test coverage detected