diff options
author | haranp <haranp@c06c8d41-db1a-0410-9941-cceddc491573> | 2008-07-24 10:38:05 +0000 |
---|---|---|
committer | haranp <haranp@c06c8d41-db1a-0410-9941-cceddc491573> | 2008-07-24 10:38:05 +0000 |
commit | 111787503763e9d3eeb4eef2248926bf4a4eeb98 (patch) | |
tree | 8af6fcd44ef05ff7cb092dfe3084c13f58e3ba74 /crawl-ref/source/stuff.h | |
parent | a7ba97bc95fa25180bd402a52943f223da2bf04a (diff) | |
download | crawl-ref-111787503763e9d3eeb4eef2248926bf4a4eeb98.tar.gz crawl-ref-111787503763e9d3eeb4eef2248926bf4a4eeb98.zip |
More cleanups.
git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@6669 c06c8d41-db1a-0410-9941-cceddc491573
Diffstat (limited to 'crawl-ref/source/stuff.h')
-rw-r--r-- | crawl-ref/source/stuff.h | 14 |
1 files changed, 5 insertions, 9 deletions
diff --git a/crawl-ref/source/stuff.h b/crawl-ref/source/stuff.h index 7a7183b60a..46dc76e103 100644 --- a/crawl-ref/source/stuff.h +++ b/crawl-ref/source/stuff.h @@ -59,8 +59,8 @@ class stack_iterator : public std::iterator<std::forward_iterator_tag, item_def> { public: - stack_iterator( const coord_def& pos ); - stack_iterator( int start_link ); + explicit stack_iterator( const coord_def& pos ); + explicit stack_iterator( int start_link ); operator bool() const; item_def& operator *() const; @@ -122,8 +122,8 @@ private: class adjacent_iterator : public radius_iterator { public: - adjacent_iterator( const coord_def& pos = you.pos(), - bool _exclude_center = true ) : + explicit adjacent_iterator( const coord_def& pos = you.pos(), + bool _exclude_center = true ) : radius_iterator(pos, 1, true, false, _exclude_center) {} }; @@ -182,11 +182,7 @@ bool adjacent( const coord_def& p1, const coord_def& p2 ); bool silenced(const coord_def& p); -bool player_can_hear(int x, int y); -inline bool player_can_hear(const coord_def &p) -{ - return player_can_hear(p.x, p.y); -} +bool player_can_hear(const coord_def& p); unsigned char random_colour(); unsigned char random_uncommon_colour(); |