Driving any vehicle into the supermatter will dust all passengers (#82137)

## About The Pull Request

Fixes #82135
All occupants of vehicles (including mobs you can ride) will now die if
anyone drives that vehicle into the supermatter crystal.

## Why It's Good For The Game

It may not be canonically true that driving the clown car into the
supermatter dusts all occupants but by god, it should be.
This is the result that you expect to occur upon doing such a thing.

## Changelog

🆑
fix: Driving a vehicle into the supermatter will kill everyone riding
the vehicle
/🆑

---------

Co-authored-by: san7890 <the@san7890.com>
This commit is contained in:
Jacquerel
2024-03-22 12:16:41 +00:00
committed by GitHub
parent a97903aa62
commit c95890c473
4 changed files with 30 additions and 4 deletions

View File

@@ -67,6 +67,7 @@
RegisterSignal(parent, COMSIG_BUCKLED_CAN_Z_MOVE, PROC_REF(riding_can_z_move))
RegisterSignals(parent, GLOB.movement_type_addtrait_signals, PROC_REF(on_movement_type_trait_gain))
RegisterSignals(parent, GLOB.movement_type_removetrait_signals, PROC_REF(on_movement_type_trait_loss))
RegisterSignal(parent, COMSIG_SUPERMATTER_CONSUMED, PROC_REF(on_entered_supermatter))
if(!can_force_unbuckle)
RegisterSignal(parent, COMSIG_ATOM_ATTACK_HAND, PROC_REF(force_unbuckle))
@@ -314,3 +315,9 @@
if((living_hitter in source.buckled_mobs))
return
return COMPONENT_CANCEL_ATTACK_CHAIN
/// When we touch a crystal, kill everything inside us
/datum/component/riding/proc/on_entered_supermatter(atom/movable/ridden, atom/movable/supermatter)
SIGNAL_HANDLER
for (var/mob/passenger as anything in ridden.buckled_mobs)
passenger.Bump(supermatter)