mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-08-28 15:47:15 +01:00
[MIRROR] Parse_zone audit + minor misc cleanup (#27735)
* Parse_zone audit + minor misc cleanup (#83154) ## About The Pull Request Does a audit on all uses of parse_zone, replacing most instances of it with a new living-level proc that refers to the bodypart in that zone if it exists. In other cases, removes parse_zone entirely because the bodypart is already confirmed to exist, so we just use plaintext_zone. Also cleans up some single letter vars. ## Why It's Good For The Game In the doc of ```plaintext_zone```, its said it ```Should be used for parsing non-instantiated bodyparts```. 99% of the code ignores the possibility of a bodypart existing, and so uses parse_zone when plaintext_zone could be accessed instead. ## Changelog 🆑 code: Most instances of parse_zone now refer to the limb's plaintext_zone var /🆑 --------- Co-authored-by: Ghom <42542238+Ghommie@ users.noreply.github.com> * Parse_zone audit + minor misc cleanup --------- Co-authored-by: nikothedude <59709059+nikothedude@users.noreply.github.com> Co-authored-by: Ghom <42542238+Ghommie@ users.noreply.github.com>
This commit is contained in:
co-authored by
Ghom
nikothedude
parent
bb0579051e
commit
1131ce10ba
@@ -345,7 +345,7 @@ MAPPING_DIRECTIONAL_HELPERS(/obj/structure/sink, (-14))
|
||||
if(busy)
|
||||
to_chat(user, span_warning("Someone's already washing here!"))
|
||||
return
|
||||
var/selected_area = parse_zone(user.zone_selected)
|
||||
var/selected_area = user.parse_zone_with_bodypart(user.zone_selected)
|
||||
var/washing_face = 0
|
||||
if(selected_area in list(BODY_ZONE_HEAD, BODY_ZONE_PRECISE_MOUTH, BODY_ZONE_PRECISE_EYES))
|
||||
washing_face = 1
|
||||
@@ -601,7 +601,7 @@ MAPPING_DIRECTIONAL_HELPERS(/obj/structure/sink/kitchen, (-16))
|
||||
if(busy)
|
||||
to_chat(user, span_warning("Someone's already washing here!"))
|
||||
return
|
||||
var/selected_area = parse_zone(user.zone_selected)
|
||||
var/selected_area = user.parse_zone_with_bodypart(user.zone_selected)
|
||||
var/washing_face = FALSE
|
||||
if(selected_area in list(BODY_ZONE_HEAD, BODY_ZONE_PRECISE_MOUTH, BODY_ZONE_PRECISE_EYES))
|
||||
washing_face = TRUE
|
||||
|
||||
Reference in New Issue
Block a user