mirror of
https://github.com/TES3MP/TES3MP.git
synced 2025-09-28 23:51:09 -04:00
Make sure crime gold discounts don't reduce price to zero
This commit is contained in:
parent
1320ac6983
commit
63fd04882a
@ -2589,6 +2589,12 @@ namespace MWWorld
|
||||
int discount = bounty * fCrimeGoldDiscountMult;
|
||||
int turnIn = bounty * fCrimeGoldTurnInMult;
|
||||
|
||||
if (bounty > 0)
|
||||
{
|
||||
discount = std::max(1, discount);
|
||||
turnIn = std::max(1, turnIn);
|
||||
}
|
||||
|
||||
mGlobalVariables["pchascrimegold"].setInteger((bounty <= playerGold) ? 1 : 0);
|
||||
|
||||
mGlobalVariables["pchasgolddiscount"].setInteger((discount <= playerGold) ? 1 : 0);
|
||||
|
Loading…
x
Reference in New Issue
Block a user