diff options
author | Adam Borowski <kilobyte@angband.pl> | 2010-12-10 13:58:34 +0100 |
---|---|---|
committer | Adam Borowski <kilobyte@angband.pl> | 2010-12-10 14:06:15 +0100 |
commit | ebc64e93b04ad92c1652180c250bc5bc7d70518d (patch) | |
tree | 7a001e54a5fd79b3db72a8485ae5774abb360c2c /crawl-ref/source/spl-monench.cc | |
parent | 3f2134ce119e4285323e646aadf20b887b7ee403 (diff) | |
download | crawl-ref-ebc64e93b04ad92c1652180c250bc5bc7d70518d.tar.gz crawl-ref-ebc64e93b04ad92c1652180c250bc5bc7d70518d.zip |
Thin spellbooks somewhat.
* Bone Shards: 0 use both in 0.4 and 0.7 winner stats. Requires tedious
messing with components.
* Tame Beasts: 0 use, gives very weak pets for its level, with lots of
preparation can be abused ("Rupert farming").
* Portal: very little use, convoluted mechanics.
Diffstat (limited to 'crawl-ref/source/spl-monench.cc')
-rw-r--r-- | crawl-ref/source/spl-monench.cc | 63 |
1 files changed, 0 insertions, 63 deletions
diff --git a/crawl-ref/source/spl-monench.cc b/crawl-ref/source/spl-monench.cc index da32620100..ad03da3661 100644 --- a/crawl-ref/source/spl-monench.cc +++ b/crawl-ref/source/spl-monench.cc @@ -51,69 +51,6 @@ void cast_mass_sleep(int pow) apply_area_visible(_sleep_monsters, pow); } -// This is a hack until we set an is_beast flag in the monster data -// (which we might never do, this is sort of minor.) -// It's a list of monster types which can be affected by beast taming. -static bool _is_domesticated_animal(int type) -{ - const monster_type types[] = { - MONS_GIANT_BAT, MONS_HOUND, MONS_JACKAL, MONS_RAT, - MONS_YAK, MONS_WYVERN, MONS_HIPPOGRIFF, MONS_GRIFFON, - MONS_DEATH_YAK, MONS_WAR_DOG, MONS_GREY_RAT, - MONS_GREEN_RAT, MONS_ORANGE_RAT, MONS_SHEEP, - MONS_HOG, MONS_GIANT_FROG, MONS_GIANT_TOAD, - MONS_SPINY_FROG, MONS_BLINK_FROG, MONS_WOLF, MONS_WARG, - MONS_BEAR, MONS_GRIZZLY_BEAR, MONS_POLAR_BEAR, MONS_BLACK_BEAR - }; - - for (unsigned int i = 0; i < ARRAYSZ(types); ++i) - if (types[i] == type) - return (true); - - return (false); -} - -static int _tame_beast_monsters(coord_def where, int pow, int, actor *) -{ - monster* mons = monster_at(where); - if (mons == NULL) - return 0; - - if (!_is_domesticated_animal(mons->type) || mons->friendly() - || player_will_anger_monster(mons)) - { - return 0; - } - - if (you.species == SP_CAT && mons_genus(mons->type) == MONS_HOUND) - return 0; - - // 50% bonus for dogs - if (mons->type == MONS_HOUND || mons->type == MONS_WAR_DOG) - pow += (pow / 2); - - if (you.species == SP_HILL_ORC && mons->type == MONS_WARG) - pow += (pow / 2); - - if (mons->check_res_magic(pow) > 0) - return 0; - - simple_monster_message(mons, " is tamed!"); - - if (random2(100) < random2(pow / 10)) - mons->attitude = ATT_FRIENDLY; // permanent - else - mons->add_ench(ENCH_CHARM); // temporary - mons_att_changed(mons); - - return 1; -} - -void cast_tame_beasts(int pow) -{ - apply_area_visible(_tame_beast_monsters, pow); -} - bool backlight_monsters(coord_def where, int pow, int garbage) { UNUSED(pow); |