mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-08-24 13:38:41 +01:00
You will no longer die of motion sickness from gibtonite on icebox (#88608)
## About The Pull Request - if an explosion epicenter is not on a station area, then it will not screen shake all mobs on the z level if it was really far ## Why It's Good For The Game - why should a bomb from 100 tiles away screenshake the entire z level? - players have brought up their annoyance with icebox gitbtonite shaking the entire z level every time one explodes. ## Changelog 🆑 grungussuss del: screenshake from explosions will no longer happen when it's really far and not on a station area (turf) /🆑
This commit is contained in:
@@ -524,6 +524,7 @@ ADMIN_VERB(check_bomb_impacts, R_DEBUG, "Check Bomb Impact", "See what the effec
|
||||
/datum/controller/subsystem/explosions/proc/shake_the_room(turf/epicenter, near_distance, far_distance, quake_factor, echo_factor, creaking, sound/near_sound = sound(get_sfx(SFX_EXPLOSION)), sound/far_sound = sound('sound/effects/explosion/explosionfar.ogg'), sound/echo_sound = sound('sound/effects/explosion/explosion_distant.ogg'), sound/creaking_sound = sound(get_sfx(SFX_EXPLOSION_CREAKING)), hull_creaking_sound = sound(get_sfx(SFX_HULL_CREAKING)))
|
||||
var/frequency = get_rand_frequency()
|
||||
var/blast_z = epicenter.z
|
||||
var/area/epicenter_area = get_area(epicenter)
|
||||
if(isnull(creaking)) // Autoset creaking.
|
||||
var/on_station = SSmapping.level_trait(epicenter.z, ZTRAIT_STATION)
|
||||
if(on_station && prob((quake_factor * QUAKE_CREAK_PROB) + (echo_factor * ECHO_CREAK_PROB))) // Huge explosions are near guaranteed to make the station creak and whine, smaller ones might.
|
||||
@@ -559,7 +560,7 @@ ADMIN_VERB(check_bomb_impacts, R_DEBUG, "Check Bomb Impact", "See what the effec
|
||||
base_shake_amount = max(base_shake_amount, quake_factor * 3, 0) // Devastating explosions rock the station and ground
|
||||
shake_camera(listener, FAR_SHAKE_DURATION, min(base_shake_amount, FAR_SHAKE_CAP))
|
||||
|
||||
else if(!isspaceturf(listener_turf) && echo_factor) // Big enough explosions echo through the hull.
|
||||
else if(!isspaceturf(listener_turf) && !(!(epicenter_area.type in GLOB.the_station_areas) && SSmapping.is_planetary()) && echo_factor) // Big enough explosions echo through the hull. Except on planetary maps if the epicenter is not on the station's area.
|
||||
var/echo_volume
|
||||
if(quake_factor)
|
||||
echo_volume = 60
|
||||
|
||||
Reference in New Issue
Block a user