… | |
… | |
489 | path_to_player (object *mon, object *pl, unsigned mindiff) |
489 | path_to_player (object *mon, object *pl, unsigned mindiff) |
490 | { |
490 | { |
491 | rv_vector rv; |
491 | rv_vector rv; |
492 | sint16 x, y; |
492 | sint16 x, y; |
493 | int lastx, lasty, dir, i, diff, firstdir = 0, lastdir, max = MAX_SPACES, mflags, blocked; |
493 | int lastx, lasty, dir, i, diff, firstdir = 0, lastdir, max = MAX_SPACES, mflags, blocked; |
494 | mapstruct *m, *lastmap; |
494 | maptile *m, *lastmap; |
495 | |
495 | |
496 | get_rangevector (mon, pl, &rv, 0); |
496 | get_rangevector (mon, pl, &rv, 0); |
497 | |
497 | |
498 | if (rv.distance < mindiff) |
498 | if (rv.distance < mindiff) |
499 | return 0; |
499 | return 0; |
… | |
… | |
1180 | if (settings.set_title == TRUE) |
1180 | if (settings.set_title == TRUE) |
1181 | op->contr->own_title[0] = '\0'; |
1181 | op->contr->own_title[0] = '\0'; |
1182 | |
1182 | |
1183 | if (!QUERY_FLAG (op, FLAG_WAS_WIZ)) |
1183 | if (!QUERY_FLAG (op, FLAG_WAS_WIZ)) |
1184 | { |
1184 | { |
1185 | mapstruct *mp, *next; |
1185 | maptile *mp, *next; |
1186 | |
1186 | |
1187 | /* We need to hunt for any per player unique maps in memory and |
1187 | /* We need to hunt for any per player unique maps in memory and |
1188 | * get rid of them. The trailing slash in the path is intentional, |
1188 | * get rid of them. The trailing slash in the path is intentional, |
1189 | * so that players named 'Ab' won't match against players 'Abe' pathname |
1189 | * so that players named 'Ab' won't match against players 'Abe' pathname |
1190 | */ |
1190 | */ |
… | |
… | |
1762 | |
1762 | |
1763 | object * |
1763 | object * |
1764 | pick_arrow_target (object *op, const char *type, int dir) |
1764 | pick_arrow_target (object *op, const char *type, int dir) |
1765 | { |
1765 | { |
1766 | object *tmp = NULL; |
1766 | object *tmp = NULL; |
1767 | mapstruct *m; |
1767 | maptile *m; |
1768 | int i, mflags, found, number; |
1768 | int i, mflags, found, number; |
1769 | sint16 x, y; |
1769 | sint16 x, y; |
1770 | |
1770 | |
1771 | if (op->map == NULL) |
1771 | if (op->map == NULL) |
1772 | return find_arrow (op, type); |
1772 | return find_arrow (op, type); |
… | |
… | |
1833 | int |
1833 | int |
1834 | fire_bow (object *op, object *part, object *arrow, int dir, int wc_mod, sint16 sx, sint16 sy) |
1834 | fire_bow (object *op, object *part, object *arrow, int dir, int wc_mod, sint16 sx, sint16 sy) |
1835 | { |
1835 | { |
1836 | object *left, *bow; |
1836 | object *left, *bow; |
1837 | int bowspeed, mflags; |
1837 | int bowspeed, mflags; |
1838 | mapstruct *m; |
1838 | maptile *m; |
1839 | |
1839 | |
1840 | if (!dir) |
1840 | if (!dir) |
1841 | { |
1841 | { |
1842 | new_draw_info (NDI_UNIQUE, 0, op, "You can't shoot yourself!"); |
1842 | new_draw_info (NDI_UNIQUE, 0, op, "You can't shoot yourself!"); |
1843 | return 0; |
1843 | return 0; |
… | |
… | |
2303 | move_player_attack (object *op, int dir) |
2303 | move_player_attack (object *op, int dir) |
2304 | { |
2304 | { |
2305 | object *tmp, *mon; |
2305 | object *tmp, *mon; |
2306 | sint16 nx, ny; |
2306 | sint16 nx, ny; |
2307 | int on_battleground; |
2307 | int on_battleground; |
2308 | mapstruct *m; |
2308 | maptile *m; |
2309 | |
2309 | |
2310 | nx = freearr_x[dir] + op->x; |
2310 | nx = freearr_x[dir] + op->x; |
2311 | ny = freearr_y[dir] + op->y; |
2311 | ny = freearr_y[dir] + op->y; |
2312 | |
2312 | |
2313 | on_battleground = op_on_battleground (op, NULL, NULL); |
2313 | on_battleground = op_on_battleground (op, NULL, NULL); |
… | |
… | |
2943 | { |
2943 | { |
2944 | char buf[MAX_BUF]; |
2944 | char buf[MAX_BUF]; |
2945 | int x, y; |
2945 | int x, y; |
2946 | |
2946 | |
2947 | //int i; |
2947 | //int i; |
2948 | mapstruct *map; /* this is for resurrection */ |
2948 | maptile *map; /* this is for resurrection */ |
2949 | |
2949 | |
2950 | /* int z; |
2950 | /* int z; |
2951 | int num_stats_lose; |
2951 | int num_stats_lose; |
2952 | int lost_a_stat; |
2952 | int lost_a_stat; |
2953 | int lose_this_stat; |
2953 | int lose_this_stat; |
… | |
… | |
3587 | int |
3587 | int |
3588 | stand_near_hostile (object *who) |
3588 | stand_near_hostile (object *who) |
3589 | { |
3589 | { |
3590 | object *tmp = NULL; |
3590 | object *tmp = NULL; |
3591 | int i, friendly = 0, player = 0, mflags; |
3591 | int i, friendly = 0, player = 0, mflags; |
3592 | mapstruct *m; |
3592 | maptile *m; |
3593 | sint16 x, y; |
3593 | sint16 x, y; |
3594 | |
3594 | |
3595 | if (!who) |
3595 | if (!who) |
3596 | return 0; |
3596 | return 0; |
3597 | |
3597 | |