public_static
Recruit

In my current game for e1.4.2 in Amprela there is a lot of hardwood for sale so I thought why not:
Starting amount for sale | Cost Displayed | The Item is n% x than average | Colour Shown | amount purchased
---------------------------------|-----------------------|-------------------------------------------| -------------------|--------------------------
52 | 42 | n=68% Cheaper | Green | 1
51 | 42 | n=68% Cheaper | Green | 5
46 | 53 | n=72% Cheaper | Green | 6
40 | 44 | n=76% Cheaper | Green | 5
35 | 45 | n=80% Cheaper | Green | 5
30 | 46 | n=84% Cheaper | Green | 5
25 | 47 | n=88% Cheaper | Green | 4
21 | 48 | n=92% Cheaper | Green | 4
17 | 49 | n=96% Cheaper | Green | 3
14 | 50 | n=100% Cheaper | Green | 4
10 | 51 | n=104% Cheaper | Green | 3
7 | 52 | n=108% Cheaper | Green | 3
4 | 53 | This item is near its average price | yellow | 3
1 | 53 | This item is near its average price | yellow | 1
The formula for the % is incorrect, it should not be getting more cheaper the more you buy, it should be going the other way. If people are reviewing the popup for % cheapness be in mind the actual value is likely to be closer to (109% - value displayed), which is a lot to work out on the fly,
Please check code.
Starting amount for sale | Cost Displayed | The Item is n% x than average | Colour Shown | amount purchased
---------------------------------|-----------------------|-------------------------------------------| -------------------|--------------------------
52 | 42 | n=68% Cheaper | Green | 1
51 | 42 | n=68% Cheaper | Green | 5
46 | 53 | n=72% Cheaper | Green | 6
40 | 44 | n=76% Cheaper | Green | 5
35 | 45 | n=80% Cheaper | Green | 5
30 | 46 | n=84% Cheaper | Green | 5
25 | 47 | n=88% Cheaper | Green | 4
21 | 48 | n=92% Cheaper | Green | 4
17 | 49 | n=96% Cheaper | Green | 3
14 | 50 | n=100% Cheaper | Green | 4
10 | 51 | n=104% Cheaper | Green | 3
7 | 52 | n=108% Cheaper | Green | 3
4 | 53 | This item is near its average price | yellow | 3
1 | 53 | This item is near its average price | yellow | 1
The formula for the % is incorrect, it should not be getting more cheaper the more you buy, it should be going the other way. If people are reviewing the popup for % cheapness be in mind the actual value is likely to be closer to (109% - value displayed), which is a lot to work out on the fly,
Please check code.
