Combine cockatrice checks into single functions to avoid repeating code. */
| 3841 | |
| 3842 | /* Combine cockatrice checks into single functions to avoid repeating code. */ |
| 3843 | void |
| 3844 | instapetrify(const char *str) |
| 3845 | { |
| 3846 | if (Stone_resistance) |
| 3847 | return; |
| 3848 | if (poly_when_stoned(gy.youmonst.data) && polymon(PM_STONE_GOLEM)) |
| 3849 | return; |
| 3850 | urgent_pline("You turn to stone..."); |
| 3851 | svk.killer.format = KILLED_BY; |
| 3852 | if (str != svk.killer.name) |
| 3853 | Strcpy(svk.killer.name, str ? str : ""); |
| 3854 | done(STONING); |
| 3855 | } |
| 3856 | |
| 3857 | void |
| 3858 | minstapetrify(struct monst *mon, boolean byplayer) |
no test coverage detected