From bd43381d5580ef32b8f5cc88bb659b3204612228 Mon Sep 17 00:00:00 2001 From: Matt Atlas Date: Sun, 2 Jul 2023 12:17:40 +0200 Subject: [PATCH] Fix one of the server killing bugs (#16580) * debug the server dying * a * adad * wtf * a --------- Co-authored-by: Matt Atlas --- code/modules/organs/organ_external.dm | 10 +++---- html/changelogs/mattatlas-yosobi.yml | 41 +++++++++++++++++++++++++++ 2 files changed, 46 insertions(+), 5 deletions(-) create mode 100644 html/changelogs/mattatlas-yosobi.yml diff --git a/code/modules/organs/organ_external.dm b/code/modules/organs/organ_external.dm index 1c5d29f5a07..0fc4102eac7 100644 --- a/code/modules/organs/organ_external.dm +++ b/code/modules/organs/organ_external.dm @@ -969,8 +969,8 @@ Note that amputating the affected organ does in fact remove the infection from t src.transform = M if(!clean) //Throw limb around. - if(src && istype(loc,/turf)) - INVOKE_ASYNC(src, TYPE_PROC_REF(/atom/movable, throw_at), get_edge_target_turf(src,pick(alldirs)), rand(1,3), 30) + if(src && isturf(loc)) + INVOKE_ASYNC(src, TYPE_PROC_REF(/atom/movable, throw_at), get_edge_target_turf(src,pick(alldirs)), rand(1,3), 4) dir = 2 if(DROPLIMB_BURN) new /obj/effect/decal/cleanable/ash(get_turf(victim)) @@ -985,12 +985,12 @@ Note that amputating the affected organ does in fact remove the infection from t if(victim.species.blood_color) gore.basecolor = victim.species.blood_color gore.update_icon() - INVOKE_ASYNC(gore, TYPE_PROC_REF(/atom/movable, throw_at), get_edge_target_turf(src, pick(alldirs)), rand(1,3), 30) + INVOKE_ASYNC(gore, TYPE_PROC_REF(/atom/movable, throw_at), get_edge_target_turf(src, pick(alldirs)), rand(1,3), 4) for(var/obj/item/organ/I in internal_organs) I.removed() if(istype(loc,/turf)) - INVOKE_ASYNC(I, TYPE_PROC_REF(/atom/movable, throw_at), get_edge_target_turf(src, pick(alldirs)), rand(1,3), 30) + INVOKE_ASYNC(I, TYPE_PROC_REF(/atom/movable, throw_at), get_edge_target_turf(src, pick(alldirs)), rand(1,3), 4) var/turf/Tloc = get_turf(src) for(var/obj/item/I in src) @@ -998,7 +998,7 @@ Note that amputating the affected organ does in fact remove the infection from t qdel(I) continue I.forceMove(Tloc) - INVOKE_ASYNC(I, TYPE_PROC_REF(/atom/movable, throw_at), get_edge_target_turf(src, pick(alldirs)), rand(1,3), 30) + INVOKE_ASYNC(I, TYPE_PROC_REF(/atom/movable, throw_at), get_edge_target_turf(src, pick(alldirs)), rand(1,3), 4) qdel(src) diff --git a/html/changelogs/mattatlas-yosobi.yml b/html/changelogs/mattatlas-yosobi.yml new file mode 100644 index 00000000000..7a6bec9c745 --- /dev/null +++ b/html/changelogs/mattatlas-yosobi.yml @@ -0,0 +1,41 @@ +################################ +# 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 +# wip (For works in progress) +# tweak +# soundadd +# sounddel +# rscadd (general adding of nice things) +# rscdel (general deleting of nice things) +# imageadd +# imagedel +# maptweak +# spellcheck (typo fixes) +# experiment +# balance +# admin +# backend +# security +# refactor +################################# + +# Your name. +author: MattAtlas + +# 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, all entries are changed into a single [] after a master changelog generation. Just remove the brackets when you add new entries. +# Please surround your changes in double quotes ("), as certain characters otherwise screws up compiling. The quotes will not show up in the changelog. +changes: + - bugfix: "Fixed a potential server killing bug."