From 5fc2e0c5e4cb034925f4d65d06049943fbb20455 Mon Sep 17 00:00:00 2001 From: Zonespace <41448081+Zonespace27@users.noreply.github.com> Date: Fri, 17 Nov 2023 13:44:06 -0800 Subject: [PATCH] Fix null parent crash in radial slice clicked() function --- code/_onclick/hud/radial.dm | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/code/_onclick/hud/radial.dm b/code/_onclick/hud/radial.dm index cfc6c4d034fb..4a23ebd882d3 100644 --- a/code/_onclick/hud/radial.dm +++ b/code/_onclick/hud/radial.dm @@ -34,6 +34,12 @@ GLOBAL_LIST_EMPTY(radial_menus) /atom/movable/screen/radial/slice/clicked(mob/user) + if(QDELETED(src)) + return + + if(!parent) + CRASH("clicked() called on a radial slice with a null parent while not deleted/deleting") + if(user.client == parent.current_user) if(next_page) parent.next_page()