mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-08-29 16:18:01 +01:00
[READY] playsound performance (#40045)
tl;dr: we have lists of playermobs on the z-level, which generally have fewer player mobs to iterate through. If we use them, we can get rid of the z-level checks too. On the off-chance that something plays a sound in nullspace, we can skip pretty much everything. The client-check can go too, there are no playermobs without a client.
This commit is contained in:
committed by
oranges
parent
3585ff1560
commit
f2ed477232
@@ -12,5 +12,9 @@
|
||||
preferred_form = client.prefs.ghost_form
|
||||
ghost_orbit = client.prefs.ghost_orbit
|
||||
|
||||
var/turf/T = get_turf(src)
|
||||
if (isturf(T))
|
||||
update_z(T.z)
|
||||
|
||||
update_icon(preferred_form)
|
||||
updateghostimages()
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
/mob/dead/observer/Logout()
|
||||
update_z(null)
|
||||
if (client)
|
||||
client.images -= (GLOB.ghost_images_default+GLOB.ghost_images_simple)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user