copy a trap's description into outbuf[] */
| 164 | |
| 165 | /* copy a trap's description into outbuf[] */ |
| 166 | staticfn void |
| 167 | trap_description(char *outbuf, int tnum, coordxy x, coordxy y) |
| 168 | { |
| 169 | /* |
| 170 | * Trap detection used to display a bear trap at locations having |
| 171 | * a trapped door or trapped container or both. They're semi-real |
| 172 | * traps now (defined trap types but not part of ftrap chain). |
| 173 | */ |
| 174 | if (trapped_chest_at(tnum, x, y)) |
| 175 | Strcpy(outbuf, "trapped chest"); /* might actually be a large box */ |
| 176 | else if (trapped_door_at(tnum, x, y)) |
| 177 | Strcpy(outbuf, "trapped door"); /* not "trap door"... */ |
| 178 | else |
| 179 | Strcpy(outbuf, trapname(tnum, FALSE)); |
| 180 | return; |
| 181 | } |
| 182 | |
| 183 | /* describe a hidden monster; used for look_at during extended monster |
| 184 | detection and for probing; also when looking at self and camera feedback */ |
no test coverage detected