diff options
author | haranp <haranp@c06c8d41-db1a-0410-9941-cceddc491573> | 2007-04-29 08:47:39 +0000 |
---|---|---|
committer | haranp <haranp@c06c8d41-db1a-0410-9941-cceddc491573> | 2007-04-29 08:47:39 +0000 |
commit | b51817cbfd4a52f6d66ed5e7580ad3b0c75ffef2 (patch) | |
tree | 104821515eb763049e31194aa56b0e4a87ee180e /crawl-ref/source | |
parent | 04d222f4d73f54788556281eabb2e09aae7ff20d (diff) | |
download | crawl-ref-b51817cbfd4a52f6d66ed5e7580ad3b0c75ffef2.tar.gz crawl-ref-b51817cbfd4a52f6d66ed5e7580ad3b0c75ffef2.zip |
Teeny bit more typesafety.
git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@1392 c06c8d41-db1a-0410-9941-cceddc491573
Diffstat (limited to 'crawl-ref/source')
-rw-r--r-- | crawl-ref/source/transfor.cc | 5 | ||||
-rw-r--r-- | crawl-ref/source/transfor.h | 2 |
2 files changed, 5 insertions, 2 deletions
diff --git a/crawl-ref/source/transfor.cc b/crawl-ref/source/transfor.cc index 887b42521b..36f067063c 100644 --- a/crawl-ref/source/transfor.cc +++ b/crawl-ref/source/transfor.cc @@ -110,7 +110,7 @@ size_type player::transform_size(int psize) const } } -bool transform(int pow, char which_trans) +bool transform(int pow, transformation_type which_trans) { if (you.species == SP_MERFOLK && player_is_swimming() && which_trans != TRAN_DRAGON) @@ -359,6 +359,9 @@ bool transform(int pow, char which_trans) you.symbol = 'S'; you.colour = RED; return (true); + case TRAN_NONE: + case NUM_TRANSFORMATIONS: + break; } return (false); diff --git a/crawl-ref/source/transfor.h b/crawl-ref/source/transfor.h index e292122559..8d62f730c7 100644 --- a/crawl-ref/source/transfor.h +++ b/crawl-ref/source/transfor.h @@ -36,7 +36,7 @@ size_type transform_size(int psize = PSIZE_BODY); /* *********************************************************************** * called from: ability - spell * *********************************************************************** */ -bool transform(int pow, char which_trans); +bool transform(int pow, transformation_type which_trans); // last updated 12may2000 {dlb} |