[EE] Adds Market Crash Event (#31870)

* Adds Market Crash Event

* Typo

* Bees

Co-authored-by: JimKil3 <47290811+JimKil3@users.noreply.github.com>
Signed-off-by: PollardTheDragon <144391971+PollardTheDragon@users.noreply.github.com>

---------

Signed-off-by: PollardTheDragon <144391971+PollardTheDragon@users.noreply.github.com>
Co-authored-by: JimKil3 <47290811+JimKil3@users.noreply.github.com>
This commit is contained in:
PollardTheDragon
2026-05-07 01:02:49 -04:00
committed by GitHub
parent 0495f43b53
commit 85002cca6c
5 changed files with 44 additions and 3 deletions
+1
View File
@@ -198,6 +198,7 @@ GLOBAL_LIST_EMPTY(event_last_fired)
new /datum/event_meta(EVENT_LEVEL_MODERATE, /datum/event/tourist_arrivals, 40, TRUE, _first_run_time = 35 MINUTES),
new /datum/event_meta(EVENT_LEVEL_MODERATE, /datum/event/shuttle_loan, 50, is_one_shot = TRUE),
new /datum/event_meta(EVENT_LEVEL_MODERATE, /datum/event/anomalous_particulate_event, 60, is_one_shot = TRUE),
new /datum/event_meta(EVENT_LEVEL_MODERATE, /datum/event/market_crash, 20),
new /datum/event_meta(EVENT_LEVEL_MODERATE, /datum/event/cargo_pods, 50),
new /datum/event_meta(EVENT_LEVEL_MODERATE, /datum/event/spawn_floor_cluwne, 3),
)
+1 -1
View File
@@ -23,7 +23,7 @@
/datum/event/tear,
/datum/event/tear/honk,
/datum/event/traders,
/datum/event/vent_clog,
/datum/event/market_crash,
/datum/event/disease_outbreak,
/datum/event/vent_clog,
/datum/event/disposals_clog,
+39
View File
@@ -0,0 +1,39 @@
/datum/event/market_crash
name = "Market Crash"
nominal_severity = EVENT_LEVEL_MODERATE
endWhen = 300
/// Vendor price multiplier
var/price_mult = 3
/datum/event/market_crash/announce(false_alarm)
var/list/possible_reasons = list(
"supply chain shortages",
"[syndicate_name()] operatives attacking a shipment",
"space wizard interference",
"bluespace traffic",
"gravitational anomalies",
"extended trade routes",
"market speculation",
"vox",
"a clown college graduation party",
"a Trans-Solar Federation investigation",
"too many credits being invested in WetSkrell.nt",
"an overabundance of bees",
)
GLOB.minor_announcement.Announce("Due to [pick(possible_reasons)], prices for on-station vendors will be increased for a short period. We apologize for the inconvenience.", "Central Command Finance Division")
/datum/event/market_crash/start()
for(var/obj/machinery/economy/vending/vendor in SSmachines.get_by_type(/obj/machinery/economy/vending))
if(!is_station_level(vendor.z))
continue
vendor.build_inventory(vendor.products, vendor.product_records, FALSE, price_mult)
vendor.build_inventory(vendor.contraband, vendor.hidden_records, FALSE, price_mult)
addtimer(CALLBACK(src, PROC_REF(reset_prices)), rand(5 MINUTES, 10 MINUTES))
/datum/event/market_crash/proc/reset_prices()
for(var/obj/machinery/economy/vending/vendor in SSmachines.get_by_type(/obj/machinery/economy/vending))
if(!is_station_level(vendor.z))
continue
vendor.build_inventory(vendor.products, vendor.product_records, FALSE, 1)
vendor.build_inventory(vendor.contraband, vendor.hidden_records, FALSE, 1)