diff options
author | Neil Moore <neil@s-z.org> | 2014-07-20 20:12:43 -0400 |
---|---|---|
committer | Neil Moore <neil@s-z.org> | 2014-07-20 20:14:12 -0400 |
commit | 8515cbe8708e4cc4772596babad9041b0f0fff65 (patch) | |
tree | 3aa46e40e7ee957f32ce5e188341d2671b6d8ae2 /crawl-ref/source/mapdef.cc | |
parent | 0aae9c8759863a1f793eed3f0786089c711928ca (diff) | |
download | crawl-ref-8515cbe8708e4cc4772596babad9041b0f0fff65.tar.gz crawl-ref-8515cbe8708e4cc4772596babad9041b0f0fff65.zip |
Allow giving derived undead equipment in mspecs (#8807)
Since they can be animated with equipment. This doesn't check that the
item is something a zombie/skeleton can use, so it's up to vault
designers not to make an centaur zombie ; shortbow .
Items are still disallowed if the zombie's base monster can't use
equipment, of if its base type is random.
Diffstat (limited to 'crawl-ref/source/mapdef.cc')
-rw-r--r-- | crawl-ref/source/mapdef.cc | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/crawl-ref/source/mapdef.cc b/crawl-ref/source/mapdef.cc index 24982bf68e..7bdd658c02 100644 --- a/crawl-ref/source/mapdef.cc +++ b/crawl-ref/source/mapdef.cc @@ -4113,7 +4113,11 @@ mons_list::mons_spec_slot mons_list::parse_mons_spec(string spec) } else if (mons_class_itemuse(type) < MONUSE_STARTING_EQUIPMENT && (!mons_class_is_animated_weapon(type) - || mspec.items.size() > 1)) + || mspec.items.size() > 1) + && (type != MONS_ZOMBIE && type != MONS_SKELETON + || invalid_monster_type(mspec.monbase) + || mons_class_itemuse(mspec.monbase) + < MONUSE_STARTING_EQUIPMENT)) { error = make_stringf("Monster '%s' can't use items.", mon_str.c_str()); |