Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
30 commits
Select commit Hold shift + click to select a range
1af00d9
WIP
Jul 28, 2026
4ef3f32
WIP
Jul 29, 2026
30e125d
feature complete (aside form reflection/merging, potentially)
Jul 31, 2026
3c178fe
unused vars
Jul 31, 2026
6f4c207
c&d fix
Aug 1, 2026
c205118
implement compounding falloff properly (to be tested in more detail)
Aug 1, 2026
4ff9421
fix falloff calc and only apply resistance after explosive effects, t…
Aug 1, 2026
3e0760a
WIP - remove cellauto
Aug 1, 2026
97f7738
add logging and kill cellauto for good
Aug 1, 2026
44a9d39
remove leftovers
Aug 1, 2026
ad57a9c
visual adjustments
Aug 1, 2026
3de717e
fix init error message
Aug 1, 2026
200ae6c
Bump up Explosions scheduling due to issues with hijack crash
Aug 1, 2026
8cf790c
divide explosion ring duration by 2
Aug 1, 2026
9663753
defer everything during hijack crash
Aug 2, 2026
94d317b
Made explosion effects more tame
Aug 2, 2026
7430ec2
fix missing passing environemental damage parameter
Aug 2, 2026
62c8eba
fix not eating the wave on origin turf
Aug 2, 2026
deb4a4d
fix explosion ring sprite not disappearing
Aug 2, 2026
53d0150
less dirt, faster but less sparks, runtime fix
Aug 2, 2026
0db9d59
Add synchronizing with ending of current explosions ; allows hijack c…
Aug 2, 2026
40b2b57
fix runtime with particles
Aug 2, 2026
11b0e86
unused var fix
Aug 2, 2026
bb0bf96
change explo propagation function to more accurately follow blockers
Aug 4, 2026
e135ffd
alpha = intensity
Aug 4, 2026
3f8f787
wait = 2
Aug 4, 2026
530aca9
fix propagation (again)
Aug 5, 2026
96c1d88
wait = 1
Aug 7, 2026
c18a412
spiral explosion, resistance on entering turf, refactor epicenter, re…
Aug 9, 2026
e7bd8a7
fix SHARP mine not exploding
Aug 9, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions code/__DEFINES/dcs/signals/signals_subsystem.dm
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,9 @@
// All signals send the source datum of the signal as the first argument

///Subsystem signals

/// Fired by SSexplosion_waves when reaching a synchronization checkpoint
#define COMSIG_SS_EXPLOSION_WAVES_CHECKPOINT_REACHED "ss_explosion_waves_checkpoint_reached"

///From base of datum/controller/subsystem/Initialize
#define COMSIG_SUBSYSTEM_POST_INITIALIZE "subsystem_post_initialize"
3 changes: 2 additions & 1 deletion code/__DEFINES/subsystems.dm
Original file line number Diff line number Diff line change
Expand Up @@ -165,15 +165,16 @@
#define SS_PRIORITY_TIMER 700
#define SS_PRIORITY_AUTOFIRE 450
#define SS_PRIORITY_SOUND 250
#define SS_PRIORITY_EXPLOSION_WAVES 240
#define SS_PRIORITY_TICKER 200
#define SS_PRIORITY_NIGHTMARE 180
#define SS_PRIORITY_CHAT 155
#define SS_PRIORITY_STATPANEL 154
#define SS_PRIORITY_CELLAUTO 152
#define SS_PRIORITY_PROJECTILES 151
#define SS_PRIORITY_MOB 150
#define SS_PRIORITY_XENO 149
#define SS_PRIORITY_HUMAN 148
#define SS_PRIORITY_DELAYED_EX_ACT 140
#define SS_PRIORITY_STAMINA 126
#define SS_PRIORITY_COMPONENT 125
#define SS_PRIORITY_NANOUI 120
Expand Down
2 changes: 2 additions & 0 deletions code/__DEFINES/turf_flags.dm
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@
#define TURF_BURNT (1<<6)
#define TURF_BREAKABLE (1<<7)
#define TURF_BROKEN (1<<8)
/// Turf is primarily comprised of water, such as a river or ocean turf
#define TURF_IS_WATER (1<<9)

//ChangeTurf options to change its behavior
#define CHANGETURF_DEFER_CHANGE (1<<0)
Expand Down
29 changes: 0 additions & 29 deletions code/controllers/subsystem/cellauto.dm

This file was deleted.

32 changes: 32 additions & 0 deletions code/controllers/subsystem/delayed_ex_act.dm
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
/// Handles ex_act calls to expensive things like mobs as defered actions to preserve game under high load
SUBSYSTEM_DEF(delayed_ex_act)
name = "Delayed Explosion Effects"
priority = SS_PRIORITY_DELAYED_EX_ACT // High prio but not SS_TICKER and shouldn't be used much
wait = 0.5 DECISECONDS
flags = SS_NO_INIT
runlevels = RUNLEVELS_DEFAULT | RUNLEVEL_LOBBY

var/list/list/queued_work = list()
var/list/list/current_work

