Misc. runtime fixes (#4545)

## About The Pull Request
No player-facing changes

This fixes a runtime in donator status code by making it return if there
is no prefs.parent
This fixes a runtime in emote code by making the code check if the user
is living so the variable isn't undefined
This fixes a runtime in Skyrat MODsuit code by making the code check if
there isn't a wearer

## Why It's Good For The Game
I fix

## Proof Of Testing

<details>
<summary>Screenshots/Videos</summary>

</details>

## Changelog

🆑 ReturnToZender
/🆑
This commit is contained in:
Return
2025-08-26 09:04:21 -06:00
committed by GitHub
parent ff40f9cb09
commit 2e5b7bc30a
3 changed files with 7 additions and 7 deletions
@@ -7,22 +7,22 @@
return
update_external_organs_modsuit_status(is_sealed && active)
wearer.update_body_parts(TRUE)
wearer?.update_body_parts(TRUE)
/obj/item/mod/control/control_activation(is_on)
. = ..()
update_external_organs_modsuit_status(is_on)
wearer.update_body_parts(TRUE)
wearer?.update_body_parts(TRUE)
/obj/item/mod/control/deploy(mob/user, obj/item/part, instant = FALSE)
. = ..()
update_external_organs_modsuit_status(active)
wearer.update_body_parts(TRUE)
wearer?.update_body_parts(TRUE)
/obj/item/mod/control/retract(mob/user, obj/item/part, instant = FALSE)
. = ..()
update_external_organs_modsuit_status(FALSE)
wearer.update_body_parts(TRUE)
wearer?.update_body_parts(TRUE)
/// Simple helper proc to force an update of the external organs appearance
/// if necessary.
+2 -2
View File
@@ -258,7 +258,7 @@
'modular_skyrat/modules/emotes/sound/emotes/clap4.ogg')
/datum/emote/living/clap/can_run_emote(mob/living/carbon/user, status_check = TRUE , intentional)
if(user.usable_hands < 2)
if(!istype(user) || user.usable_hands < 2)
return FALSE
return ..()
@@ -276,7 +276,7 @@
'modular_zubbers/sound/emotes/claponce2.ogg')
/datum/emote/living/clap1/can_run_emote(mob/living/carbon/user, status_check = TRUE , intentional)
if(user.usable_hands < 2)
if(!istype(user) || user.usable_hands < 2)
return FALSE
return ..()
@@ -118,7 +118,7 @@ SUBSYSTEM_DEF(player_ranks)
* * prefs - The preferences datum to check the donator_status eligibility.
*/
/datum/controller/subsystem/player_ranks/proc/update_prefs_donator_status(datum/preferences/prefs)
if(!prefs)
if(!prefs || !prefs.parent)
return
prefs.unlock_content = !!prefs.parent.IsByondMember()