diff --git a/code/__HELPERS/unsorted.dm b/code/__HELPERS/unsorted.dm index d054734611..73b2dd3006 100644 --- a/code/__HELPERS/unsorted.dm +++ b/code/__HELPERS/unsorted.dm @@ -173,10 +173,10 @@ Turf and target are separate in case you want to teleport some distance from a t var/banned = jobban_isbanned(src, "appearance") - if(C?.prefs?.custom_names[role] && !banned) - newname = C.prefs.custom_names[role] - else - while(loop && safety < 5) + while(loop && safety < 5) + if(C && C.prefs.custom_names[role] && !safety && !banned) + newname = C.prefs.custom_names[role] + else switch(role) if("human") newname = random_unique_name(gender)