mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-08-29 08:08:49 +01:00
[MIRROR] Tweaks some instances of get_safe_turf so things like the nuclear disk doesn't accidentally teleport to the Icebox Syndicate Base (#28184)
* Tweaks some instances of get_safe_turf so things like the nuclear disk doesn't accidentally teleport to the Icebox Syndicate Base (#83012) Yes, I know preventing the nuke disk teleporting to the icebox syndicate base (or possibly the wendigo arena) is removing soul. Please don't kill me :( ## About The Pull Request Adds some missing variables to instances of get_safe_turf() so they will only teleport to the given z-level. Replaces some instances of get_safe_turf() with get_safe_random_station_turf(). ## Why It's Good For The Game First, the differences between get_safe_turf() and get_safe_random_station_turf(): ### get_safe_turf() - gets a random safe turf on a z-level (usually any of the staiton z-levels), not accounting for the /area/ - should be used if you don't care if it spawns on the station or not, or if you need to specifically teleport to a z-level - not very expensive performance wise ### get_safe_random_station_turf() - gets a random safe turf that will always be a station area, ignoring z-level. - should be used if you NEED the turf to be on a station's area - slightly more expensive performance wise than get_safe_turf, but still very cheap Some code was using get_safe_turf() when it should've been using get_safe_random_station_turf(), and some code that should be using get_safe_turf() were incorrectly using the zlevels arg instead of zlevel arg (Yes, there is a difference), or didn't include it at all. All the changes were made to my best judgement. If you're curious about a change, please ask and I will explain why I did it. ## Changelog 🆑 BurgerBB fix: Tweaks some instances of get_safe_turf so things like the nuclear disk doesn't accidentally teleport to the Icebox Syndicate Base /🆑 --------- Co-authored-by: Jacquerel <hnevard@ gmail.com> * Tweaks some instances of get_safe_turf so things like the nuclear disk doesn't accidentally teleport to the Icebox Syndicate Base --------- Co-authored-by: BurgerLUA <8602857+BurgerLUA@users.noreply.github.com> Co-authored-by: Jacquerel <hnevard@ gmail.com>
This commit is contained in:
co-authored by
Jacquerel
BurgerLUA
parent
c1e7417d7b
commit
19e80c32c7
@@ -135,7 +135,7 @@
|
||||
|
||||
/obj/effect/fun_balloon/scatter/effect()
|
||||
for(var/mob/living/M in range(effect_range, get_turf(src)))
|
||||
var/turf/T = find_safe_turf()
|
||||
var/turf/T = find_safe_turf(zlevel = src.z)
|
||||
new /obj/effect/temp_visual/gravpush(get_turf(M))
|
||||
M.forceMove(T)
|
||||
to_chat(M, span_notice("Pop!"), confidential = TRUE)
|
||||
|
||||
Reference in New Issue
Block a user