mirror of
https://github.com/OpenMW/openmw.git
synced 2025-06-21 08:41:33 +00:00
Merge branch 'hammerthingstilltheybreak' into 'master'
Don't let the player repair items that are better than new Closes #8171 See merge request OpenMW/openmw!4381
This commit is contained in:
commit
b6c1e33da6
3 changed files with 3 additions and 2 deletions
|
@ -191,6 +191,7 @@
|
||||||
Bug #8097: GetEffect doesn't detect 0 magnitude spells
|
Bug #8097: GetEffect doesn't detect 0 magnitude spells
|
||||||
Bug #8124: Normal weapon resistance is applied twice for NPCs
|
Bug #8124: Normal weapon resistance is applied twice for NPCs
|
||||||
Bug #8132: Actors without hello responses turn to face the player
|
Bug #8132: Actors without hello responses turn to face the player
|
||||||
|
Bug #8171: Items with more than 100% health can be repaired
|
||||||
Feature #1415: Infinite fall failsafe
|
Feature #1415: Infinite fall failsafe
|
||||||
Feature #2566: Handle NAM9 records for manual cell references
|
Feature #2566: Handle NAM9 records for manual cell references
|
||||||
Feature #3501: OpenMW-CS: Instance Editing - Shortcuts for axial locking
|
Feature #3501: OpenMW-CS: Instance Editing - Shortcuts for axial locking
|
||||||
|
|
|
@ -55,7 +55,7 @@ namespace MWGui
|
||||||
{
|
{
|
||||||
int maxDurability = iter->getClass().getItemMaxHealth(*iter);
|
int maxDurability = iter->getClass().getItemMaxHealth(*iter);
|
||||||
int durability = iter->getClass().getItemHealth(*iter);
|
int durability = iter->getClass().getItemHealth(*iter);
|
||||||
if (maxDurability == durability || maxDurability == 0)
|
if (maxDurability <= durability || maxDurability == 0)
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
int basePrice = iter->getClass().getValue(*iter);
|
int basePrice = iter->getClass().getValue(*iter);
|
||||||
|
|
|
@ -288,7 +288,7 @@ namespace MWGui
|
||||||
|
|
||||||
if ((mFilter & Filter_OnlyRepairable)
|
if ((mFilter & Filter_OnlyRepairable)
|
||||||
&& (!base.getClass().hasItemHealth(base)
|
&& (!base.getClass().hasItemHealth(base)
|
||||||
|| (base.getClass().getItemHealth(base) == base.getClass().getItemMaxHealth(base))
|
|| (base.getClass().getItemHealth(base) >= base.getClass().getItemMaxHealth(base))
|
||||||
|| (base.getType() != ESM::Weapon::sRecordId && base.getType() != ESM::Armor::sRecordId)))
|
|| (base.getType() != ESM::Weapon::sRecordId && base.getType() != ESM::Armor::sRecordId)))
|
||||||
return false;
|
return false;
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue