Files
Bubberstation/code/controllers
ArcaneMusic 3a76cb27fe Arcargo: Balance Pass v2 on the Stock Market (#81580)
## About The Pull Request

Picking up where I left off on #81216. 

* Stock market stocks have had their market quantity drastically
reduced, as on both the more common and more rare material sides of
things these materials traditionally have been traded in quantities that
it would prevent bicycle like quantities of materials entering the game
while still allowing for access to rare materials at rare material rates
of credits.

* The stock market subsystem now fires once every 60 seconds, as opposed
to once every 20 seconds. To compensate for this, the subsystem now
makes much wider price changes every update, to disincentivize players
from just camping out at the stock market console all game, as this is
behavior we typically discourage (genetics/virology/etc). Material
tending times are similarly decreased to make up for that, while noting
that stock market events will still enable for a material to change
directions at any point as well.

* Material prices can drop below their minimum trading threshold,
resulting in them gaining protected purchasing status, and resulting in
them being unavailable for purchase. This means if you're watching a
price drop, and it's still trending lower, there's a distinct chance you
might want to buy before it drops below the threshold, or risk it, buy
later, and avoid the material getting locked out for another minute or
more.

* Adds 2 new stock market events to help add additional variety to the
stock market's variability, while adjusting the probability of a market
event occurring per stock market event. This should average to ~4 events
every minute, keeping things somewhat interesting if you're watching the
prices of items, but without requiring second to second updates to keep
things engaging.
* These two events include one that blocks off all material quantity
from a material for the duration of the event and resets prices when
complete, and another one that maximizes the profitability of a
material, but leaves it's market quantity up in the air.

* Stock blocks have had their freeze timer decreased from 5 minutes,
down to 3, with the warning now at 1.5 minutes. This is to encourage
players not to sit on their resources for longer periods of time if
their goal is just to sell at a specific price point and to keep items
going through the shuttle, which _also_ encourages players to receive
mail/receive regular orders from the rest of the crew.

* The UI has a number of improvements, those being:
* The time until the next stock market update is listed on the UI as an
active timer.
* The materials listed in the UI are now sorted by the value of that
resource per unit.
* The instructions are now kept within a collapsible component to cut
down on wasted space within the UI.
* A few elements are moved over to % width as opposed to a hardset x
pixels width for screen size compatibility purposes.


![image](https://github.com/tgstation/tgstation/assets/41715314/b8c7b00a-947e-421b-aa18-2b77f0b9bb50)

## Why It's Good For The Game

Stock market has been known to create bike levels of wealth with near
negligible amounts of effort and was going to need a balance pass
eventually. This is being accomplished by slowing down the system, but
also making it more unpredictable by expanding on the stock market event
system a bit further. Naturally, it could use a few more wacky events to
keep the system fresh and active, but for now this helps to keep the
system from being a screen simulator while also making game-health
changes like lowering material quantities that were capable of allowing
the player to double, quadruple, octuple, etc. their wealth every few
minutes by just buying low and selling high.

Makes a few QOL changes to the UI to compensate for a few of these
changes, like the new update timer on the UI in the case we change the
time per update any further, as well as to give incentive to players to
not just camp the console for new updates, just to glance at how their
investments are doing.

These tweaks also keep cargo moving as opposed to just trying to power
game iron and glass for maximum returns, while giving them extra
opportunities to send the shuttle to keep packages flowing for other
purchases/getting mail.

This has a chance to stop #79978, but I'll edit this appropriately after
a TM has confirmed if it was effective or not.

## Changelog

🆑
balance: The stock market now fires slower, has stock market events
occur more often, and the stock market has fewer minerals that are
available to buy in a single purchase before restocking.
balance: Materials sold on the stock market may be protected from being
bought if their prices drop too low, so make sure you watch your prices
before they run the risk of getting shut out!
balance: Stock blocks now freeze the price of materials for 3 minutes,
down from 5.
qol: Tweaks to the Galactic Material Market UI, with materials sorted
based on their rarity and a timer to show how long until it updates.
add: New Stock market events, one locks a material from being purchased,
the other maximizes the value and quantity of a material for sale.
/🆑

---------

Co-authored-by: MrMelbert <51863163+MrMelbert@users.noreply.github.com>
Co-authored-by: Ghom <42542238+Ghommie@users.noreply.github.com>
2024-03-06 23:54:37 +00:00
..