diff options
author | haranp <haranp@c06c8d41-db1a-0410-9941-cceddc491573> | 2009-02-11 20:36:46 +0000 |
---|---|---|
committer | haranp <haranp@c06c8d41-db1a-0410-9941-cceddc491573> | 2009-02-11 20:36:46 +0000 |
commit | f5ce15870a0d4ae042a704065df4d0cdbbda0506 (patch) | |
tree | 3b8b31a38729b64be106930df581aef7197c6202 /crawl-ref/source/abl-show.cc | |
parent | 50a255f8eaad1124e731f6fb1de417baaa133a80 (diff) | |
download | crawl-ref-f5ce15870a0d4ae042a704065df4d0cdbbda0506.tar.gz crawl-ref-f5ce15870a0d4ae042a704065df4d0cdbbda0506.zip |
Fix [2586695]: you can no longer throw items (including via Portal
Projectile) if you can't wield weapons.
Don't allow base-shape breath attacks when shapechanged, except
for Nagas in spider form.
Fix [2589913]: melded shields counted for heavy armour penalties.
git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@9026 c06c8d41-db1a-0410-9941-cceddc491573
Diffstat (limited to 'crawl-ref/source/abl-show.cc')
-rw-r--r-- | crawl-ref/source/abl-show.cc | 47 |
1 files changed, 26 insertions, 21 deletions
diff --git a/crawl-ref/source/abl-show.cc b/crawl-ref/source/abl-show.cc index 9924f8b957..927eb987ed 100644 --- a/crawl-ref/source/abl-show.cc +++ b/crawl-ref/source/abl-show.cc @@ -2089,31 +2089,37 @@ std::vector<talent> your_talents( bool check_confused ) if (you.species == SP_MUMMY && you.experience_level >= 13) _add_talent(talents, ABIL_MUMMY_RESTORATION, check_confused); - if (you.species == SP_NAGA) + // Spit Poison. Nontransformed nagas can upgrade to Breathe Poison. + // Transformed nagas, or non-nagas, can only get Spit Poison. + if (you.species == SP_NAGA + && (!transform_changed_physiology() + || you.attribute[ATTR_TRANSFORMATION] == TRAN_SPIDER)) { _add_talent(talents, player_mutation_level(MUT_BREATHE_POISON) ? ABIL_BREATHE_POISON : ABIL_SPIT_POISON, check_confused); } - else if (player_mutation_level(MUT_SPIT_POISON)) - _add_talent(talents, ABIL_SPIT_POISON, check_confused ); + else if (player_mutation_level(MUT_SPIT_POISON) + || player_mutation_level(MUT_BREATHE_POISON)) + { + _add_talent(talents, ABIL_SPIT_POISON, check_confused); + } - if (player_genus(GENPC_DRACONIAN)) + if (player_genus(GENPC_DRACONIAN) + && you.experience_level >= 7 + && !transform_changed_physiology()) { - if (you.experience_level >= 7) - { - const ability_type ability = ( - (you.species == SP_GREEN_DRACONIAN) ? ABIL_BREATHE_POISON : - (you.species == SP_RED_DRACONIAN) ? ABIL_BREATHE_FIRE : - (you.species == SP_WHITE_DRACONIAN) ? ABIL_BREATHE_FROST : - (you.species == SP_YELLOW_DRACONIAN) ? ABIL_SPIT_ACID : - (you.species == SP_BLACK_DRACONIAN) ? ABIL_BREATHE_LIGHTNING : - (you.species == SP_PURPLE_DRACONIAN) ? ABIL_BREATHE_POWER : - (you.species == SP_PALE_DRACONIAN) ? ABIL_BREATHE_STEAM : - (you.species == SP_MOTTLED_DRACONIAN)? ABIL_BREATHE_STICKY_FLAME - : ABIL_NON_ABILITY); - if (ability != ABIL_NON_ABILITY) - _add_talent(talents, ability, check_confused ); - } + const ability_type ability = ( + (you.species == SP_GREEN_DRACONIAN) ? ABIL_BREATHE_POISON : + (you.species == SP_RED_DRACONIAN) ? ABIL_BREATHE_FIRE : + (you.species == SP_WHITE_DRACONIAN) ? ABIL_BREATHE_FROST : + (you.species == SP_YELLOW_DRACONIAN) ? ABIL_SPIT_ACID : + (you.species == SP_BLACK_DRACONIAN) ? ABIL_BREATHE_LIGHTNING : + (you.species == SP_PURPLE_DRACONIAN) ? ABIL_BREATHE_POWER : + (you.species == SP_PALE_DRACONIAN) ? ABIL_BREATHE_STEAM : + (you.species == SP_MOTTLED_DRACONIAN)? ABIL_BREATHE_STICKY_FLAME + : ABIL_NON_ABILITY); + if (ability != ABIL_NON_ABILITY) + _add_talent(talents, ability, check_confused ); } if (you.species == SP_VAMPIRE && you.experience_level >= 3 @@ -2123,7 +2129,7 @@ std::vector<talent> your_talents( bool check_confused ) _add_talent(talents, ABIL_TRAN_BAT, check_confused ); } - if (!player_is_airborne()) + if (!player_is_airborne() && !transform_changed_physiology()) { // Kenku can fly, but only from the ground // (until level 15, when it becomes permanent until revoked). @@ -2247,7 +2253,6 @@ std::vector<talent> your_talents( bool check_confused ) _add_talent(talents, ABIL_EVOKE_TURN_INVISIBLE, check_confused ); } - // jmf: "upgrade" for draconians -- expensive flight // Note: This ability only applies to this counter. if (player_equip( EQ_RINGS, RING_LEVITATION ) || player_equip_ego_type( EQ_BOOTS, SPARM_LEVITATION ) |