mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-08-28 07:38:05 +01:00
[MIRROR] Adds the New-and-Improved Training Machine, Training Toolbox! (#1345)
* Adds the New-and-Improved Training Machine, Training Toolbox! (#54133) Co-authored-by: Jared-Fogle <35135081+Jared-Fogle@ users.noreply.github.com> Co-authored-by: ATH1909 <42606352+ATH1909@ users.noreply.github.com> Co-authored-by: Rohesie <rohesie@ gmail.com> * Adds the New-and-Improved Training Machine, Training Toolbox! Co-authored-by: Emmanuel S <mrdoomboyo@gmail.com> Co-authored-by: Jared-Fogle <35135081+Jared-Fogle@ users.noreply.github.com> Co-authored-by: ATH1909 <42606352+ATH1909@ users.noreply.github.com> Co-authored-by: Rohesie <rohesie@ gmail.com>
This commit is contained in:
co-authored by
Jared-Fogle
ATH1909
Rohesie
Emmanuel S
parent
b13fdd5ae4
commit
717c31d40c
@@ -1,46 +0,0 @@
|
||||
/datum/component/magnetic_catch/Initialize()
|
||||
if(!isatom(parent))
|
||||
return COMPONENT_INCOMPATIBLE
|
||||
RegisterSignal(parent, COMSIG_PARENT_EXAMINE, .proc/examine)
|
||||
if(ismovable(parent))
|
||||
RegisterSignal(parent, COMSIG_MOVABLE_CROSSED, .proc/crossed_react)
|
||||
RegisterSignal(parent, COMSIG_MOVABLE_UNCROSSED, .proc/uncrossed_react)
|
||||
for(var/i in get_turf(parent))
|
||||
if(i == parent)
|
||||
continue
|
||||
RegisterSignal(i, COMSIG_MOVABLE_PRE_THROW, .proc/throw_react)
|
||||
else
|
||||
RegisterSignal(parent, COMSIG_ATOM_ENTERED, .proc/entered_react)
|
||||
RegisterSignal(parent, COMSIG_ATOM_EXITED, .proc/exited_react)
|
||||
for(var/i in parent)
|
||||
RegisterSignal(i, COMSIG_MOVABLE_PRE_THROW, .proc/throw_react)
|
||||
|
||||
/datum/component/magnetic_catch/proc/examine(datum/source, mob/user, list/examine_list)
|
||||
SIGNAL_HANDLER
|
||||
|
||||
examine_list += "It has been installed with inertia dampening to prevent coffee spills."
|
||||
|
||||
/datum/component/magnetic_catch/proc/crossed_react(datum/source, atom/movable/thing)
|
||||
SIGNAL_HANDLER
|
||||
|
||||
RegisterSignal(thing, COMSIG_MOVABLE_PRE_THROW, .proc/throw_react, TRUE)
|
||||
|
||||
/datum/component/magnetic_catch/proc/uncrossed_react(datum/source, atom/movable/thing)
|
||||
SIGNAL_HANDLER
|
||||
|
||||
UnregisterSignal(thing, COMSIG_MOVABLE_PRE_THROW)
|
||||
|
||||
/datum/component/magnetic_catch/proc/entered_react(datum/source, atom/movable/thing, atom/oldloc)
|
||||
SIGNAL_HANDLER
|
||||
|
||||
RegisterSignal(thing, COMSIG_MOVABLE_PRE_THROW, .proc/throw_react, TRUE)
|
||||
|
||||
/datum/component/magnetic_catch/proc/exited_react(datum/source, atom/movable/thing, atom/newloc)
|
||||
SIGNAL_HANDLER
|
||||
|
||||
UnregisterSignal(thing, COMSIG_MOVABLE_PRE_THROW)
|
||||
|
||||
/datum/component/magnetic_catch/proc/throw_react(datum/source, list/arguments)
|
||||
SIGNAL_HANDLER
|
||||
|
||||
return COMPONENT_CANCEL_THROW
|
||||
Reference in New Issue
Block a user