stock_market
Vars | |
active_events | A list of all currently active stock market events. |
---|---|
materials_prices | Associated list of materials and their prices at the given time. |
materials_quantity | Associated list of materials alongside their available quantity. This is used to determine how much of a material is available to buy, and how much buying and selling affects the price. |
materials_trend_life | Associated list of materials alongside the life of its current trend. After its life is up, it will change to a new trend. |
materials_trends | Associated list of materials alongside their market trends. 1 is up, 0 is stable, -1 is down. |
news_string | HTML string that is used to display the market events to the player. |
Procs | |
adjust_material_price | Adjust the price of a material(either through buying or selling) ensuring it stays within limits |
adjust_material_quantity | Adjust the amount of material(either through buying or selling) ensuring it stays within limits |
handle_market_event | Market events are a way to spice up the market and make it more interesting. Randomly one will occur to a random material, and it will change the price of that material more drastically, or reset it to a stable price. Events are also broadcast to the newscaster as a fun little fluff piece. Good way to tell some lore as well, or just make a joke. |
handle_trends_and_price | Handles shifts in the cost of materials, and in what direction the material is most likely to move. |
Var Details
active_events
A list of all currently active stock market events.
materials_prices
Associated list of materials and their prices at the given time.
materials_quantity
Associated list of materials alongside their available quantity. This is used to determine how much of a material is available to buy, and how much buying and selling affects the price.
materials_trend_life
Associated list of materials alongside the life of its current trend. After its life is up, it will change to a new trend.
materials_trends
Associated list of materials alongside their market trends. 1 is up, 0 is stable, -1 is down.
news_string
HTML string that is used to display the market events to the player.
Proc Details
adjust_material_price
Adjust the price of a material(either through buying or selling) ensuring it stays within limits
adjust_material_quantity
Adjust the amount of material(either through buying or selling) ensuring it stays within limits
handle_market_event
Market events are a way to spice up the market and make it more interesting. Randomly one will occur to a random material, and it will change the price of that material more drastically, or reset it to a stable price. Events are also broadcast to the newscaster as a fun little fluff piece. Good way to tell some lore as well, or just make a joke.
handle_trends_and_price
Handles shifts in the cost of materials, and in what direction the material is most likely to move.