diff options
author | j-p-e-g <j-p-e-g@c06c8d41-db1a-0410-9941-cceddc491573> | 2008-10-04 12:21:31 +0000 |
---|---|---|
committer | j-p-e-g <j-p-e-g@c06c8d41-db1a-0410-9941-cceddc491573> | 2008-10-04 12:21:31 +0000 |
commit | f7dc52138f8412bc2f041657f674a5d135e6bdfc (patch) | |
tree | d80bd1be89e1688e1bf2a7a80e475249ba303b0a /crawl-ref/source/travel.h | |
parent | b2fa14e4db341fa5ce4c283bec0f6b217ca2347f (diff) | |
download | crawl-ref-f7dc52138f8412bc2f041657f674a5d135e6bdfc.tar.gz crawl-ref-f7dc52138f8412bc2f041657f674a5d135e6bdfc.zip |
Implement 1853872: Limit travel exclusions to LOS.
This was done by adding env_show_grid as a property to all exclusions.
losight() is currently called if an exclusion is set, when changing
levels/restarting the game and at a vitrification event (in all of the
latter cases for all exclusions on the level).
git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@7121 c06c8d41-db1a-0410-9941-cceddc491573
Diffstat (limited to 'crawl-ref/source/travel.h')
-rw-r--r-- | crawl-ref/source/travel.h | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/crawl-ref/source/travel.h b/crawl-ref/source/travel.h index 320749506b..77368c23be 100644 --- a/crawl-ref/source/travel.h +++ b/crawl-ref/source/travel.h @@ -435,14 +435,21 @@ public: bool can_travel() const { return (type == PHYSICAL); } }; +void init_exclusion_los(); +void update_exclusion_los(coord_def &p); + struct travel_exclude { coord_def pos; int radius; + env_show_grid show; + + void set_exclude_show(); travel_exclude(const coord_def &p, int r = LOS_RADIUS) : pos(p), radius(r) { + set_exclude_show(); } int radius_sq() const |