mirror of
https://github.com/CHOMPStation2/CHOMPStation2.git
synced 2025-12-11 18:53:06 +00:00
Dry agent and dry galoshes (#7845)
This commit is contained in:
19
modular_chomp/code/datums/components/dry.dm
Normal file
19
modular_chomp/code/datums/components/dry.dm
Normal file
@@ -0,0 +1,19 @@
|
||||
/datum/component/dry
|
||||
var/turf/simulated/T
|
||||
var/obj/effect/decal/cleanable/blood/B
|
||||
|
||||
/datum/component/dry/Initialize()
|
||||
if(!isatom(parent))
|
||||
return COMPONENT_INCOMPATIBLE
|
||||
if(istype(parent, /obj/item/clothing/shoes))
|
||||
RegisterSignal(parent, COMSIG_SHOES_STEP_ACTION, PROC_REF(step_dry))
|
||||
|
||||
/datum/component/dry/proc/step_dry(obj/item/clothing/shoes/source)
|
||||
SIGNAL_HANDLER
|
||||
|
||||
T = get_turf(parent)
|
||||
B = locate(/obj/effect/decal/cleanable/blood) in T
|
||||
|
||||
T.wet_floor_finish()
|
||||
if(B)
|
||||
B.dry()
|
||||
Reference in New Issue
Block a user