diff options
author | Adam Borowski <kilobyte@angband.pl> | 2013-11-04 19:37:43 +0100 |
---|---|---|
committer | Adam Borowski <kilobyte@angband.pl> | 2013-11-05 05:14:17 +0100 |
commit | 75e84aa610c300a6f83b442f4afb78f50a13fcc6 (patch) | |
tree | 609b95a766e47f9f7838c26ba66dec2938070936 /crawl-ref/source/coord-circle.h | |
parent | 5114b4b827b5b56b3f5e6a204c682c3ac77ad755 (diff) | |
download | crawl-ref-75e84aa610c300a6f83b442f4afb78f50a13fcc6.tar.gz crawl-ref-75e84aa610c300a6f83b442f4afb78f50a13fcc6.zip |
Eradicate C_SQUARE/SH_SQUARE.
circle_def can now be replaced by just a center + radius instead of a
complex object.
Diffstat (limited to 'crawl-ref/source/coord-circle.h')
-rw-r--r-- | crawl-ref/source/coord-circle.h | 16 |
1 files changed, 2 insertions, 14 deletions
diff --git a/crawl-ref/source/coord-circle.h b/crawl-ref/source/coord-circle.h index 7cda864b65..cb2ae50beb 100644 --- a/crawl-ref/source/coord-circle.h +++ b/crawl-ref/source/coord-circle.h @@ -1,18 +1,8 @@ #ifndef COORD_CIRCLE_H #define COORD_CIRCLE_H - -// Internal to circle_def. -enum shape_type -{ - SH_SQUARE, // square around an origin - SH_CIRCLE, // circle around an origin -}; - -// External interface to circle_def shapes. enum circle_type { - C_SQUARE, C_CIRCLE, // circle specified by pre-squared radius C_POINTY, // circle with square radius r*r C_ROUND, // circle with square radius r*r+1 @@ -51,8 +41,6 @@ class circle_def // Check against map bounds for containment? bool check_bounds; - shape_type shape:8; - coord_def origin; int radius; @@ -67,9 +55,9 @@ public: circle_def(const coord_def &origin_, const circle_def &bds); // Circle around (0,0) of specified shape and size. // No bounds checking. - explicit circle_def(int param, circle_type ctype = C_SQUARE); + explicit circle_def(int param, circle_type ctype); // Circle around given origin of specified shape and size. - circle_def(const coord_def &origin_, int param, circle_type ctype = C_SQUARE); + circle_def(const coord_def &origin_, int param, circle_type ctype); bool contains(const coord_def &p) const PURE; const rect_def& get_bbox() const PURE; |