mirror of
https://github.com/TES3MP/TES3MP.git
synced 2025-09-28 07:32:00 -04:00
Use relative stat difference for haggling
This commit is contained in:
parent
b7026df551
commit
24c1ee7744
@ -32,7 +32,6 @@ namespace MWMechanics
|
|||||||
|
|
||||||
// Is the player buying?
|
// Is the player buying?
|
||||||
bool buying = (merchantOffer < 0);
|
bool buying = (merchantOffer < 0);
|
||||||
|
|
||||||
int a = std::abs(merchantOffer);
|
int a = std::abs(merchantOffer);
|
||||||
int b = std::abs(playerOffer);
|
int b = std::abs(playerOffer);
|
||||||
int d = (buying)
|
int d = (buying)
|
||||||
@ -56,7 +55,7 @@ namespace MWMechanics
|
|||||||
float npcTerm = (d1 + e1 + f1) * merchantStats.getFatigueTerm();
|
float npcTerm = (d1 + e1 + f1) * merchantStats.getFatigueTerm();
|
||||||
float x = gmst.find("fBargainOfferMulti")->getFloat() * d
|
float x = gmst.find("fBargainOfferMulti")->getFloat() * d
|
||||||
+ gmst.find("fBargainOfferBase")->getFloat()
|
+ gmst.find("fBargainOfferBase")->getFloat()
|
||||||
+ std::abs(int(pcTerm - npcTerm));
|
+ int(pcTerm - npcTerm);
|
||||||
|
|
||||||
int roll = Misc::Rng::rollDice(100) + 1;
|
int roll = Misc::Rng::rollDice(100) + 1;
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user