Reversing Morrowind's formulas

Everything about development and the OpenMW source code.
Post Reply
User avatar
jvoisin
Posts: 303
Joined: 11 Aug 2011, 18:47
Contact:

Reversing Morrowind's formulas

Post by jvoisin »

A few tips about reversing Morowind's formulas :
  • The dedicated wiki page is here. Be careful, not all formulas written here are exacts.
  • The dedicated topic on bethsoft forum is here
  • The uesp wiki is a great place to find stuffs.
  • We can try to contact Hrnchamd and Psyringe, respectively developer and test of the MPC
  • We can also try to contact Fliggerty, who might also know a thing or two about formulas
  • I don't think it's really relevant, but we can try to contact timeslip too (MGE and many Morrowind's internal related work)
  • When trying to get a formula, only change one parameter at a time
If you find something, don't forget to put it here

For contacts, we should coordinate our efforts, in order to avoid spamming : please state here who you are contacting.
Last edited by jvoisin on 30 May 2012, 15:03, edited 2 times in total.
User avatar
natirips
Posts: 52
Joined: 26 Apr 2012, 10:48
Location: Solar System/~Zagreb
Contact:

Re: Reversing Morrowind

Post by natirips »

A few days in bed (picked up some virus) and so many posts about this.

Anyway, from page 142 (156 physically) of MMM_Manual ( http://min.us/mChxB3o1o ):
In many cases where you see Base and Mult game settings, the formula they're involved in is a standard linear equation in the form y = mx + b, where m is the mult, b is the base, and x is some attribute, skill, or other value.
This may save a little bit of work for someone.

I've uploaded MMM Manual to minus.com (link again: http://min.us/mChxB3o1o ) because this forum says "The file is too big, maximum allowed size is 512 KiB.". Anyway, MMM Manual is free for non-profitable use so it should be okay to use it for OpenMW.
Sadler
Posts: 24
Joined: 30 May 2012, 13:53

Re: Reversing Morrowind's formulas

Post by Sadler »

After few hours of inventing the empiric buy price formula for items:

Code: Select all

Buy_Price = Base_Price * (210 + Merchant_Mercantile - Player_Mercantile - Relation) / 161
Please check this. It seems to be fairly accurate.
User avatar
scrawl
Posts: 2152
Joined: 18 Feb 2012, 11:51

Re: Reversing Morrowind's formulas

Post by scrawl »

Wow, nice. I will add that right away. Do you have any idea about the chance that the NPC accepts your offer? (if you leave the price at default, they always accept, i think)
Sadler
Posts: 24
Joined: 30 May 2012, 13:53

Re: Reversing Morrowind's formulas

Post by Sadler »

scrawl wrote:Wow, nice. I will add that right away. Do you have any idea about the chance that the NPC accepts your offer? (if you leave the price at default, they always accept, i think)
It will require much more trade tries for model with strong correlation. If I will have a huge amount of free time I'll do that work :D .
User avatar
Necrod
Posts: 251
Joined: 26 Mar 2012, 17:00
Location: Croatia/Pula

Re: Reversing Morrowind's formulas

Post by Necrod »

Sadler wrote:After few hours of inventing the empiric buy price formula for items:

Code: Select all

Buy_Price = Base_Price * (210 + Merchant_Mercantile - Player_Mercantile - Relation) / 161
Please check this. It seems to be fairly accurate.
Seems pretty accurate, but shouldn't it involve "luck" as well?
Sadler
Posts: 24
Joined: 30 May 2012, 13:53

Re: Reversing Morrowind's formulas

Post by Sadler »

Necrod wrote:Seems pretty accurate, but shouldn't it involve "luck" as well?
Oh, maybe. Give me a a few minutes, I'll check this.
Sadler
Posts: 24
Joined: 30 May 2012, 13:53

Re: Reversing Morrowind's formulas

Post by Sadler »

Player-merchant luck difference changes the cost. About 10-15% for luck change from 0 to 100.

We may simply add the correction:

Code: Select all

Buy_Price = 26 - 0.6077*Player_Luck + Base_Price * (210 + Merchant_Mercantile - Player_Mercantile - Relation) / 161
Not so straight as first formula, but must work.
User avatar
heilkitty
Posts: 158
Joined: 11 Aug 2011, 07:57
Location: Vivec City, MW
Contact:

Re: Reversing Morrowind's formulas

Post by heilkitty »

I reckon, some of the numbers should be GMSTs and not hardcoded. I don't have access to Morrowind right now, so I can't help with that, but you could use some mod that changes trading significantly (e.g. BTB GI Settings) for reference.
User avatar
natirips
Posts: 52
Joined: 26 Apr 2012, 10:48
Location: Solar System/~Zagreb
Contact:

Re: Reversing Morrowind's formulas

Post by natirips »

MMM Manual has most (if not all) game settings' default values and descriptions on page 142 (156).
Post Reply