Price Calculations Inaccurate #95


  • New
  • Defect
Open
Assigned to _ForgeUser6956315
  • _ForgeUser9275026 created this issue Jul 22, 2012

    If at stock level 128 IRONINGOT is worth $60.93 and I buy and sell 64, the price should now be 60.93. Or to put it another way, for a given set ceiling, floor, stock, and span, price should always be the same. Yet it is not. As the log below shows, the price returns to $73.60 not $73.91. Executing /renewpricing will then set it to the expected value.

    If the stock is = 0, the value is not the ceiling price (250). It's $183.32.

    For testing purposes, these are the the values for IRONINGOT:

    Ceiling: 250 Floor: 20 Span: 6 Initial stock: 128 Initial price: $60.93

    Here is a screenshot confirming that the values are set correctly:

    values for iron

    What version of DynamicEconomy are you using?: .9.2

    Try to explain how to arrive at the problem:

    1. Installed Vault & DE
    2. Configured IRONINGOT: Ceiling 250, Floor 20, Span 6
    3. Set stock to 128
    4. Did some buying and selling.

    Log:

    • [2012-07-22 19:13:04.882] AgrippaHX succesfully sold 64 of 'IRONINGOT' for 4664.2
    • [2012-07-22 19:13:04.883] New price of IRONINGOT changed dynamically to 73.91(-176.09)
    • [2012-07-22 19:13:26.579] AgrippaHX succesfully sold 64 of 'IRONINGOT' for 3185.32
    • [2012-07-22 19:13:26.58] New price of IRONINGOT changed dynamically to 60.93(-12.98)
    • [2012-07-22 19:13:33.376] AgrippaHX bought 64 of 'IRONINGOT' for 4247.099999999999
    • [2012-07-22 19:13:33.377] New price of IRONINGOT changed dynamically to 73.6(+12.67)
  • _ForgeUser9275026 added the tags New Defect Jul 22, 2012
  • _ForgeUser9275026 posted a comment Jul 22, 2012

    I should also add that if I buy the entire stock (stock = 0), the price is $183.32. At stock zero, the price should be the ceiling price (250), right?


    Edited Jul 22, 2012
  • _ForgeUser9275026 edited description Jul 22, 2012

To post a comment, please login or register a new account.