From 5005b19f2e07a1a55fd28658de69a36b64dea12c Mon Sep 17 00:00:00 2001 From: planqi Date: Wed, 1 May 2019 12:45:19 -0800 Subject: [PATCH] fix `ARMOR` selector --- BH/Modules/Item/ItemDisplay.cpp | 2 +- README.md | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/BH/Modules/Item/ItemDisplay.cpp b/BH/Modules/Item/ItemDisplay.cpp index 1761e967..3c9991b5 100644 --- a/BH/Modules/Item/ItemDisplay.cpp +++ b/BH/Modules/Item/ItemDisplay.cpp @@ -667,7 +667,7 @@ void Condition::BuildConditions(vector &conditions, string token) { Condition::AddOperand(conditions, new ItemStatCondition(STAT_MINIMUMDAMAGE, 0, operation, value)); } else if (key.compare(0, 6, "MAXDMG") == 0) { Condition::AddOperand(conditions, new ItemStatCondition(STAT_MAXIMUMDAMAGE, 0, operation, value)); - } else if (key.compare(0, 2, "AR") == 0) { + } else if (key.compare(0, 2, "AR") == 0 && keylen == 2) { Condition::AddOperand(conditions, new ItemStatCondition(STAT_ATTACKRATING, 0, operation, value)); } else if (key.compare(0, 3, "DTM") == 0) { Condition::AddOperand(conditions, new ItemStatCondition(STAT_DAMAGETOMANA, 0, operation, value)); diff --git a/README.md b/README.md index e691363d..08129e86 100644 --- a/README.md +++ b/README.md @@ -72,7 +72,7 @@ Mustache[stash]: {{#this}}* {{>item}}\n\n{{/this}} * `BELT` `CHEST` `HELM` `SHIELD` `GLOVES` `BOOTS` `CIRC` * `AXE` `MACE` `SWORD` `DAGGER` `THROWING` `JAV` `SPEAR` `POLEARM` `BOW` `XBOW` `STAFF` `WAND` `SCEPTER` * They have the same functionality as `WP1` and `EQ1` style selectors -* Fixed `JAV`/`WP6` selectors +* Fixed `JAV`/`WP6` and `ARMOR` selectors # Release Notes for 1.9.2 * Add custom notification colors `%notify-1%`