/datum/controller/subsystem/delayed_ex_act/fire(resumed = FALSE)
if(!resumed)
current_work = queued_work.Copy()
queued_work = list()

while(length(current_work))
var/list/order = current_work[current_work.len]
current_work.len--
var/atom/target = order[1]
if(!QDELETED(target)) // Very neccessary here
var/list/arguments = order.Copy(2, 0)
if(isliving(target) && length(arguments) >= 3)
var/datum/cause_data/cause_data = arguments[3]
log_explosion(target, cause_data)
target.ex_act(arglist(arguments))

if(MC_TICK_CHECK)
return

/datum/controller/subsystem/delayed_ex_act/proc/queue(atom/target, power, dir, datum/cause_data/cause_data, pierce = FALSE, enviro = FALSE)
queued_work += list(list(target, power, dir, cause_data, pierce, enviro))
55 changes: 55 additions & 0 deletions code/controllers/subsystem/explosion_waves.dm
Original file line number Diff line number Diff line change
@@ -0,0 +1,55 @@
SUBSYSTEM_DEF(explosion_waves)
name = "Explosion Waves"
wait = 1
flags = SS_TICKER | SS_NO_INIT
priority = SS_PRIORITY_EXPLOSION_WAVES

var/list/datum/explosion_wave/queued = list()
var/list/datum/explosion_wave/currentrun

/// List of synchronization checkpoints. An arbitrary tag, followed by the explosion_wave-s that existed at that time
/// When all of these waves are gone, we fire a signal to let listeners know we've progressed past that state
var/alist/checkpoints = alist()

/datum/controller/subsystem/explosion_waves/fire(resumed = FALSE)
if(!resumed)
currentrun = queued.Copy()

while(length(currentrun))
var/datum/explosion_wave/current = currentrun[currentrun.len]
currentrun.len--
var/ret = current?.process(wait * world.tick_lag)
if(ret == PROCESS_KILL)
queued -= current
if(MC_TICK_CHECK)
return

for(var/name, checkpoint in checkpoints)
if(!length(checkpoint & queued))
checkpoints -= name
SEND_GLOBAL_SIGNAL(COMSIG_SS_EXPLOSION_WAVES_CHECKPOINT_REACHED, name)

/datum/controller/subsystem/explosion_waves/proc/queue(datum/explosion_wave/item)
queued += item

/datum/controller/subsystem/explosion_waves/proc/forget(datum/explosion_wave/item)
queued -= item
currentrun -= item

for(var/name, contents in checkpoints)
var/list/datum/explosion_wave/checkpoint_waves = contents
checkpoint_waves -= item

/datum/controller/subsystem/explosion_waves/proc/set_checkpoint(name)
checkpoints[name] = queued.Copy()

/// Waits until reaching said checkpoint. DON'T USE THIS PLEASE USE THE SIGNALS ABOVE
/datum/controller/subsystem/explosion_waves/proc/synchronize(name)
if(isnull(name))
var/static/notch = 1
name = "_dynamic_checkpoint_[notch++]"
set_checkpoint(name)
else if(!(name in checkpoints))
return TRUE
UNTIL(!(name in checkpoints))
return TRUE
1 change: 0 additions & 1 deletion code/controllers/subsystem/ticker.dm
Original file line number Diff line number Diff line change
Expand Up @@ -496,7 +496,6 @@ SUBSYSTEM_DEF(ticker)
* SSsound: lowering SSsound freq probably won't help because it's just a worker for the sound queue, same amount of work gets queued anyway
* SSmob/SShuman/SSxeno: you don't want to touch these, because several systems down the line rely on the timing (2 SECONDS) for gameplay logic
* SSchat/SSinput: these are perf intensive but need to be SS_TICKER, changing wait would be troublesome and/or inconsequential for perf
* SScellauto: can't touch this because it would directly affect explosion spread speed
*/

SSlighting?.wait = 0.6 SECONDS // From 0.4, same but also heavily scales on player/scene density (higher = less frequent lighting updates which is very noticeable as you move)
Expand Down
8 changes: 4 additions & 4 deletions code/datums/ammo/shrapnel.dm
Original file line number Diff line number Diff line change
Expand Up @@ -149,11 +149,11 @@
icon_state = "shrapnel_glass"

/particles/shrapnel
icon = 'icons/obj/items/weapons/projectiles.dmi'
icon_state = "shrapnel_bright2"
icon = 'icons/effects/particles/generic_particles.dmi'
icon_state = "spark"
width = 1000
height = 1000
count = 100
count = 200
spawning = 0
lifespan = 0.6 SECONDS
fadein = 0.2 SECONDS
Expand All @@ -169,7 +169,7 @@
/obj/shrapnel_effect/New()
. = ..()
particles = new /particles/shrapnel
particles.spawning = rand(5,9) + rand(5,9)
particles.spawning = rand(50,80)
addtimer(CALLBACK(src, PROC_REF(stop)), 0.1 SECONDS)
QDEL_IN(src, 0.9 SECONDS)

Expand Down
128 changes: 0 additions & 128 deletions code/datums/autocells/auto_cell.dm

This file was deleted.

Loading