diff options
author | Adam Borowski <kilobyte@angband.pl> | 2012-06-09 00:28:37 +0200 |
---|---|---|
committer | Adam Borowski <kilobyte@angband.pl> | 2012-06-09 00:57:02 +0200 |
commit | 046f7596c433ed781270a4bfbc54a1a414e5492f (patch) | |
tree | 2bb8a716464486d5bc4b96159f75cc187ce8865e /crawl-ref/source/tiledoll.cc | |
parent | 79308c8751c69b0d8d27c3c348658be4b8f945da (diff) | |
download | crawl-ref-046f7596c433ed781270a4bfbc54a1a414e5492f.tar.gz crawl-ref-046f7596c433ed781270a4bfbc54a1a414e5492f.zip |
Horny cat tiles (ontoclasm).
Checks for inappropriate combinations (possible due to the doll editor) are
really ugly, and in the editor you get series of tile parts that won't show
up. That's nothing new (nagas, etc), but points out how the doll editor is
unmaintained.
Diffstat (limited to 'crawl-ref/source/tiledoll.cc')
-rw-r--r-- | crawl-ref/source/tiledoll.cc | 32 |
1 files changed, 20 insertions, 12 deletions
diff --git a/crawl-ref/source/tiledoll.cc b/crawl-ref/source/tiledoll.cc index 6b17a1f00e..96b52e7369 100644 --- a/crawl-ref/source/tiledoll.cc +++ b/crawl-ref/source/tiledoll.cc @@ -282,9 +282,7 @@ void fill_doll_equipment(dolls_data &result) else if (item == -1) result.parts[TILEP_PART_HAND1] = 0; else - { result.parts[TILEP_PART_HAND1] = tilep_equ_weapon(you.inv[item]); - } } // Off hand. if (result.parts[TILEP_PART_HAND2] == TILEP_SHOW_EQUIP) @@ -325,18 +323,26 @@ void fill_doll_equipment(dolls_data &result) result.parts[TILEP_PART_HELM] = tilep_equ_helm(you.inv[item]); else if (player_mutation_level(MUT_HORNS) > 0) { - switch (player_mutation_level(MUT_HORNS)) + if (you.species == SP_FELID + && is_player_tile(result.parts[TILEP_PART_BASE], TILEP_BASE_FELID)) { - case 1: - result.parts[TILEP_PART_HELM] = TILEP_HELM_HORNS1; - break; - case 2: - result.parts[TILEP_PART_HELM] = TILEP_HELM_HORNS2; - break; - case 3: - result.parts[TILEP_PART_HELM] = TILEP_HELM_HORNS3; - break; + // Felid horns are offset by the tile variant. + result.parts[TILEP_PART_HELM] = TILEP_HELM_HORNS_CAT + + result.parts[TILEP_PART_BASE] - TILEP_BASE_FELID; } + else + switch (player_mutation_level(MUT_HORNS)) + { + case 1: + result.parts[TILEP_PART_HELM] = TILEP_HELM_HORNS1; + break; + case 2: + result.parts[TILEP_PART_HELM] = TILEP_HELM_HORNS2; + break; + case 3: + result.parts[TILEP_PART_HELM] = TILEP_HELM_HORNS3; + break; + } } else result.parts[TILEP_PART_HELM] = 0; @@ -362,6 +368,8 @@ void fill_doll_equipment(dolls_data &result) const int item = you.equip[EQ_GLOVES]; if (item != -1) result.parts[TILEP_PART_ARM] = tilep_equ_gloves(you.inv[item]); + else if (player_mutation_level(MUT_TENTACLE_SPIKE)) + result.parts[TILEP_PART_ARM] = TILEP_ARM_OCTOPODE_SPIKE; else if (you.has_claws(false) >= 3) result.parts[TILEP_PART_ARM] = TILEP_ARM_CLAWS; else |