… | |
… | |
729 | |
729 | |
730 | int dy = atoi (cp); |
730 | int dy = atoi (cp); |
731 | |
731 | |
732 | if (player *opl = pl->observe->contr) |
732 | if (player *opl = pl->observe->contr) |
733 | if (client *ns = opl->ns) |
733 | if (client *ns = opl->ns) |
734 | { |
734 | if (opl->blocked_los (dx, dy) >= LOS_MAX) |
735 | if (fabs (dx) > ns->mapx / 2 || fabs (dy) > ns->mapy / 2) |
|
|
736 | return; |
735 | return; |
737 | |
|
|
738 | if (opl->blocked_los[dx + ns->mapx / 2][dy + ns->mapy / 2] >= LOS_MAX) |
|
|
739 | return; |
|
|
740 | } |
|
|
741 | |
736 | |
742 | look_at (pl, dx, dy); |
737 | look_at (pl, dx, dy); |
743 | } |
738 | } |
744 | |
739 | |
745 | /** Move an object to a new location */ |
740 | /** Move an object to a new location */ |