diff options
author | Robert Vollmert <rvollmert@gmx.net> | 2009-10-10 12:26:58 +0200 |
---|---|---|
committer | Robert Vollmert <rvollmert@gmx.net> | 2009-10-10 12:26:58 +0200 |
commit | 28112f6099b94dff010198d6b3cbf33d40219a7e (patch) | |
tree | 73ea07a4a36b0f67b00ce993a2abba0026c4b608 /crawl-ref/source/ray.h | |
parent | 32f7f9c05634d9442ccdc6fcc9bda35ab1f682d7 (diff) | |
download | crawl-ref-28112f6099b94dff010198d6b3cbf33d40219a7e.tar.gz crawl-ref-28112f6099b94dff010198d6b3cbf33d40219a7e.zip |
Move shoot_ray into ray_def.
Diffstat (limited to 'crawl-ref/source/ray.h')
-rw-r--r-- | crawl-ref/source/ray.h | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/crawl-ref/source/ray.h b/crawl-ref/source/ray.h index 8816c20171..acea3a33c1 100644 --- a/crawl-ref/source/ray.h +++ b/crawl-ref/source/ray.h @@ -20,7 +20,8 @@ public: int fullray_idx; // for cycling: where did we come from? public: - ray_def(); + ray_def(double accx = 0.0, double accy = 0.0, double slope = 0.0, + int quadrant = 0, int fullray_idx = -1); int x() const { return static_cast<int>(accx); } int y() const { return static_cast<int>(accy); } coord_def pos() const { return coord_def(x(), y()); } @@ -31,6 +32,8 @@ public: void advance_and_bounce(); void regress(); + int footprint(int radius2, int xpos[], int ypos[]); + // Gets/sets the slope in terms of degrees, with 0 = east, 90 = north, // 180 = west, 270 = south, 360 = east, -90 = south, etc double get_degrees() const; |