diff --git a/code/game/machinery/telecomms/machine_interactions.dm b/code/game/machinery/telecomms/machine_interactions.dm index 778de2a2f3e..9420f1051e0 100644 --- a/code/game/machinery/telecomms/machine_interactions.dm +++ b/code/game/machinery/telecomms/machine_interactions.dm @@ -12,17 +12,28 @@ interact(user, attacking_item) return TRUE - // REPAIRING: Use Nanopaste to repair half of the system's integrity. At 24 machines, it will take 48 uses of nanopaste to repair the entire array. + // REPAIRING: Use Nanopaste to repair 25pts of system integrity. + // This used to be half integrity, but changed by Bat to be simpler after comms blackouts started causing emp damage. if(istype(attacking_item, /obj/item/stack/nanopaste)) var/obj/item/stack/nanopaste/T = attacking_item - if (integrity < 100) //Damaged, let's repair! - if (T.use(1)) - integrity = between(0, initial(integrity) / 2, initial(integrity)) + // Damaged, let's repair! + if(integrity < 100) + if(T.use(1)) + integrity = between(0, integrity + 25, initial(integrity)) to_chat(user, "You apply the Nanopaste to [src], repairing some of the damage.") else to_chat(user, "This machine is already in perfect condition.") return TRUE + // Beat it with a stick! + if(!istype(user, /mob/living/silicon)) + if(user.a_intent == I_HURT) + user.visible_message(SPAN_DANGER("\The [user] strikes [src]!")) + user.do_attack_animation(user, attacking_item) + playsound(loc, hitsound, 60, TRUE) + user.setClickCooldown(DEFAULT_ATTACK_COOLDOWN) + integrity = between(0, integrity - round(attacking_item.force / 3), initial(integrity)) + return TRUE switch(construct_op) if(0) diff --git a/code/game/machinery/telecomms/machines/processor.dm b/code/game/machinery/telecomms/machines/processor.dm index 52d8900a864..6e293296d05 100644 --- a/code/game/machinery/telecomms/machines/processor.dm +++ b/code/game/machinery/telecomms/machines/processor.dm @@ -13,6 +13,7 @@ name = "processor unit" icon_state = "processor" desc = "This machine is used to process large quantities of information." + desc_antag = "Attacking this machine will cause communications over its linked frequency(s) to become increasingly garbled." telecomms_type = /obj/machinery/telecomms/processor delay = 5 circuitboard = "/obj/item/circuitboard/telecomms/processor" diff --git a/code/game/machinery/telecomms/telecommunications.dm b/code/game/machinery/telecomms/telecommunications.dm index e976ea2849c..cca8def0654 100644 --- a/code/game/machinery/telecomms/telecommunications.dm +++ b/code/game/machinery/telecomms/telecommunications.dm @@ -19,6 +19,7 @@ /obj/machinery/telecomms icon = 'icons/obj/machinery/telecomms.dmi' + desc_info = "All telecomms machinery can repaired through the application of Nanopaste." density = TRUE anchored = TRUE idle_power_usage = 600 // WATTS @@ -45,6 +46,8 @@ var/circuitboard = null // string pointing to a circuitboard type var/hide = FALSE // Is it a hidden machine? + var/hitsound = 'sound/weapons/smash.ogg' + // Overmap ranges in terms of map tile distance, used by receivers, relays, and broadcasters (and AIOs) var/overmap_range = 0 @@ -148,7 +151,7 @@ addtimer(CALLBACK(src, PROC_REF(post_emp_act)), (300 SECONDS) / severity) /obj/machinery/telecomms/proc/emp_damage() - integrity = between(0, integrity - (rand(5,30)), 100) + integrity = between(0, integrity - (rand(5,15)), 100) /obj/machinery/telecomms/proc/post_emp_act() stat &= ~EMPED @@ -264,3 +267,19 @@ if (overmap_dist > overmap_range) return -1 return overmap_dist + +/obj/machinery/telecomms/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) + . = ..() + if(integrity < initial(integrity)) + var/state + var/current_damage = integrity / initial(integrity) + switch(current_damage) + if(0 to 0.2) + state = SPAN_DANGER("The machine is on its last legs!") + if(0.2 to 0.4) + state = SPAN_WARNING("The machine looks seriously damaged.") + if(0.4 to 0.8) + state = SPAN_WARNING("The machine's condition appears somewhat degraded.") + if(0.8 to 1) + state = SPAN_NOTICE("The machine shows some indications of minor damage.") + . += state diff --git a/code/modules/events/apc_damage.dm b/code/modules/events/apc_damage.dm index a9d5cc2977a..628d3dc2619 100644 --- a/code/modules/events/apc_damage.dm +++ b/code/modules/events/apc_damage.dm @@ -10,18 +10,20 @@ switch(severity) if(EVENT_LEVEL_MAJOR) - victim_apc.overload_lighting(50, TRUE) + victim_apc.overload_lighting(100, TRUE) victim_apc.set_broken() if(!QDELETED(victim_apc.cell)) victim_apc.cell.corrupt() if(EVENT_LEVEL_MODERATE) + victim_apc.overload_lighting(85, TRUE) victim_apc.set_broken() if(!QDELETED(victim_apc.cell)) victim_apc.cell.corrupt() //EVENT_LEVEL_MUNDANE and if someone fucked up the config else + victim_apc.overload_lighting(60, TRUE) victim_apc.emagged = TRUE victim_apc.flicker_all() diff --git a/code/modules/events/electrical_storm.dm b/code/modules/events/electrical_storm.dm index 81a682663fa..c55ddfbf028 100644 --- a/code/modules/events/electrical_storm.dm +++ b/code/modules/events/electrical_storm.dm @@ -34,7 +34,7 @@ for(var/obj/machinery/power/apc/valid_apc in SSmachinery.apc_units) if((valid_apc.z in affecting_z) && !valid_apc.is_critical) valid_apcs += valid_apc - endWhen = (severity * 60) + startWhen + endWhen = (severity * 45) + startWhen /datum/event/electrical_storm/end(faked) ..() @@ -60,17 +60,22 @@ var/list/picked_apcs = list() // Up to 2/4/6 APCs per tick depending on severity + for(var/i = 0, i < ((severity + 1)), i++) for(var/i = 0, i < (severity * 2), i++) picked_apcs |= pick(valid_apcs) for(var/obj/machinery/power/apc/victim_apc in picked_apcs) // Determine what each APC does. Depending on how bad they roll, might be nothing or might blow out the entire thing. // Mundane storm: 0-55 nothing, 56+ lights flicker, 86+ damage (2 APC at a time) - // Moderate storm: 0-30 nothing, 31+ lights flicker, 81+ damage (4 APCs at a time) - // Severe storm: 0-5 nothing, 6+ lights flicker, 76+ damage (6 APCs at a time) + // Moderate storm: 0-30 nothing, 31+ lights flicker, 81+ damage (3 APCs at a time) + // Severe storm: 0-5 nothing, 6+ lights flicker, 76+ damage (4 APCs at a time) // Once storm damage exceeds a threshold, there is a random chance of certain secondary effects. storm_damage = rand(0,100) + // We don't want to obliterate small offships (lucky 7 APCs or fewer). + if(LAZYLEN(valid_apcs) < 8) + LAZYREMOVE(victim_apc, valid_apcs) + // Main breaker is turned off, or we rolled lucky. Consider this APC protected. if(!victim_apc.operating || storm_damage <= (80 - (severity * 25))) continue diff --git a/code/modules/events/event_container.dm b/code/modules/events/event_container.dm index 09f81fd233a..9baa9ca3539 100644 --- a/code/modules/events/event_container.dm +++ b/code/modules/events/event_container.dm @@ -213,7 +213,7 @@ GLOBAL_LIST_INIT(severity_to_string, list(EVENT_LEVEL_MUNDANE = "Mundane", EVENT 120), new /datum/event_meta(EVENT_LEVEL_MUNDANE, "APC Damage", /datum/event/apc_damage, - 10, list(ASSIGNMENT_ENGINEER = 15)), + 10, list(ASSIGNMENT_ENGINEER = 15, ASSIGNMENT_JANITOR = 20)), new /datum/event_meta(EVENT_LEVEL_MUNDANE, "Brand Intelligence", /datum/event/brand_intelligence, 0, list(ASSIGNMENT_ENGINEER = 5), TRUE), @@ -225,7 +225,7 @@ GLOBAL_LIST_INIT(severity_to_string, list(EVENT_LEVEL_MUNDANE = "Mundane", EVENT 300), new /datum/event_meta(EVENT_LEVEL_MUNDANE, "Electrical Storm", /datum/event/electrical_storm, - 50, list(ASSIGNMENT_ENGINEER = 20, ASSIGNMENT_JANITOR = 25)), + 30, list(ASSIGNMENT_ENGINEER = 20, ASSIGNMENT_JANITOR = 25)), new /datum/event_meta(EVENT_LEVEL_MUNDANE, "Cozmozoan Migration", /datum/event/carp_migration/cozmo, 60), @@ -287,14 +287,18 @@ GLOBAL_LIST_INIT(severity_to_string, list(EVENT_LEVEL_MUNDANE = "Mundane", EVENT 0, list(ASSIGNMENT_SURGEON = 25)), new /datum/event_meta(EVENT_LEVEL_MODERATE, "Comms Blackout", /datum/event/communications_blackout, - 100), + 50), + + new /datum/event_meta(EVENT_LEVEL_MODERATE, "Comms Blackout - Damage", /datum/event/communications_blackout/damage_machinery, + 50, list(ASSIGNMENT_ENGINEER = 25), + pop_needed = 6), new /datum/event_meta(EVENT_LEVEL_MODERATE, "Comms Blackout - Damage", /datum/event/communications_blackout/damage_machinery, 100, list(ASSIGNMENT_ENGINEER = 25), pop_needed = 6), new /datum/event_meta(EVENT_LEVEL_MODERATE, "Electrical Storm", /datum/event/electrical_storm, - 40, list(ASSIGNMENT_AI = 10, ASSIGNMENT_ENGINEER = 15, ASSIGNMENT_JANITOR = 20)), + 30, list(ASSIGNMENT_AI = 10, ASSIGNMENT_ENGINEER = 15, ASSIGNMENT_JANITOR = 20)), // see comment at code/modules/events/gravity.dm // tl;dr gravity is handled globally, meaning if the horizon loses gravity, everyone does @@ -333,7 +337,7 @@ GLOBAL_LIST_INIT(severity_to_string, list(EVENT_LEVEL_MUNDANE = "Mundane", EVENT 25, list(ASSIGNMENT_ENGINEER = 30)), new /datum/event_meta(EVENT_LEVEL_MODERATE, "APC Damage", /datum/event/apc_damage, - 20, list(ASSIGNMENT_ENGINEER = 15)), + 20, list(ASSIGNMENT_ENGINEER = 15, ASSIGNMENT_JANITOR = 20)), ) @@ -378,11 +382,11 @@ GLOBAL_LIST_INIT(severity_to_string, list(EVENT_LEVEL_MUNDANE = "Mundane", EVENT pop_needed = 4), new /datum/event_meta(EVENT_LEVEL_MAJOR, "Comet Expulsion", /datum/event/comet_expulsion, - 1, list(ASSIGNMENT_BRIDGE_CREW = 5, ASSIGNMENT_ENGINEER = 2), is_one_shot = TRUE, + 1, list(ASSIGNMENT_BRIDGE_CREW = 15, ASSIGNMENT_ENGINEER = 12), is_one_shot = TRUE, pop_needed = 8), new /datum/event_meta(EVENT_LEVEL_MAJOR, "APC Damage", /datum/event/apc_damage, - 20, list(ASSIGNMENT_ENGINEER = 15)), + 20, list(ASSIGNMENT_ENGINEER = 15, ASSIGNMENT_JANITOR = 20)), ) diff --git a/code/modules/power/apc.dm b/code/modules/power/apc.dm index af11c60772a..742275e6285 100644 --- a/code/modules/power/apc.dm +++ b/code/modules/power/apc.dm @@ -341,7 +341,7 @@ ABSTRACT_TYPE(/obj/machinery/power/apc) else icon_state = basestate else if(update_state & UPDATE_OPENED2) - icon_state = "[basestate]-nocover" + icon_state = "apcmaint" //needs missing "[basestate]-nocover" icon restored else if(update_state & UPDATE_BROKE) icon_state = "apc-b" else if(update_state & UPDATE_BLUESCREEN) @@ -941,6 +941,7 @@ ABSTRACT_TYPE(/obj/machinery/power/apc) area.power_equip = (equipment > 1) area.power_environ = (environ > 1) else + GLOB.power_alarm.triggerAlarm(loc, src) area.power_light = FALSE area.power_equip = FALSE area.power_environ = FALSE diff --git a/html/changelogs/Batrachophreno-EventTuning.yml b/html/changelogs/Batrachophreno-EventTuning.yml new file mode 100644 index 00000000000..68e150c7ba4 --- /dev/null +++ b/html/changelogs/Batrachophreno-EventTuning.yml @@ -0,0 +1,71 @@ +################################ +# Example Changelog File +# +# Note: This file, and files beginning with ".", and files that don't end in ".yml" will not be read. If you change this file, you will look really dumb. +# +# Your changelog will be merged with a master changelog. (New stuff added only, and only on the date entry for the day it was merged.) +# When it is, any changes listed below will disappear. +# +# Valid Prefixes: +# bugfix +# - (fixes bugs) +# wip +# - (work in progress) +# qol +# - (quality of life) +# soundadd +# - (adds a sound) +# sounddel +# - (removes a sound) +# rscadd +# - (adds a feature) +# rscdel +# - (removes a feature) +# imageadd +# - (adds an image or sprite) +# imagedel +# - (removes an image or sprite) +# spellcheck +# - (fixes spelling or grammar) +# experiment +# - (experimental change) +# balance +# - (balance changes) +# code_imp +# - (misc internal code change) +# refactor +# - (refactors code) +# config +# - (makes a change to the config files) +# admin +# - (makes changes to administrator tools) +# server +# - (miscellaneous changes to server) +################################# + +# Your name. +author: Batrachophreno + +# Optional: Remove this file after generating master changelog. Useful for PR changelogs that won't get used again. +delete-after: True + +# Any changes you've made. See valid prefix list above. +# INDENT WITH TWO SPACES. NOT TABS. SPACES. +# SCREW THIS UP AND IT WON'T WORK. +# Also, this gets changed to [] after reading. Just remove the brackets when you add new shit. +# Please surround your changes in double quotes ("). It works without them, but if you use certain characters it screws up compiling. The quotes will not show up in the changelog. +changes: + - qol: "Added additional description information for telecomms machines to communicate that they can be repaired using Nanopaste." + - qol: "Damaged telecomms machines now show their condition when examined." + - balance: "Added small Nanopaste supply to the telecomms vestibule for repair." + - balance: "Repairing telecomms machines now just repairs flat 25 damage (out of max 100) instead of repairing by halves (was behaving oddly in-game)." + - balance: "Made the damaging variant of Communications Blackout do less damage to soften the garbling effect." + - rscadd: "Beating up a telecomms processor will now cause integrity damage to it, which will result in garbled communications" + - qol: "Added antag desc text for the telecomms processor describing damage to it garbling communications." + - balance: "Comms Blackout events (base and damaging version) have had their weights halved, given the addition of the new variant greatly increased their overall likelihood." + - balance: "APC Damage event now much more frequently causes lights to blow out." + - balance: "Electrical Storm events have had their weights adjusted downwards slightly." + - balance: "Electrical Storm events have had their durations reduced slightly." + - balance: "Electrical Storm events now target fewer APCs at a time (2,4,6 -> 2,3,4)." + - balance: "Electrical Storm events no longer affect smaller offships." + - balance: "Cosmic Expulsion event now weigh Bridge Crew/Engineer presence slightly more heavily." \ No newline at end of file diff --git a/maps/sccv_horizon/sccv_horizon.dmm b/maps/sccv_horizon/sccv_horizon.dmm index 7d82c7536b8..b0ee02aacba 100644 --- a/maps/sccv_horizon/sccv_horizon.dmm +++ b/maps/sccv_horizon/sccv_horizon.dmm @@ -22644,6 +22644,7 @@ /obj/effect/floor_decal/spline/plain{ dir = 5 }, +/obj/item/stack/nanopaste, /turf/simulated/floor/carpet/rubber, /area/tcommsat/entrance) "dgc" = ( diff --git a/tools/Event Probabilities/Event Probabilities.xlsx b/tools/Event Probabilities/Event Probabilities.xlsx index 1be10c2b1ce..6cdc905621d 100644 Binary files a/tools/Event Probabilities/Event Probabilities.xlsx and b/tools/Event Probabilities/Event Probabilities.xlsx differ