From ae270c6938e1023d3b975fbb8d68e12eef1313f3 Mon Sep 17 00:00:00 2001 From: Leshana Date: Wed, 24 May 2017 16:48:31 -0400 Subject: [PATCH] Adjusts random events to be more suitable for the Tether Fixes #1542 Fixes #1396 * Disables the Supply Demand event until it can be reworked to be more interesting. * Removes volatile fuel from the possible gases leaked in Atmos Leak event. * Excludes areas around spawn points from the Atmos Leak event. * Prevents gravity failure from disabling gravity on planetary z levels. --- code/modules/events/atmos_leak.dm | 4 ++-- code/modules/events/event_container_vr.dm | 10 +++++----- code/modules/events/gravity.dm | 10 ++++++++-- maps/tether/tether_areas2.dm | 12 ++++++++++++ 4 files changed, 27 insertions(+), 9 deletions(-) diff --git a/code/modules/events/atmos_leak.dm b/code/modules/events/atmos_leak.dm index 46c28b7adfe..0b9da559c93 100644 --- a/code/modules/events/atmos_leak.dm +++ b/code/modules/events/atmos_leak.dm @@ -22,8 +22,8 @@ var/gas_choices = list("carbon_dioxide", "sleeping_agent") // Annoying if(severity >= EVENT_LEVEL_MODERATE) gas_choices += "phoron" // Dangerous - if(severity >= EVENT_LEVEL_MAJOR) - gas_choices += "volatile_fuel" // Dangerous and no default atmos setup! + // if(severity >= EVENT_LEVEL_MAJOR) + // gas_choices += "volatile_fuel" // Dangerous and no default atmos setup! gas_type = pick(gas_choices) // Assemble areas that all exists (See DM reference if you are confused about loop labels) diff --git a/code/modules/events/event_container_vr.dm b/code/modules/events/event_container_vr.dm index c2103246a46..1381a28417b 100644 --- a/code/modules/events/event_container_vr.dm +++ b/code/modules/events/event_container_vr.dm @@ -41,7 +41,6 @@ new /datum/event_meta(EVENT_LEVEL_MUNDANE, "Mundane News", /datum/event/mundane_news, 300), new /datum/event_meta(EVENT_LEVEL_MUNDANE, "PDA Spam", /datum/event/pda_spam, 0, list(ASSIGNMENT_ANY = 4), 1, 25, 50), new /datum/event_meta(EVENT_LEVEL_MUNDANE, "Shipping Error", /datum/event/shipping_error , 30, list(ASSIGNMENT_ANY = 2), 0), - new /datum/event_meta(EVENT_LEVEL_MUNDANE, "Supply Demand", /datum/event/supply_demand, 0, list(ASSIGNMENT_ANY = 5, ASSIGNMENT_SCIENCE = 15, ASSIGNMENT_GARDENER = 10, ASSIGNMENT_ENGINEER = 10, ASSIGNMENT_MEDICAL = 15), 1), new /datum/event_meta(EVENT_LEVEL_MUNDANE, "Trivial News", /datum/event/trivial_news, 400), // Spawns mice, lizards, or dud spiderlings new /datum/event_meta(EVENT_LEVEL_MUNDANE, "Vermin Infestation",/datum/event/infestation, 100, list(ASSIGNMENT_JANITOR = 100), 1), @@ -51,13 +50,14 @@ add_disabled_events(list( new /datum/event_meta(EVENT_LEVEL_MUNDANE, "Lost Carp", /datum/event/carp_migration, 20, list(ASSIGNMENT_SECURITY = 10), 1), new /datum/event_meta(EVENT_LEVEL_MUNDANE, "Money Hacker", /datum/event/money_hacker, 0, list(ASSIGNMENT_ANY = 4), 1, 10, 25), + new /datum/event_meta(EVENT_LEVEL_MUNDANE, "Supply Demand", /datum/event/supply_demand, 0, list(ASSIGNMENT_ANY = 5, ASSIGNMENT_SCIENCE = 15, ASSIGNMENT_GARDENER = 10, ASSIGNMENT_ENGINEER = 10, ASSIGNMENT_MEDICAL = 15), 1), )) /datum/event_container/moderate/New() available_events = list( new /datum/event_meta(EVENT_LEVEL_MODERATE, "Nothing", /datum/event/nothing, 800), // Leaks gas into an unoccupied room. - new /datum/event_meta(EVENT_LEVEL_MODERATE, "Atmos Leak", /datum/event/atmos_leak, 30, list(ASSIGNMENT_ENGINEER = 50), 1), + new /datum/event_meta(EVENT_LEVEL_MODERATE, "Atmos Leak", /datum/event/atmos_leak, 30, list(ASSIGNMENT_ENGINEER = 25), 1), // Just disables comms for a short while. new /datum/event_meta(EVENT_LEVEL_MODERATE, "Communication Blackout", /datum/event/communications_blackout, 500, list(ASSIGNMENT_AI = 150, ASSIGNMENT_SECURITY = 120), 1), // Just blows out a few lights @@ -74,7 +74,6 @@ new /datum/event_meta(EVENT_LEVEL_MODERATE, "Solar Storm", /datum/event/solar_storm, 30, list(ASSIGNMENT_ENGINEER = 40, ASSIGNMENT_SECURITY = 30), 1), new /datum/event_meta(EVENT_LEVEL_MODERATE, "Virology Breach", /datum/event/prison_break/virology, 0, list(ASSIGNMENT_MEDICAL = 100), 1), new /datum/event_meta(EVENT_LEVEL_MODERATE, "Xenobiology Breach", /datum/event/prison_break/xenobiology, 0, list(ASSIGNMENT_SCIENCE = 100), 1), - new /datum/event_meta(EVENT_LEVEL_MODERATE, "Supply Demand", /datum/event/supply_demand, 0, list(ASSIGNMENT_ANY = 5, ASSIGNMENT_SCIENCE = 15, ASSIGNMENT_GARDENER = 10, ASSIGNMENT_ENGINEER = 10, ASSIGNMENT_MEDICAL = 15), 1), ) add_disabled_events(list( new /datum/event_meta(EVENT_LEVEL_MODERATE, "Appendicitis", /datum/event/spontaneous_appendicitis, 0, list(ASSIGNMENT_MEDICAL = 30), 1), @@ -86,13 +85,13 @@ new /datum/event_meta(EVENT_LEVEL_MODERATE, "Rogue Drones", /datum/event/rogue_drone, 20, list(ASSIGNMENT_SECURITY = 60)), new /datum/event_meta(EVENT_LEVEL_MODERATE, "Space Dust", /datum/event/dust, 80, list(ASSIGNMENT_ENGINEER = 30)), new /datum/event_meta(EVENT_LEVEL_MODERATE, "Spider Infestation", /datum/event/spider_infestation, 100, list(ASSIGNMENT_SECURITY = 40), 1), + new /datum/event_meta(EVENT_LEVEL_MODERATE, "Supply Demand", /datum/event/supply_demand, 0, list(ASSIGNMENT_ANY = 5, ASSIGNMENT_SCIENCE = 15, ASSIGNMENT_GARDENER = 10, ASSIGNMENT_ENGINEER = 10, ASSIGNMENT_MEDICAL = 15), 1), )) /datum/event_container/major/New() available_events = list( new /datum/event_meta(EVENT_LEVEL_MAJOR, "Nothing", /datum/event/nothing, 900), - new /datum/event_meta(EVENT_LEVEL_MAJOR, "Atmos Leak", /datum/event/atmos_leak, 30, list(ASSIGNMENT_ENGINEER = 50), 1), - new /datum/event_meta(EVENT_LEVEL_MAJOR, "Supply Demand", /datum/event/supply_demand, 0, list(ASSIGNMENT_ANY = 5, ASSIGNMENT_SCIENCE = 15, ASSIGNMENT_GARDENER = 10, ASSIGNMENT_ENGINEER = 10, ASSIGNMENT_MEDICAL = 15), 1), + new /datum/event_meta(EVENT_LEVEL_MAJOR, "Atmos Leak", /datum/event/atmos_leak, 30, list(ASSIGNMENT_ENGINEER = 25), 1), ) add_disabled_events(list( new /datum/event_meta(EVENT_LEVEL_MAJOR, "Blob", /datum/event/blob, 10, list(ASSIGNMENT_ENGINEER = 60), 1), @@ -100,6 +99,7 @@ new /datum/event_meta(EVENT_LEVEL_MAJOR, "Containment Breach", /datum/event/prison_break/station,0,list(ASSIGNMENT_ANY = 5)), new /datum/event_meta(EVENT_LEVEL_MAJOR, "Meteor Wave", /datum/event/meteor_wave, 30, list(ASSIGNMENT_ENGINEER = 30), 1), new /datum/event_meta(EVENT_LEVEL_MAJOR, "Space Vines", /datum/event/spacevine, 20, list(ASSIGNMENT_ENGINEER = 15), 1), + new /datum/event_meta(EVENT_LEVEL_MAJOR, "Supply Demand", /datum/event/supply_demand, 0, list(ASSIGNMENT_ANY = 5, ASSIGNMENT_SCIENCE = 15, ASSIGNMENT_GARDENER = 10, ASSIGNMENT_ENGINEER = 10, ASSIGNMENT_MEDICAL = 15), 1), )) #undef ASSIGNMENT_ANY diff --git a/code/modules/events/gravity.dm b/code/modules/events/gravity.dm index 0719c9bba19..f5fc8f0b5a5 100644 --- a/code/modules/events/gravity.dm +++ b/code/modules/events/gravity.dm @@ -1,8 +1,14 @@ /datum/event/gravity announceWhen = 5 + var/list/zLevels /datum/event/gravity/setup() endWhen = rand(15, 60) + // Setup which levels we will disrupt gravit on. + zLevels = using_map.station_levels.Copy() + if (planet_controller) + for(var/datum/planet/P in planet_controller.planets) + zLevels -= P.expected_z_levels /datum/event/gravity/announce() command_announcement.Announce("Feedback surge detected in mass-distributions systems. Artificial gravity has been disabled whilst the system \ @@ -11,7 +17,7 @@ /datum/event/gravity/start() gravity_is_on = 0 for(var/area/A in world) - if(A.z in using_map.station_levels) + if(A.z in zLevels) A.gravitychange(gravity_is_on, A) /datum/event/gravity/end() @@ -19,7 +25,7 @@ gravity_is_on = 1 for(var/area/A in world) - if(A.z in using_map.station_levels) + if(A.z in zLevels) A.gravitychange(gravity_is_on, A) command_announcement.Announce("Gravity generators are again functioning within normal parameters. Sorry for any inconvenience.", "Gravity Restored") diff --git a/maps/tether/tether_areas2.dm b/maps/tether/tether_areas2.dm index a25afb08a7c..682eecf2d87 100644 --- a/maps/tether/tether_areas2.dm +++ b/maps/tether/tether_areas2.dm @@ -405,3 +405,15 @@ name = "\improper Syndicate LC - Mining" icon_state = "shuttle2" base_turf = /turf/simulated/floor/outdoors/dirt/virgo3b + + + +// Exclude some more areas from the atmos leak event so people don't get trapped when spawning. +/datum/event/atmos_leak/setup() + excluded |= /area/tether/surfacebase/tram + excluded |= /area/tether/surfacebase/atrium_one + excluded |= /area/tether/surfacebase/atrium_two + excluded |= /area/tether/surfacebase/atrium_three + excluded |= /area/teleporter/departing + excluded |= /area/hallway/station/upper + ..()