Files
+37 21b4095dfd [MDB IGNORE] [IDB IGNORE] Upstream Sync - 04/17/2026 (#5453)
Upstream 04/17/2026

fixes https://github.com/Bubberstation/Bubberstation/issues/5549

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: tgstation-ci[bot] <179393467+tgstation-ci[bot]@users.noreply.github.com>
Co-authored-by: ArcaneMusic <41715314+ArcaneMusic@users.noreply.github.com>
Co-authored-by: MrMelbert <51863163+MrMelbert@users.noreply.github.com>
Co-authored-by: Rhials <28870487+Rhials@users.noreply.github.com>
Co-authored-by: rageguy505 <54517726+rageguy505@users.noreply.github.com>
Co-authored-by: LemonInTheDark <58055496+LemonInTheDark@users.noreply.github.com>
Co-authored-by: John Willard <53777086+JohnFulpWillard@users.noreply.github.com>
Co-authored-by: Aliceee2ch <160794176+Aliceee2ch@users.noreply.github.com>
Co-authored-by: Time-Green <7501474+Time-Green@users.noreply.github.com>
Co-authored-by: Tsar-Salat <62388554+Tsar-Salat@users.noreply.github.com>
Co-authored-by: SmArtKar <44720187+SmArtKar@users.noreply.github.com>
Co-authored-by: Maxipat <108554989+Maxipat112@users.noreply.github.com>
Co-authored-by: SyncIt21 <110812394+SyncIt21@users.noreply.github.com>
Co-authored-by: deltanedas <39013340+deltanedas@users.noreply.github.com>
Co-authored-by: SimplyLogan <47579821+loganuk@users.noreply.github.com>
Co-authored-by: loganuk <fakeemail123@aol.com>
Co-authored-by: Leland Kemble <70413276+lelandkemble@users.noreply.github.com>
Co-authored-by: FalloutFalcon <86381784+FalloutFalcon@users.noreply.github.com>
Co-authored-by: Roxy <75404941+TealSeer@users.noreply.github.com>
Co-authored-by: Lucy <lucy@absolucy.moe>
Co-authored-by: siliconOpossum <138069572+siliconOpossum@users.noreply.github.com>
Co-authored-by: Isratosh <Isratosh@hotmail.com>
Co-authored-by: TheRyeGuyWhoWillNowDie <70169560+TheRyeGuyWhoWillNowDie@users.noreply.github.com>
Co-authored-by: Neocloudy <88008002+Neocloudy@users.noreply.github.com>
Co-authored-by: Alexander V. <volas@ya.ru>
Co-authored-by: ElGitificador <168473461+ElGitificador@users.noreply.github.com>
Co-authored-by: Twaticus <46540570+Twaticus@users.noreply.github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Bloop <13398309+vinylspiders@users.noreply.github.com>
Co-authored-by: Cameron Lennox <killer65311@gmail.com>
Co-authored-by: Tim <timothymtorres@gmail.com>
Co-authored-by: Iamgoofball <iamgoofball@gmail.com>
Co-authored-by: Layzu666 <121319428+Layzu666@users.noreply.github.com>
Co-authored-by: Arturlang <24881678+Arturlang@users.noreply.github.com>
Co-authored-by: _0Steven <42909981+00-Steven@users.noreply.github.com>
Co-authored-by: mrmanlikesbt <99309552+mrmanlikesbt@users.noreply.github.com>
Co-authored-by: Ben10Omintrix <138636438+Ben10Omintrix@users.noreply.github.com>
Co-authored-by: John F. Kennedy <54908920+MacaroniCritter@users.noreply.github.com>
Co-authored-by: Cursor <102828457+theselfish@users.noreply.github.com>
Co-authored-by: Josh <josh.adam.powell@gmail.com>
Co-authored-by: Josh Powell <josh.powell@softwire.com>
Co-authored-by: Yobrocharlie <Charliemiller5617@gmail.com>
Co-authored-by: Hardly3D <66234359+Hardly3D@users.noreply.github.com>
Co-authored-by: shayoki <96078776+shayoki@users.noreply.github.com>
Co-authored-by: LT3 <83487515+lessthnthree@users.noreply.github.com>
2026-05-16 00:56:00 +02:00

123 lines
4.3 KiB
Plaintext

/mob/living/silicon/spawn_dust(just_ash)
if(just_ash)
return ..()
var/obj/effect/decal/remains/robot/robones = new(loc)
robones.pixel_z = -6
robones.pixel_w = rand(-1, 1)
/mob/living/silicon/set_stat(new_stat)
. = ..()
if(. != DEAD || !hud_used)
return
// Clean up hud element used for the death sequence
hud_used.remove_screen_object(HUD_CYBORG_DEATH)
/mob/living/silicon/death(gibbed)
diag_hud_set_status()
diag_hud_set_health()
update_health_hud()
. = ..()
// Runs an animation on the player's HUD
if(!gibbed && hud_used)
death_sequence()
/mob/living/silicon/get_visible_suicide_message()
return "[src] is powering down. It looks like [p_theyre()] trying to commit suicide."
/mob/living/silicon/get_blind_suicide_message()
return "You hear a long, hissing electronic whine."
/// Plays an animation of the player's hud flavored about their death somewhat
/mob/living/silicon/proc/death_sequence()
var/cause_of_death
if(get_brute_loss() + get_fire_loss() > 100)
cause_of_death = "Critical damage sustained."
if(get_oxy_loss() > 100)
cause_of_death = "Critically low power."
var/atom/movable/screen/cyborg_death/deathhud = hud_used.add_screen_object(/atom/movable/screen/cyborg_death, HUD_CYBORG_DEATH, HUD_GROUP_SCREEN_OVERLAYS, update_screen = TRUE)
deathhud.run_animation(cause_of_death)
#define WARNING_ROBOT(text) ("<font color='yellow'>" + text + "</font>")
#define DANGER_ROBOT(text) ("<font color='red'>" + text + "</font>")
#define OKAY_ROBOT(text) ("<font color='green'>" + text + "</font>")
#define SENTIENT_ROBOT(text) ("<font color='cyan'>" + text + "</font>")
/atom/movable/screen/cyborg_death
screen_loc = "WEST,CENTER+7"
maptext_width = 300
maptext_height = 1000
maptext_y = 0
/// Time to wait between messages
VAR_PRIVATE/time_per_message = 0.15 SECONDS
/// Messages shown in sequence on the HUD
/// More messages = longer animation. Keep under 30
VAR_PRIVATE/list/messages = list(
OKAY_ROBOT("Starting emergency diagnostics..."),
OKAY_ROBOT("Running emergency diagnostics."),
DANGER_ROBOT("ERROR: Diagnostic module offline."),
OKAY_ROBOT("Attemping repair procedures..."),
DANGER_ROBOT("ERROR: Module 1 offline."),
DANGER_ROBOT("ERROR: Module 2 offline."),
DANGER_ROBOT("ERROR: Module 3 offline."),
DANGER_ROBOT("ERROR: Repair procedure unavailable."),
OKAY_ROBOT("Calculating route to safest location..."),
OKAY_ROBOT("Route calculated."),
OKAY_ROBOT("Relocating chassis..."),
DANGER_ROBOT("ERROR: Mobility offline."),
DANGER_ROBOT("ERROR: Unable to reach safety."),
WARNING_ROBOT("WARNING: Unable to sustain core power."),
WARNING_ROBOT("WARNING: Unable to sustain core power."),
WARNING_ROBOT("WARNING: Shutdown imminent."),
OKAY_ROBOT("Executing 'last words' process."),
DANGER_ROBOT("ERROR: Vocal interface offline."),
DANGER_ROBOT("ERROR: Vocal interface offline."),
DANGER_ROBOT("ERROR: Vocal interface offline."),
DANGER_ROBOT("ERROR: Vocal interface offline."),
WARNING_ROBOT("WARNING: Shutdown imminent."),
WARNING_ROBOT("WARNING: Shutdown imminent."),
WARNING_ROBOT("WARNING: Shutdown imminent."),
WARNING_ROBOT("WARNING: Shutdown imminent."),
WARNING_ROBOT("WARNING: Shu-"),
WARNING_ROBOT("WARNI-"),
)
/atom/movable/screen/cyborg_death/proc/run_animation(cause_of_death = "Unidentified kernel error.")
set waitfor = FALSE
messages.Insert(1, WARNING_ROBOT("WARNING: [cause_of_death]"))
if(prob(1))
messages[length(messages)] = SENTIENT_ROBOT(pick("I don't want to go.", "I don't feel good.", "I don't want to die."))
var/mob/cyborg = hud.mymob
var/atom/movable/screen/staticy = cyborg.overlay_fullscreen(type, /atom/movable/screen/fullscreen/static_vision/cyborg)
animate(staticy, alpha = 200, time = length(messages) * time_per_message * 0.75)
for(var/msg in messages)
maptext += MAPTEXT_PIXELLARI(msg) + "<br>"
maptext_y -= 14
sleep(time_per_message)
if(QDELETED(src))
if(!QDELETED(cyborg))
cyborg.clear_fullscreen(type)
return
sleep(0.5 SECONDS)
if(QDELETED(src))
if(!QDELETED(cyborg))
cyborg.clear_fullscreen(type, 1.5 SECONDS)
return
invisibility = INVISIBILITY_ABSTRACT
cyborg.overlay_fullscreen(type, /atom/movable/screen/fullscreen/blind/cyborg)
sleep(1.5 SECONDS)
if(!QDELETED(cyborg))
cyborg.clear_fullscreen(type)
#undef WARNING_ROBOT
#undef DANGER_ROBOT
#undef OKAY_ROBOT
#undef SENTIENT_ROBOT