1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.
  2. Hi there Guest! You should join our Minecraft server @ meepcraft.com
  3. We also have a Discord server that you can join @ https://discord.gg/B4shfCZjYx
  4. Purchase a rank upgrade and get it instantly in-game! Cookies Minecraft Discord Upgrade

Rounding error on vshop lets you jump to head of line

Discussion in 'Resolved/Denied' started by Pluto258, Oct 25, 2017.

  1. Pluto258

    Pluto258 Popular Meeper

    Offline
    Messages:
    332
    Likes Received:
    154
    Bug: Rounding error on vshop lets you jump to head of line

    IGN: Pluto258

    Date of Bug: reporting 10/25/17

    Summary of Bug: There is a rounding error with vshop that lets you jump to the head of the line with the same price as the cheapest person. Example player A has signs up on /vshop for 34. Player B does "/sell 10 sign 33.999" this will place player B signs in the front of the line for 34. I know there used to be a hiccup with vshop where if you posted for the same price you had about a 1% chance of accidentally being placed in front. Recently Blakek13 has been jumping the line multiple times a day, way too much for the accidental placement.

    Evidence of Bug:

    Additional information: Just today he is at the front of the line with the same lowest price in sign, wheat, jackolantern, potato, paper and sunflower. He and i have been battling back and forth on vshop recently. I repriced my sign and wheat prices before deciding to fill a bug report. i left the rest. I was on a little after 10pm est last night and posted some stuff to vshop. I noticed blakek13's vshop prices at around 7:30 am est this morning.
     
    Last edited: Oct 25, 2017
  2. jadenPete

    jadenPete Code Writer & Meme Trader

    Offline
    Messages:
    335
    Likes Received:
    387
    What do you mean "jump to the front of line?"
     
  3. Pluto258

    Pluto258 Popular Meeper

    Offline
    Messages:
    332
    Likes Received:
    154
    If i understand how vshop works, when you post items at the same price as is already there, you go behind the person already selling, so their items sell first. If you want to move ahead of them, you have to post at a lower price. As I mentioned, there is a hiccup where less than 1% of the time, posting at the same price puts the newer seller ahead of the seller already there, but it is very rare.
    Using the rounding error, you can post new items at the same price as someone already on vshop, but be placed ahead of them in the queue, thus getting to sell your items first for the exact same price as someone who was already selling.
     
  4. lanekids40

    lanekids40 Popular Meeper

    Offline
    Messages:
    613
    Likes Received:
    483
    well if someone was selling signs for 40 meebles and you put up signs for 39.999 meebles than that means that the system works because it puts the lower price first. however the view-able price is rounded but it may not sell for 40 it sells for 39.999.
     
  5. Pluto258

    Pluto258 Popular Meeper

    Offline
    Messages:
    332
    Likes Received:
    154
    Except it sells the newer ones for 40 instead of 39.999. That's how you can "jump to the head of the line" and still get the same price as existing sellers. yes i tested this.
     
  6. FamousZAmos

    FamousZAmos Popular Meeper

    Offline
    Messages:
    1,158
    Likes Received:
    2,548
    tbh I used to do this a lot I don't think it's a bug at all. I would do signs for 39.95 in your case to make SURE your ahead, or make a wood farm to drastically lower the price (signs are worth more like 4 than 40 anyways)
    just because someone outsmarts you doesn't mean the system is broken
     
  7. Pluto258

    Pluto258 Popular Meeper

    Offline
    Messages:
    332
    Likes Received:
    154
    FamousZamos, I think you are missing my point.

    I have no problem with people posting stuff for less than me, that's how vshop works.

    What I feel is wrong here is that by taking advantage of the way the prices are rounded, and posting for a price that can't be charged and/or displayed, the other player is moving ahead of me in the queue for the EXACT same price as me, which in not the way the vshop is supposed to work.
    If it's not a bug, it could still be fixed by a change. Move the lines of code that decide where in the queue this posting of items belongs to the very end of the subroutine, so all other calculations and moving of any existing items of this type, are taken care of before hand, and it gets placed in the queue in the correct spot based on the existing rules.
     
  8. FamousZAmos

    FamousZAmos Popular Meeper

    Offline
    Messages:
    1,158
    Likes Received:
    2,548
    if you want a solution, removing thousandth-place digits from vshop should work, so only usuable values are shown tbh it's not hard
     
  9. Pluto258

    Pluto258 Popular Meeper

    Offline
    Messages:
    332
    Likes Received:
    154
    Famous - yea, that dawned on me about 1/2 an hour after my last reply. Much simpler solution.
     
    SuperDyl likes this.
  10. LordInateur

    LordInateur Deus Ex Machina Staff Member Administrator

    Offline
    Messages:
    490
    Likes Received:
    1,413
    @jadenPete this is a confirmed "unintended feature" but do you happen to know if the database stores the rounded version, or if it just displays as the rounded version?

    The best way to go about this would probably be to make it so that the price rounds down to the nearest cent, with the caveat that items couldn't be sold for any less than .01 meeble (or it would round down to 0). However, this is not a high-priority issue, so I'll mark it as "pending" but I don't see it getting fixed anytime soon.
     
  11. jadenPete

    jadenPete Code Writer & Meme Trader

    Offline
    Messages:
    335
    Likes Received:
    387
    I'll take a look soon, I have no idea at the moment.
     
  12. Pluto258

    Pluto258 Popular Meeper

    Offline
    Messages:
    332
    Likes Received:
    154
    Thank you both for your attention on this matter.

    Lordinateur - great gif. my son who just took Calculus cracked up when he saw it.
     
    LordInateur likes this.
  13. LordInateur

    LordInateur Deus Ex Machina Staff Member Administrator

    Offline
    Messages:
    490
    Likes Received:
    1,413

    It's my favorite xD our Math Club at my university shared it.
     
  14. SuperDyl

    SuperDyl Popular Meeper

    Offline
    Messages:
    1,016
    Likes Received:
    645
    I think this should be a quick fix, just take the place for input and immediately round the float to the hundredths or return an error if a number beyond hundredths is used. This may not be the largest problem ever, but it's a quick fix for a definite problem.
     
  15. LordInateur

    LordInateur Deus Ex Machina Staff Member Administrator

    Offline
    Messages:
    490
    Likes Received:
    1,413
    Probably in regard to the actual coding it's a quick fix; the bottleneck usually occurs through the testing stages (Murphy's Law) and various approval stages. While the fix itself is probably a small thing, it does end up affecting the speediness of other projects.
     
    SuperDyl likes this.
  16. CluelessKlutz

    CluelessKlutz Badmin

    Offline
    Messages:
    2,997
    Likes Received:
    7,356

Share This Page