diff options
Diffstat (limited to 'crawl-ref/source/losparam.cc')
-rw-r--r-- | crawl-ref/source/losparam.cc | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/crawl-ref/source/losparam.cc b/crawl-ref/source/losparam.cc index cd746d0b58..c0a3ed0298 100644 --- a/crawl-ref/source/losparam.cc +++ b/crawl-ref/source/losparam.cc @@ -10,6 +10,7 @@ REVISION("$Rev$"); #include "cloud.h" #include "externs.h" +#include "los.h" #include "stuff.h" #include "terrain.h" @@ -23,12 +24,12 @@ los_param_trans::los_param_trans(const coord_def& c) coord_def los_param_trans::trans(const coord_def& p) const { - return p + center; + return (p + center); } -bool los_param_trans::map_bounds(const coord_def& p) const +bool los_param_trans::los_bounds(const coord_def& p) const { - return ::map_bounds(trans(p)); + return (map_bounds(trans(p)) && p.abs() <= get_los_radius_squared()); } |