From fcd9b439a1b1671fac1d7b43bb982234ad2639b5 Mon Sep 17 00:00:00 2001 From: Andrettin Date: Fri, 1 Jan 2016 18:44:41 +0100 Subject: [PATCH] Time efficiency bonus now properly appears with a "%" in the effects strings --- src/stratagus/item.cpp | 4 ++-- src/unit/upgrade.cpp | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/stratagus/item.cpp b/src/stratagus/item.cpp index 5acbc3f6d..abdb6be28 100644 --- a/src/stratagus/item.cpp +++ b/src/stratagus/item.cpp @@ -334,7 +334,7 @@ std::string GetUniqueItemEffectsString(std::string item_name) || var == AIRRESISTANCE_INDEX || var == EARTHRESISTANCE_INDEX || var == WATERRESISTANCE_INDEX || var == HACKRESISTANCE_INDEX || var == PIERCERESISTANCE_INDEX || var == BLUNTRESISTANCE_INDEX || var == ACCURACY_INDEX || var == EVASION_INDEX || var == SPEED_INDEX || var == BACKSTAB_INDEX - || var == HITPOINTHEALING_INDEX || var == HITPOINTBONUS_INDEX || var == SIGHTRANGE_INDEX || var == GIVERESOURCE_INDEX) + || var == HITPOINTHEALING_INDEX || var == HITPOINTBONUS_INDEX || var == SIGHTRANGE_INDEX || var == GIVERESOURCE_INDEX || var == TIMEEFFICIENCYBONUS_INDEX) ) { continue; } @@ -371,7 +371,7 @@ std::string GetUniqueItemEffectsString(std::string item_name) item_effects_string += "+"; } item_effects_string += std::to_string((long long) variable_value); - if (var == BACKSTAB_INDEX || var == FIRERESISTANCE_INDEX || var == COLDRESISTANCE_INDEX || var == ARCANERESISTANCE_INDEX || var == LIGHTNINGRESISTANCE_INDEX || var == AIRRESISTANCE_INDEX || var == EARTHRESISTANCE_INDEX || var == WATERRESISTANCE_INDEX || var == HACKRESISTANCE_INDEX || var == PIERCERESISTANCE_INDEX || var == BLUNTRESISTANCE_INDEX) { + if (var == BACKSTAB_INDEX || var == FIRERESISTANCE_INDEX || var == COLDRESISTANCE_INDEX || var == ARCANERESISTANCE_INDEX || var == LIGHTNINGRESISTANCE_INDEX || var == AIRRESISTANCE_INDEX || var == EARTHRESISTANCE_INDEX || var == WATERRESISTANCE_INDEX || var == HACKRESISTANCE_INDEX || var == PIERCERESISTANCE_INDEX || var == BLUNTRESISTANCE_INDEX || var == TIMEEFFICIENCYBONUS_INDEX) { item_effects_string += "%"; } item_effects_string += " "; diff --git a/src/unit/upgrade.cpp b/src/unit/upgrade.cpp index 8816a17ec..3905f332c 100644 --- a/src/unit/upgrade.cpp +++ b/src/unit/upgrade.cpp @@ -1929,7 +1929,7 @@ std::string GetUpgradeEffectsString(std::string upgrade_ident) upgrade_effects_string += "+"; } upgrade_effects_string += std::to_string((long long) UpgradeModifiers[z]->Modifier.Variables[var].Value); - if (var == BACKSTAB_INDEX || var == FIRERESISTANCE_INDEX || var == COLDRESISTANCE_INDEX || var == ARCANERESISTANCE_INDEX || var == LIGHTNINGRESISTANCE_INDEX || var == AIRRESISTANCE_INDEX || var == EARTHRESISTANCE_INDEX || var == WATERRESISTANCE_INDEX || var == HACKRESISTANCE_INDEX || var == PIERCERESISTANCE_INDEX || var == BLUNTRESISTANCE_INDEX) { + if (var == BACKSTAB_INDEX || var == FIRERESISTANCE_INDEX || var == COLDRESISTANCE_INDEX || var == ARCANERESISTANCE_INDEX || var == LIGHTNINGRESISTANCE_INDEX || var == AIRRESISTANCE_INDEX || var == EARTHRESISTANCE_INDEX || var == WATERRESISTANCE_INDEX || var == HACKRESISTANCE_INDEX || var == PIERCERESISTANCE_INDEX || var == BLUNTRESISTANCE_INDEX || var == TIMEEFFICIENCYBONUS_INDEX) { upgrade_effects_string += "%"; } upgrade_effects_string += " ";