special attack bonus */
| 1073 | |
| 1074 | /* special attack bonus */ |
| 1075 | int |
| 1076 | spec_abon(struct obj *otmp, struct monst *mon) |
| 1077 | { |
| 1078 | const struct artifact *weap = get_artifact(otmp); |
| 1079 | |
| 1080 | /* no need for an extra check for `NO_ATTK' because this will |
| 1081 | always return 0 for any artifact which has that attribute */ |
| 1082 | |
| 1083 | if (weap != &artilist[ART_NONARTIFACT] |
| 1084 | && weap->attk.damn && spec_applies(weap, mon)) |
| 1085 | return rnd((int) weap->attk.damn); |
| 1086 | return 0; |
| 1087 | } |
| 1088 | |
| 1089 | /* special damage bonus */ |
| 1090 | int |
no test coverage detected