diff options
author | Jared Tinney (Twinge) <homelesspete@gmail.com> | 2010-02-09 01:50:34 -0800 |
---|---|---|
committer | Jude Brown <bookofjude@users.sourceforge.net> | 2010-02-09 19:22:29 +1000 |
commit | 51d572c98b3c2d20eacfe9942c13c015865ff6b8 (patch) | |
tree | 2ab343b7e17a649b03bb0f17ca8a10a59de6f615 /crawl-ref/source/l_mons.cc | |
parent | 03d233ae5391aed05d619f26ef1bf8cbdbb05ac9 (diff) | |
download | crawl-ref-51d572c98b3c2d20eacfe9942c13c015865ff6b8.tar.gz crawl-ref-51d572c98b3c2d20eacfe9942c13c015865ff6b8.zip |
dlua mons.mimic check returns mimic type. Place-pop sorting.
Place-pop script now groups mimics, dancing weapons, and very ugly
things properly. Added sort by count option.
Signed-off-by: Jude Brown <bookofjude@users.sourceforge.net>
Diffstat (limited to 'crawl-ref/source/l_mons.cc')
-rw-r--r-- | crawl-ref/source/l_mons.cc | 18 |
1 files changed, 17 insertions, 1 deletions
diff --git a/crawl-ref/source/l_mons.cc b/crawl-ref/source/l_mons.cc index 721939a2d2..fddfb8c132 100644 --- a/crawl-ref/source/l_mons.cc +++ b/crawl-ref/source/l_mons.cc @@ -114,7 +114,23 @@ MDEF(mimic) { ASSERT_DLUA; if (mons_genus(mons->type) == MONS_GOLD_MIMIC) - lua_pushstring(ls, "mimic"); + { + switch (mons->type) + { + case MONS_GOLD_MIMIC: + lua_pushstring(ls, "gold mimic"); break; + case MONS_WEAPON_MIMIC: + lua_pushstring(ls, "weapon mimic"); break; + case MONS_ARMOUR_MIMIC: + lua_pushstring(ls, "armour mimic"); break; + case MONS_POTION_MIMIC: + lua_pushstring(ls, "potion mimic"); break; + case MONS_SCROLL_MIMIC: + lua_pushstring(ls, "scroll mimic"); break; + default: + lua_pushstring(ls, "unknown mimic"); break; + } + } else lua_pushnil(ls); |