diff options
author | Adam Borowski <kilobyte@angband.pl> | 2013-10-29 12:46:54 +0100 |
---|---|---|
committer | Adam Borowski <kilobyte@angband.pl> | 2013-10-29 12:46:54 +0100 |
commit | c50ef73cf1b0a965f288834b1db4f82696a9eabf (patch) | |
tree | 57be4e6b6193852a0d9105ee2761aa635a62c44f /crawl-ref/source/artefact.cc | |
parent | c86e462775f656f55f25c4c0a5d23695ae24ec23 (diff) | |
download | crawl-ref-c50ef73cf1b0a965f288834b1db4f82696a9eabf.tar.gz crawl-ref-c50ef73cf1b0a965f288834b1db4f82696a9eabf.zip |
Specify upgrade inhibition in art-data.txt
Diffstat (limited to 'crawl-ref/source/artefact.cc')
-rw-r--r-- | crawl-ref/source/artefact.cc | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/crawl-ref/source/artefact.cc b/crawl-ref/source/artefact.cc index e30974ff3e..03c1e7d723 100644 --- a/crawl-ref/source/artefact.cc +++ b/crawl-ref/source/artefact.cc @@ -1172,6 +1172,9 @@ void setup_unrandart(item_def &item) CrawlVector &rap = item.props[ARTEFACT_PROPS_KEY].get_vector(); const unrandart_entry *unrand = _seekunrandart(item); + if (unrand->prpty[ARTP_NO_UPGRADE] && item.props.exists(ARTEFACT_NAME_KEY)) + return; // don't mangle mutable items + for (int i = 0; i < ART_PROPERTIES; i++) rap[i] = static_cast<short>(unrand->prpty[i]); |