Grep for space indentation (#54850)

#54604 atomizing
Since a lot of the space indents are in lists ill atomize those later
This commit is contained in:
TiviPlus
2020-11-30 18:48:40 +01:00
committed by GitHub
parent 84796e5372
commit 0eaab0bc54
468 changed files with 7623 additions and 7548 deletions
+153 -153
View File
@@ -1,14 +1,14 @@
/**
* # Component
*
* The component datum
*
* A component should be a single standalone unit
* of functionality, that works by receiving signals from it's parent
* object to provide some single functionality (i.e a slippery component)
* that makes the object it's attached to cause people to slip over.
* Useful when you want shared behaviour independent of type inheritance
*/
* # Component
*
* The component datum
*
* A component should be a single standalone unit
* of functionality, that works by receiving signals from it's parent
* object to provide some single functionality (i.e a slippery component)
* that makes the object it's attached to cause people to slip over.
* Useful when you want shared behaviour independent of type inheritance
*/
/datum/component
/**
* Defines how duplicate existing components are handled when added to a datum
@@ -39,13 +39,13 @@
var/can_transfer = FALSE
/**
* Create a new component.
*
* Additional arguments are passed to [Initialize()][/datum/component/proc/Initialize]
*
* Arguments:
* * datum/P the parent datum this component reacts to signals from
*/
* Create a new component.
*
* Additional arguments are passed to [Initialize()][/datum/component/proc/Initialize]
*
* Arguments:
* * datum/P the parent datum this component reacts to signals from
*/
/datum/component/New(list/raw_args)
parent = raw_args[1]
var/list/arguments = raw_args.Copy(2)
@@ -57,20 +57,20 @@
_JoinParent(parent)
/**
* Called during component creation with the same arguments as in new excluding parent.
*
* Do not call `qdel(src)` from this function, `return COMPONENT_INCOMPATIBLE` instead
*/
* Called during component creation with the same arguments as in new excluding parent.
*
* Do not call `qdel(src)` from this function, `return COMPONENT_INCOMPATIBLE` instead
*/
/datum/component/proc/Initialize(...)
return
/**
* Properly removes the component from `parent` and cleans up references
*
* Arguments:
* * force - makes it not check for and remove the component from the parent
* * silent - deletes the component without sending a [COMSIG_COMPONENT_REMOVING] signal
*/
* Properly removes the component from `parent` and cleans up references
*
* Arguments:
* * force - makes it not check for and remove the component from the parent
* * silent - deletes the component without sending a [COMSIG_COMPONENT_REMOVING] signal
*/
/datum/component/Destroy(force=FALSE, silent=FALSE)
if(!force && parent)
_RemoveFromParent()
@@ -80,8 +80,8 @@
return ..()
/**
* Internal proc to handle behaviour of components when joining a parent
*/
* Internal proc to handle behaviour of components when joining a parent
*/
/datum/component/proc/_JoinParent()
var/datum/P = parent
//lazy init the parent's dc list
@@ -118,8 +118,8 @@
RegisterWithParent()
/**
* Internal proc to handle behaviour when being removed from a parent
*/
* Internal proc to handle behaviour when being removed from a parent
*/
/datum/component/proc/_RemoveFromParent()
var/datum/P = parent
var/list/dc = P.datum_components
@@ -139,39 +139,39 @@
UnregisterFromParent()
/**
* Register the component with the parent object
*
* Use this proc to register with your parent object
*
* Overridable proc that's called when added to a new parent
*/
* Register the component with the parent object
*
* Use this proc to register with your parent object
*
* Overridable proc that's called when added to a new parent
*/
/datum/component/proc/RegisterWithParent()
return
/**
* Unregister from our parent object
*
* Use this proc to unregister from your parent object
*
* Overridable proc that's called when removed from a parent
* *
*/
* Unregister from our parent object
*
* Use this proc to unregister from your parent object
*
* Overridable proc that's called when removed from a parent
* *
*/
/datum/component/proc/UnregisterFromParent()
return
/**
* Register to listen for a signal from the passed in target
*
* This sets up a listening relationship such that when the target object emits a signal
* the source datum this proc is called upon, will receive a callback to the given proctype
* Return values from procs registered must be a bitfield
*
* Arguments:
* * datum/target The target to listen for signals from
* * sig_type_or_types Either a string signal name, or a list of signal names (strings)
* * proctype The proc to call back when the signal is emitted
* * override If a previous registration exists you must explicitly set this
*/
* Register to listen for a signal from the passed in target
*
* This sets up a listening relationship such that when the target object emits a signal
* the source datum this proc is called upon, will receive a callback to the given proctype
* Return values from procs registered must be a bitfield
*
* Arguments:
* * datum/target The target to listen for signals from
* * sig_type_or_types Either a string signal name, or a list of signal names (strings)
* * proctype The proc to call back when the signal is emitted
* * override If a previous registration exists you must explicitly set this
*/
/datum/proc/RegisterSignal(datum/target, sig_type_or_types, proctype, override = FALSE)
if(QDELETED(src) || QDELETED(target))
return
@@ -205,16 +205,16 @@
signal_enabled = TRUE
/**
* Stop listening to a given signal from target
*
* Breaks the relationship between target and source datum, removing the callback when the signal fires
*
* Doesn't care if a registration exists or not
*
* Arguments:
* * datum/target Datum to stop listening to signals from
* * sig_typeor_types Signal string key or list of signal keys to stop listening to specifically
*/
* Stop listening to a given signal from target
*
* Breaks the relationship between target and source datum, removing the callback when the signal fires
*
* Doesn't care if a registration exists or not
*
* Arguments:
* * datum/target Datum to stop listening to signals from
* * sig_typeor_types Signal string key or list of signal keys to stop listening to specifically
*/
/datum/proc/UnregisterSignal(datum/target, sig_type_or_types)
var/list/lookup = target.comp_lookup
if(!signal_procs || !signal_procs[target] || !lookup)
@@ -247,50 +247,50 @@
signal_procs -= target
/**
* Called on a component when a component of the same type was added to the same parent
*
* See [/datum/component/var/dupe_mode]
*
* `C`'s type will always be the same of the called component
*/
* Called on a component when a component of the same type was added to the same parent
*
* See [/datum/component/var/dupe_mode]
*
* `C`'s type will always be the same of the called component
*/
/datum/component/proc/InheritComponent(datum/component/C, i_am_original)
return
/**
* Called on a component when a component of the same type was added to the same parent with [COMPONENT_DUPE_SELECTIVE]
*
* See [/datum/component/var/dupe_mode]
*
* `C`'s type will always be the same of the called component
*
* return TRUE if you are absorbing the component, otherwise FALSE if you are fine having it exist as a duplicate component
*/
* Called on a component when a component of the same type was added to the same parent with [COMPONENT_DUPE_SELECTIVE]
*
* See [/datum/component/var/dupe_mode]
*
* `C`'s type will always be the same of the called component
*
* return TRUE if you are absorbing the component, otherwise FALSE if you are fine having it exist as a duplicate component
*/
/datum/component/proc/CheckDupeComponent(datum/component/C, ...)
return
/**
* Callback Just before this component is transferred
*
* Use this to do any special cleanup you might need to do before being deregged from an object
*/
* Callback Just before this component is transferred
*
* Use this to do any special cleanup you might need to do before being deregged from an object
*/
/datum/component/proc/PreTransfer()
return
/**
* Callback Just after a component is transferred
*
* Use this to do any special setup you need to do after being moved to a new object
*
* Do not call `qdel(src)` from this function, `return COMPONENT_INCOMPATIBLE` instead
*/
* Callback Just after a component is transferred
*
* Use this to do any special setup you need to do after being moved to a new object
*
* Do not call `qdel(src)` from this function, `return COMPONENT_INCOMPATIBLE` instead
*/
/datum/component/proc/PostTransfer()
return COMPONENT_INCOMPATIBLE //Do not support transfer by default as you must properly support it
/**
* Internal proc to create a list of our type and all parent types
*/
* Internal proc to create a list of our type and all parent types
*/
/datum/component/proc/_GetInverseTypeList(our_type = type)
//we can do this one simple trick
var/current_type = parent_type
@@ -301,12 +301,12 @@
. += current_type
/**
* Internal proc to handle most all of the signaling procedure
*
* Will runtime if used on datums with an empty component list
*
* Use the [SEND_SIGNAL] define instead
*/
* Internal proc to handle most all of the signaling procedure
*
* Will runtime if used on datums with an empty component list
*
* Use the [SEND_SIGNAL] define instead
*/
/datum/proc/_SendSignal(sigtype, list/arguments)
var/target = comp_lookup[sigtype]
if(!length(target))
@@ -325,13 +325,13 @@
// The type arg is casted so initial works, you shouldn't be passing a real instance into this
/**
* Return any component assigned to this datum of the given type
*
* This will throw an error if it's possible to have more than one component of that type on the parent
*
* Arguments:
* * datum/component/c_type The typepath of the component you want to get a reference to
*/
* Return any component assigned to this datum of the given type
*
* This will throw an error if it's possible to have more than one component of that type on the parent
*
* Arguments:
* * datum/component/c_type The typepath of the component you want to get a reference to
*/
/datum/proc/GetComponent(datum/component/c_type)
RETURN_TYPE(c_type)
if(initial(c_type.dupe_mode) == COMPONENT_DUPE_ALLOWED || initial(c_type.dupe_mode) == COMPONENT_DUPE_SELECTIVE)
@@ -345,13 +345,13 @@
// The type arg is casted so initial works, you shouldn't be passing a real instance into this
/**
* Return any component assigned to this datum of the exact given type
*
* This will throw an error if it's possible to have more than one component of that type on the parent
*
* Arguments:
* * datum/component/c_type The typepath of the component you want to get a reference to
*/
* Return any component assigned to this datum of the exact given type
*
* This will throw an error if it's possible to have more than one component of that type on the parent
*
* Arguments:
* * datum/component/c_type The typepath of the component you want to get a reference to
*/
/datum/proc/GetExactComponent(datum/component/c_type)
RETURN_TYPE(c_type)
if(initial(c_type.dupe_mode) == COMPONENT_DUPE_ALLOWED || initial(c_type.dupe_mode) == COMPONENT_DUPE_SELECTIVE)
@@ -368,11 +368,11 @@
return null
/**
* Get all components of a given type that are attached to this datum
*
* Arguments:
* * c_type The component type path
*/
* Get all components of a given type that are attached to this datum
*
* Arguments:
* * c_type The component type path
*/
/datum/proc/GetComponents(c_type)
var/list/dc = datum_components
if(!dc)
@@ -382,16 +382,16 @@
return list(.)
/**
* Creates an instance of `new_type` in the datum and attaches to it as parent
*
* Sends the [COMSIG_COMPONENT_ADDED] signal to the datum
*
* Returns the component that was created. Or the old component in a dupe situation where [COMPONENT_DUPE_UNIQUE] was set
*
* If this tries to add a component to an incompatible type, the component will be deleted and the result will be `null`. This is very unperformant, try not to do it
*
* Properly handles duplicate situations based on the `dupe_mode` var
*/
* Creates an instance of `new_type` in the datum and attaches to it as parent
*
* Sends the [COMSIG_COMPONENT_ADDED] signal to the datum
*
* Returns the component that was created. Or the old component in a dupe situation where [COMPONENT_DUPE_UNIQUE] was set
*
* If this tries to add a component to an incompatible type, the component will be deleted and the result will be `null`. This is very unperformant, try not to do it
*
* Properly handles duplicate situations based on the `dupe_mode` var
*/
/datum/proc/_AddComponent(list/raw_args)
var/new_type = raw_args[1]
var/datum/component/nt = new_type
@@ -459,22 +459,22 @@
return old_comp
/**
* Get existing component of type, or create it and return a reference to it
*
* Use this if the item needs to exist at the time of this call, but may not have been created before now
*
* Arguments:
* * component_type The typepath of the component to create or return
* * ... additional arguments to be passed when creating the component if it does not exist
*/
* Get existing component of type, or create it and return a reference to it
*
* Use this if the item needs to exist at the time of this call, but may not have been created before now
*
* Arguments:
* * component_type The typepath of the component to create or return
* * ... additional arguments to be passed when creating the component if it does not exist
*/
/datum/proc/LoadComponent(component_type, ...)
. = GetComponent(component_type)
if(!.)
return _AddComponent(args)
/**
* Removes the component from parent, ends up with a null parent
*/
* Removes the component from parent, ends up with a null parent
*/
/datum/component/proc/RemoveComponent()
if(!parent)
return
@@ -485,13 +485,13 @@
SEND_SIGNAL(old_parent, COMSIG_COMPONENT_REMOVING, src)
/**
* Transfer this component to another parent
*
* Component is taken from source datum
*
* Arguments:
* * datum/component/target Target datum to transfer to
*/
* Transfer this component to another parent
*
* Component is taken from source datum
*
* Arguments:
* * datum/component/target Target datum to transfer to
*/
/datum/proc/TakeComponent(datum/component/target)
if(!target || target.parent == src)
return
@@ -509,13 +509,13 @@
target._JoinParent()
/**
* Transfer all components to target
*
* All components from source datum are taken
*
* Arguments:
* * /datum/target the target to move the components to
*/
* Transfer all components to target
*
* All components from source datum are taken
*
* Arguments:
* * /datum/target the target to move the components to
*/
/datum/proc/TransferComponents(datum/target)
var/list/dc = datum_components
if(!dc)
@@ -531,7 +531,7 @@
target.TakeComponent(comps)
/**
* Return the object that is the host of any UI's that this component has
*/
* Return the object that is the host of any UI's that this component has
*/
/datum/component/ui_host()
return parent
+5 -5
View File
@@ -1,9 +1,9 @@
/** Component representing acid applied to an object.
*
* Must be attached to an atom.
* Processes, repeatedly damaging whatever it is attached to.
* If the parent atom is a turf it applies acid to the contents of the turf.
*/
*
* Must be attached to an atom.
* Processes, repeatedly damaging whatever it is attached to.
* If the parent atom is a turf it applies acid to the contents of the turf.
*/
/datum/component/acid
dupe_mode = COMPONENT_DUPE_UNIQUE_PASSARGS
/// The strength of the acid on the parent [/atom].
+7 -7
View File
@@ -1,11 +1,11 @@
/**
* Beauty component, makes the indoor area the parent is in prettier or uglier depending on the beauty var.
* Clean and well decorated areas lead to positive moodlets for passerbies, while shabbier, dirtier ones
* lead to negative moodlets exclusive to characters with the snob quirk.
*
* Keep in mind AddComponent is used for BOTH adding and removing beauty value here,
* so please don't use qdel/RemoveComponent unless necessary.
*/
* Beauty component, makes the indoor area the parent is in prettier or uglier depending on the beauty var.
* Clean and well decorated areas lead to positive moodlets for passerbies, while shabbier, dirtier ones
* lead to negative moodlets exclusive to characters with the snob quirk.
*
* Keep in mind AddComponent is used for BOTH adding and removing beauty value here,
* so please don't use qdel/RemoveComponent unless necessary.
*/
/datum/component/beauty
var/beauty = 0
dupe_mode = COMPONENT_DUPE_UNIQUE_PASSARGS
+34 -34
View File
@@ -1,7 +1,7 @@
/**
* Component for clothing items that can pick up blood from decals and spread it around everywhere when walking, such as shoes or suits with integrated shoes.
*/
* Component for clothing items that can pick up blood from decals and spread it around everywhere when walking, such as shoes or suits with integrated shoes.
*/
/datum/component/bloodysoles
/// The type of the last grub pool we stepped in, used to decide the type of footprints to make
var/last_blood_state = BLOOD_STATE_NOT_BLOODY
@@ -31,8 +31,8 @@
RegisterSignal(parent, COMSIG_COMPONENT_CLEAN_ACT, .proc/on_clean)
/**
* Unregisters from the wielder if necessary
*/
* Unregisters from the wielder if necessary
*/
/datum/component/bloodysoles/proc/unregister()
if(!QDELETED(wielder))
UnregisterSignal(wielder, COMSIG_MOVABLE_MOVED)
@@ -41,21 +41,21 @@
equipped_slot = null
/**
* Returns true if the parent item is obscured by something else that the wielder is wearing
*/
* Returns true if the parent item is obscured by something else that the wielder is wearing
*/
/datum/component/bloodysoles/proc/is_obscured()
return wielder.check_obscured_slots(TRUE) & equipped_slot
/**
* Run to update the icon of the parent
*/
* Run to update the icon of the parent
*/
/datum/component/bloodysoles/proc/update_icon()
var/obj/item/parent_item = parent
parent_item.update_slot_icon()
/**
* Run to equally share the blood between us and a decal
*/
* Run to equally share the blood between us and a decal
*/
/datum/component/bloodysoles/proc/share_blood(obj/effect/decal/cleanable/pool)
last_blood_state = pool.blood_state
@@ -72,24 +72,24 @@
update_icon()
/**
* Find a blood decal on a turf that matches our last_blood_state
*/
* Find a blood decal on a turf that matches our last_blood_state
*/
/datum/component/bloodysoles/proc/find_pool_by_blood_state(turf/turfLoc, typeFilter = null)
for(var/obj/effect/decal/cleanable/blood/pool in turfLoc)
if(pool.blood_state == last_blood_state && (!typeFilter || istype(pool, typeFilter)))
return pool
/**
* Adds the parent type to the footprint's shoe_types var
*/
* Adds the parent type to the footprint's shoe_types var
*/
/datum/component/bloodysoles/proc/add_parent_to_footprint(obj/effect/decal/cleanable/blood/footprints/FP)
FP.shoe_types |= parent.type
/**
* Called when the parent item is equipped by someone
*
* Used to register our wielder
*/
* Called when the parent item is equipped by someone
*
* Used to register our wielder
*/
/datum/component/bloodysoles/proc/on_equip(datum/source, mob/equipper, slot)
SIGNAL_HANDLER
@@ -106,20 +106,20 @@
RegisterSignal(wielder, COMSIG_STEP_ON_BLOOD, .proc/on_step_blood)
/**
* Called when the parent item has been dropped
*
* Used to deregister our wielder
*/
* Called when the parent item has been dropped
*
* Used to deregister our wielder
*/
/datum/component/bloodysoles/proc/on_drop(datum/source, mob/dropper)
SIGNAL_HANDLER
unregister()
/**
* Called when the wielder has moved
*
* Used to make bloody footprints on the ground
*/
* Called when the wielder has moved
*
* Used to make bloody footprints on the ground
*/
/datum/component/bloodysoles/proc/on_moved(datum/source, OldLoc, Dir, Forced)
SIGNAL_HANDLER
@@ -176,10 +176,10 @@
/**
* Called when the wielder steps in a pool of blood
*
* Used to make the parent item bloody
*/
* Called when the wielder steps in a pool of blood
*
* Used to make the parent item bloody
*/
/datum/component/bloodysoles/proc/on_step_blood(datum/source, obj/effect/decal/cleanable/pool)
SIGNAL_HANDLER
@@ -200,8 +200,8 @@
last_pickup = world.time
/**
* Called when the parent item is being washed
*/
* Called when the parent item is being washed
*/
/datum/component/bloodysoles/proc/on_clean(datum/source, clean_types)
SIGNAL_HANDLER
@@ -215,8 +215,8 @@
/**
* Like its parent but can be applied to carbon mobs instead of clothing items
*/
* Like its parent but can be applied to carbon mobs instead of clothing items
*/
/datum/component/bloodysoles/feet
var/static/mutable_appearance/bloody_feet
+6 -6
View File
@@ -60,12 +60,12 @@
*/
/**
* Check that the contents of the recipe meet the requirements.
*
* user: The /mob that initated the crafting.
* R: The /datum/crafting_recipe being attempted.
* contents: List of items to search for R's reqs.
*/
* Check that the contents of the recipe meet the requirements.
*
* user: The /mob that initated the crafting.
* R: The /datum/crafting_recipe being attempted.
* contents: List of items to search for R's reqs.
*/
/datum/component/personal_crafting/proc/check_contents(atom/a, datum/crafting_recipe/R, list/contents)
var/list/item_instances = contents["instances"]
contents = contents["other"]
+31 -23
View File
@@ -19,11 +19,11 @@
blacklist += result
/**
* Run custom pre-craft checks for this recipe
*
* user: The /mob that initiated the crafting
* collected_requirements: A list of lists of /obj/item instances that satisfy reqs. Top level list is keyed by requirement path.
*/
* Run custom pre-craft checks for this recipe
*
* user: The /mob that initiated the crafting
* collected_requirements: A list of lists of /obj/item instances that satisfy reqs. Top level list is keyed by requirement path.
*/
/datum/crafting_recipe/proc/check_requirements(mob/user, list/collected_requirements)
return TRUE
@@ -820,8 +820,9 @@
name = "Collosal Rib"
always_available = FALSE
reqs = list(
/obj/item/stack/sheet/bone = 10,
/datum/reagent/fuel/oil = 5)
/obj/item/stack/sheet/bone = 10,
/datum/reagent/fuel/oil = 5,
)
result = /obj/structure/statue/bone/rib
subcategory = CAT_PRIMAL
@@ -829,8 +830,9 @@
name = "Skull Carving"
always_available = FALSE
reqs = list(
/obj/item/stack/sheet/bone = 6,
/datum/reagent/fuel/oil = 5)
/obj/item/stack/sheet/bone = 6,
/datum/reagent/fuel/oil = 5,
)
result = /obj/structure/statue/bone/skull
category = CAT_PRIMAL
@@ -838,8 +840,9 @@
name = "Cracked Skull Carving"
always_available = FALSE
reqs = list(
/obj/item/stack/sheet/bone = 3,
/datum/reagent/fuel/oil = 5)
/obj/item/stack/sheet/bone = 3,
/datum/reagent/fuel/oil = 5,
)
result = /obj/structure/statue/bone/skull/half
category = CAT_PRIMAL
@@ -847,42 +850,47 @@
name = "Serrated Bone Shovel"
always_available = FALSE
reqs = list(
/obj/item/stack/sheet/bone = 4,
/datum/reagent/fuel/oil = 5,
/obj/item/shovel/spade = 1)
/obj/item/stack/sheet/bone = 4,
/datum/reagent/fuel/oil = 5,
/obj/item/shovel/spade = 1,
)
result = /obj/item/shovel/serrated
category = CAT_PRIMAL
/datum/crafting_recipe/lasso
name = "Bone Lasso"
reqs = list(
/obj/item/stack/sheet/bone = 1,
/obj/item/stack/sheet/sinew = 5)
/obj/item/stack/sheet/bone = 1,
/obj/item/stack/sheet/sinew = 5,
)
result = /obj/item/key/lasso
category = CAT_PRIMAL
/datum/crafting_recipe/gripperoffbrand
name = "Improvised Gripper Gloves"
reqs = list(
/obj/item/clothing/gloves/fingerless = 1,
/obj/item/stack/sticky_tape = 1)
/obj/item/clothing/gloves/fingerless = 1,
/obj/item/stack/sticky_tape = 1,
)
result = /obj/item/clothing/gloves/tackler/offbrand
category = CAT_CLOTHING
/datum/crafting_recipe/boh
name = "Bag of Holding"
reqs = list(
/obj/item/bag_of_holding_inert = 1,
/obj/item/assembly/signaler/anomaly/bluespace = 1)
/obj/item/bag_of_holding_inert = 1,
/obj/item/assembly/signaler/anomaly/bluespace = 1,
)
result = /obj/item/storage/backpack/holding
category = CAT_CLOTHING
/datum/crafting_recipe/ipickaxe
name = "Improvised Pickaxe"
reqs = list(
/obj/item/crowbar = 1,
/obj/item/kitchen/knife = 1,
/obj/item/stack/sticky_tape = 1)
/obj/item/crowbar = 1,
/obj/item/kitchen/knife = 1,
/obj/item/stack/sticky_tape = 1,
)
result = /obj/item/pickaxe/improvised
category = CAT_MISC
+4 -4
View File
@@ -5,10 +5,10 @@ GLOBAL_LIST_INIT(creamable, typecacheof(list(
/mob/living/silicon/ai)))
/**
* Creamed component
*
* For when you have pie on your face
*/
* Creamed component
*
* For when you have pie on your face
*/
/datum/component/creamed
dupe_mode = COMPONENT_DUPE_UNIQUE_PASSARGS
+7 -7
View File
@@ -1,6 +1,6 @@
/**
* A component to reset the parent to its previous state after some time passes
*/
* A component to reset the parent to its previous state after some time passes
*/
/datum/component/dejavu
/// The turf the parent was on when this components was applied, they get moved back here after the duration
var/turf/starting_turf
@@ -35,7 +35,7 @@
starting_turf = get_turf(parent)
rewinds_remaining = rewinds
rewind_interval = interval
if(isliving(parent))
var/mob/living/L = parent
clone_loss = L.getCloneLoss()
@@ -43,22 +43,22 @@
oxy_loss = L.getOxyLoss()
brain_loss = L.getOrganLoss(ORGAN_SLOT_BRAIN)
rewind_type = .proc/rewind_living
if(iscarbon(parent))
var/mob/living/carbon/C = parent
saved_bodyparts = C.save_bodyparts()
rewind_type = .proc/rewind_carbon
else if(isanimal(parent))
var/mob/living/simple_animal/M = parent
brute_loss = M.bruteloss
rewind_type = .proc/rewind_animal
else if(isobj(parent))
var/obj/O = parent
integrity = O.obj_integrity
rewind_type = .proc/rewind_obj
addtimer(CALLBACK(src, rewind_type), rewind_interval)
/datum/component/dejavu/Destroy()
+1 -1
View File
@@ -28,7 +28,7 @@
RegisterSignal(parent, COMSIG_COMPONENT_CLEAN_ACT, .proc/clean_act)
/datum/component/forensics/UnregisterFromParent()
UnregisterSignal(parent, list(COMSIG_COMPONENT_CLEAN_ACT))
UnregisterSignal(parent, list(COMSIG_COMPONENT_CLEAN_ACT))
/datum/component/forensics/PostTransfer()
if(!isatom(parent))
+7 -7
View File
@@ -47,13 +47,13 @@
/**
* Throw a target in a direction
*
* Arguments:
* * target - Target atom to throw
* * thrower - Thing that caused this atom to be thrown
* * throw_dir - Direction to throw the atom
*/
* Throw a target in a direction
*
* Arguments:
* * target - Target atom to throw
* * thrower - Thing that caused this atom to be thrown
* * throw_dir - Direction to throw the atom
*/
/datum/component/knockback/proc/do_knockback(atom/target, mob/thrower, throw_dir)
if(!ismovable(target) || throw_dir == null)
return
+8 -8
View File
@@ -196,14 +196,14 @@
qdel(src)
/**
* Handles how nanites leave the host's body if they find out that they're currently exceeding the maximum supported amount
*
* IC explanation:
* Normally nanites simply discard excess volume by slowing replication or 'sweating' it out in imperceptible amounts,
* but if there is a large excess volume, likely due to a programming change that leaves them unable to support their current volume,
* the nanites attempt to leave the host as fast as necessary to prevent nanite poisoning. This can range from minor oozing to nanites
* rapidly bursting out from every possible pathway, causing temporary inconvenience to the host.
*/
* Handles how nanites leave the host's body if they find out that they're currently exceeding the maximum supported amount
*
* IC explanation:
* Normally nanites simply discard excess volume by slowing replication or 'sweating' it out in imperceptible amounts,
* but if there is a large excess volume, likely due to a programming change that leaves them unable to support their current volume,
* the nanites attempt to leave the host as fast as necessary to prevent nanite poisoning. This can range from minor oozing to nanites
* rapidly bursting out from every possible pathway, causing temporary inconvenience to the host.
*/
/datum/component/nanites/proc/reject_excess_nanites()
var/excess = nanite_volume - max_nanites
nanite_volume = max_nanites
+12 -12
View File
@@ -1,11 +1,11 @@
/**
* omen.dm: For when you want someone to have a really bad day
*
* When you attach an omen component to someone, they start running the risk of all sorts of bad environmental injuries, like nearby vending machines randomly falling on you,
* or hitting your head really hard when you slip and fall, or... well, for now those two are all I have. More will come.
*
* Omens are removed once the victim is either maimed by one of the possible injuries, or if they receive a blessing (read: bashing with a bible) from the chaplain.
*/
* omen.dm: For when you want someone to have a really bad day
*
* When you attach an omen component to someone, they start running the risk of all sorts of bad environmental injuries, like nearby vending machines randomly falling on you,
* or hitting your head really hard when you slip and fall, or... well, for now those two are all I have. More will come.
*
* Omens are removed once the victim is either maimed by one of the possible injuries, or if they receive a blessing (read: bashing with a bible) from the chaplain.
*/
/datum/component/omen
dupe_mode = COMPONENT_DUPE_UNIQUE
@@ -45,11 +45,11 @@
UnregisterSignal(parent, list(COMSIG_LIVING_STATUS_KNOCKDOWN, COMSIG_MOVABLE_MOVED, COMSIG_ADD_MOOD_EVENT))
/**
* check_accident() is called each step we take
*
* While we're walking around, roll to see if there's any environmental hazards (currently only vending machines) on one of the adjacent tiles we can trigger.
* We do the prob() at the beginning to A. add some tension for /when/ it will strike, and B. (more importantly) ameliorate the fact that we're checking up to 5 turfs's contents each time
*/
* check_accident() is called each step we take
*
* While we're walking around, roll to see if there's any environmental hazards (currently only vending machines) on one of the adjacent tiles we can trigger.
* We do the prob() at the beginning to A. add some tension for /when/ it will strike, and B. (more importantly) ameliorate the fact that we're checking up to 5 turfs's contents each time
*/
/datum/component/omen/proc/check_accident(atom/movable/our_guy)
SIGNAL_HANDLER_DOES_SLEEP
+14 -14
View File
@@ -10,20 +10,20 @@
#define SHORT_CAST 2
/**
* Movable atom overlay-based lighting component.
*
* * Component works by applying a visual object to the parent target.
*
* * The component tracks the parent's loc to determine the current_holder.
* * The current_holder is either the parent or its loc, whichever is on a turf. If none, then the current_holder is null and the light is not visible.
*
* * Lighting works at its base by applying a dark overlay and "cutting" said darkness with light, adding (possibly colored) transparency.
* * This component uses the visible_mask visual object to apply said light mask on the darkness.
*
* * The main limitation of this system is that it uses a limited number of pre-baked geometrical shapes, but for most uses it does the job.
*
* * Another limitation is for big lights: you only see the light if you see the object emiting it.
* * For small objects this is good (you can't see them behind a wall), but for big ones this quickly becomes prety clumsy.
* Movable atom overlay-based lighting component.
*
* * Component works by applying a visual object to the parent target.
*
* * The component tracks the parent's loc to determine the current_holder.
* * The current_holder is either the parent or its loc, whichever is on a turf. If none, then the current_holder is null and the light is not visible.
*
* * Lighting works at its base by applying a dark overlay and "cutting" said darkness with light, adding (possibly colored) transparency.
* * This component uses the visible_mask visual object to apply said light mask on the darkness.
*
* * The main limitation of this system is that it uses a limited number of pre-baked geometrical shapes, but for most uses it does the job.
*
* * Another limitation is for big lights: you only see the light if you see the object emiting it.
* * For small objects this is good (you can't see them behind a wall), but for big ones this quickly becomes prety clumsy.
*/
/datum/component/overlay_lighting
///How far the light reaches, float.
+9 -9
View File
@@ -1,14 +1,14 @@
/**
* Handles simple payment operations where the cost of the object in question doesn't change.
*
* What this is useful for:
* Basic forms of vending.
* Objects that can drain the owner's money linearly.
* What this is not useful for:
* Things where the seller may want to fluxuate the price of the object.
* Improving standardizing every form of payment handing, as some custom handling is specific to that object.
**/
* Handles simple payment operations where the cost of the object in question doesn't change.
*
* What this is useful for:
* Basic forms of vending.
* Objects that can drain the owner's money linearly.
* What this is not useful for:
* Things where the seller may want to fluxuate the price of the object.
* Improving standardizing every form of payment handing, as some custom handling is specific to that object.
**/
/datum/component/payment
///Standardized of operation.
var/cost = 10
+22 -22
View File
@@ -92,11 +92,11 @@
UnregisterSignal(parent, list(COMSIG_PARENT_PREQDELETED, COMSIG_PELLET_CLOUD_INIT, COMSIG_GRENADE_DETONATE, COMSIG_GRENADE_ARMED, COMSIG_MOVABLE_MOVED, COMSIG_MOVABLE_UNCROSSED, COMSIG_MINE_TRIGGERED, COMSIG_ITEM_DROPPED))
/**
* create_casing_pellets() is for directed pellet clouds for ammo casings that have multiple pellets (buckshot and scatter lasers for instance)
*
* Honestly this is mostly just a rehash of [/obj/item/ammo_casing/proc/fire_casing] for pellet counts > 1, except this lets us tamper with the pellets and hook onto them for tracking purposes.
* The arguments really don't matter, this proc is triggered by COMSIG_PELLET_CLOUD_INIT which is only for this really, it's just a big mess of the state vars we need for doing the stuff over here.
*/
* create_casing_pellets() is for directed pellet clouds for ammo casings that have multiple pellets (buckshot and scatter lasers for instance)
*
* Honestly this is mostly just a rehash of [/obj/item/ammo_casing/proc/fire_casing] for pellet counts > 1, except this lets us tamper with the pellets and hook onto them for tracking purposes.
* The arguments really don't matter, this proc is triggered by COMSIG_PELLET_CLOUD_INIT which is only for this really, it's just a big mess of the state vars we need for doing the stuff over here.
*/
/datum/component/pellet_cloud/proc/create_casing_pellets(obj/item/ammo_casing/shell, atom/target, mob/living/user, fired_from, randomspread, spread, zone_override, params, distro)
SIGNAL_HANDLER_DOES_SLEEP
@@ -130,15 +130,15 @@
shell.newshot()
/**
* create_blast_pellets() is for when we have a central point we want to shred the surroundings of with a ring of shrapnel, namely frag grenades and landmines.
*
* Note that grenades have extra handling for someone throwing themselves/being thrown on top of it, see [/datum/component/pellet_cloud/proc/handle_martyrs]
* Landmines just have a small check for [/obj/effect/mine/shrapnel/var/shred_triggerer], and spawn extra shrapnel for them if so
*
* Arguments:
* * O- Our parent, the thing making the shrapnel obviously (grenade or landmine)
* * punishable_triggerer- For grenade lances or people who step on the landmines (if we shred the triggerer), we spawn extra shrapnel for them in addition to the normal spread
*/
* create_blast_pellets() is for when we have a central point we want to shred the surroundings of with a ring of shrapnel, namely frag grenades and landmines.
*
* Note that grenades have extra handling for someone throwing themselves/being thrown on top of it, see [/datum/component/pellet_cloud/proc/handle_martyrs]
* Landmines just have a small check for [/obj/effect/mine/shrapnel/var/shred_triggerer], and spawn extra shrapnel for them if so
*
* Arguments:
* * O- Our parent, the thing making the shrapnel obviously (grenade or landmine)
* * punishable_triggerer- For grenade lances or people who step on the landmines (if we shred the triggerer), we spawn extra shrapnel for them in addition to the normal spread
*/
/datum/component/pellet_cloud/proc/create_blast_pellets(obj/O, mob/living/punishable_triggerer)
SIGNAL_HANDLER_DOES_SLEEP
@@ -164,14 +164,14 @@
pew(shootat_turf)
/**
* handle_martyrs() is used for grenades that shoot shrapnel to check if anyone threw themselves/were thrown on top of the grenade, thus absorbing a good chunk of the shrapnel
*
* Between the time the grenade is armed and the actual detonation, we set var/list/bodies to the list of mobs currently on the new tile, as if the grenade landed on top of them, tracking if any of them move off the tile and removing them from the "under" list
* Once the grenade detonates, handle_martyrs() is called and gets all the new mobs on the tile, and add the ones not in var/list/bodies to var/list/martyrs
* We then iterate through the martyrs and reduce the shrapnel magnitude for each mob on top of it, shredding each of them with some of the shrapnel they helped absorb. This can snuff out all of the shrapnel if there's enough bodies
*
* Note we track anyone who's alive and client'd when they get shredded in var/list/purple_hearts, for achievement checking later
*/
* handle_martyrs() is used for grenades that shoot shrapnel to check if anyone threw themselves/were thrown on top of the grenade, thus absorbing a good chunk of the shrapnel
*
* Between the time the grenade is armed and the actual detonation, we set var/list/bodies to the list of mobs currently on the new tile, as if the grenade landed on top of them, tracking if any of them move off the tile and removing them from the "under" list
* Once the grenade detonates, handle_martyrs() is called and gets all the new mobs on the tile, and add the ones not in var/list/bodies to var/list/martyrs
* We then iterate through the martyrs and reduce the shrapnel magnitude for each mob on top of it, shredding each of them with some of the shrapnel they helped absorb. This can snuff out all of the shrapnel if there's enough bodies
*
* Note we track anyone who's alive and client'd when they get shredded in var/list/purple_hearts, for achievement checking later
*/
/datum/component/pellet_cloud/proc/handle_martyrs(mob/living/punishable_triggerer)
var/magnitude_absorbed
var/list/martyrs = list()
+13 -13
View File
@@ -1,8 +1,8 @@
/**
*
* Allows the parent to act similarly to the Altar of Gods with modularity. Invoke and Sect Selection is done via attacking with a bible. This means you cannot sacrifice Bibles (you shouldn't want to do this anyways although now that I mentioned it you probably will want to).
*
*/
*
* Allows the parent to act similarly to the Altar of Gods with modularity. Invoke and Sect Selection is done via attacking with a bible. This means you cannot sacrifice Bibles (you shouldn't want to do this anyways although now that I mentioned it you probably will want to).
*
*/
/datum/component/religious_tool
dupe_mode = COMPONENT_DUPE_UNIQUE
/// Enables access to the global sect directly
@@ -34,8 +34,8 @@
UnregisterSignal(parent, list(COMSIG_PARENT_ATTACKBY, COMSIG_PARENT_EXAMINE))
/**
* Sets the easy access variable to the global if it exists.
*/
* Sets the easy access variable to the global if it exists.
*/
/datum/component/religious_tool/proc/SetGlobalToLocal()
if(easy_access_sect)
return TRUE
@@ -48,8 +48,8 @@
/**
* Since all of these involve attackby, we require mega proc. Handles Invocation, Sacrificing, And Selection of Sects.
*/
* Since all of these involve attackby, we require mega proc. Handles Invocation, Sacrificing, And Selection of Sects.
*/
/datum/component/religious_tool/proc/AttemptActions(datum/source, obj/item/the_item, mob/living/user)
SIGNAL_HANDLER
@@ -57,7 +57,7 @@
if(!SetGlobalToLocal())
if(!(operation_flags & RELIGION_TOOL_SECTSELECT))
return
//At this point you're intentionally trying to select a sect.
//At this point you're intentionally trying to select a sect.
INVOKE_ASYNC(src, .proc/select_sect, user)
return COMPONENT_NO_AFTERATTACK
@@ -122,8 +122,8 @@
QDEL_NULL(performing_rite)
/**
* Generates a list of available sects to the user. Intended to support custom-availability sects. Because these are not instanced, we cannot put the availability on said sect beyond variables.
*/
* Generates a list of available sects to the user. Intended to support custom-availability sects. Because these are not instanced, we cannot put the availability on said sect beyond variables.
*/
/datum/component/religious_tool/proc/generate_available_sects(mob/user)
. = list()
for(var/i in subtypesof(/datum/religion_sect))
@@ -132,8 +132,8 @@
. += list(initial(not_a_real_instance_rs.name) = i)
/**
* Appends to examine so the user knows it can be used for religious purposes.
*/
* Appends to examine so the user knows it can be used for religious purposes.
*/
/datum/component/religious_tool/proc/on_examine(datum/source, mob/user, list/examine_list)
SIGNAL_HANDLER
+8 -8
View File
@@ -35,14 +35,14 @@ It has a punishment variable that is what happens to the parent when they leave
message = _message
/**
* Called when parent leaves the zlevel this is set to (aka whichever zlevel it was on when it was added)
* Sends a message, then does an effect depending on what the punishment was.
*
* Punishments:
* * PUNISHMENT_MURDER: kills parent
* * PUNISHMENT_GIB: gibs parent
* * PUNISHMENT_TELEPORT: finds a safe turf if possible, or a completely random one if not.
*/
* Called when parent leaves the zlevel this is set to (aka whichever zlevel it was on when it was added)
* Sends a message, then does an effect depending on what the punishment was.
*
* Punishments:
* * PUNISHMENT_MURDER: kills parent
* * PUNISHMENT_GIB: gibs parent
* * PUNISHMENT_TELEPORT: finds a safe turf if possible, or a completely random one if not.
*/
/datum/component/stationstuck/proc/punish()
SIGNAL_HANDLER
@@ -1,6 +1,6 @@
/**
*A storage component to be used on card piles, for use as hands/decks/discard piles. Don't use on something that's not a card pile!
*/
*A storage component to be used on card piles, for use as hands/decks/discard piles. Don't use on something that's not a card pile!
*/
/datum/component/storage/concrete/tcg
display_numerical_stacking = FALSE
max_w_class = WEIGHT_CLASS_TINY
+43 -43
View File
@@ -37,13 +37,13 @@
. = ..()
/** Begins the process of inserted an item.
*
* Clicking on the food storage with an item will begin a do_after, which if successful inserts the item.
*
* Arguments
* inserted_item - the item being placed into the food
* user - the person inserting the item
*/
*
* Clicking on the food storage with an item will begin a do_after, which if successful inserts the item.
*
* Arguments
* inserted_item - the item being placed into the food
* user - the person inserting the item
*/
/datum/component/food_storage/proc/try_inserting_item(datum/source, obj/item/inserted_item, mob/user, params)
SIGNAL_HANDLER
@@ -74,12 +74,12 @@
return COMPONENT_CANCEL_ATTACK_CHAIN
/** Begins the process of attempting to remove the stored item.
*
* Clicking on food storage on grab intent will begin a do_after, which if successful removes the stored_item.
*
* Arguments
* user - the person removing the item.
*/
*
* Clicking on food storage on grab intent will begin a do_after, which if successful removes the stored_item.
*
* Arguments
* user - the person removing the item.
*/
/datum/component/food_storage/proc/try_removing_item(datum/source, mob/user)
SIGNAL_HANDLER
@@ -96,11 +96,11 @@
return COMPONENT_CANCEL_ATTACK_CHAIN
/** Inserts the item into the food, after a do_after.
*
* Arguments
* inserted_item - The item being inserted.
* user - the person inserting the item.
*/
*
* Arguments
* inserted_item - The item being inserted.
* user - the person inserting the item.
*/
/datum/component/food_storage/proc/insert_item(obj/item/inserted_item, mob/user)
if(do_after(user, 1.5 SECONDS, target = parent))
var/atom/food = parent
@@ -113,17 +113,17 @@
stored_item = inserted_item
/** Removes the item from the food, after a do_after.
*
* Arguments
* user - person removing the item.
*/
*
* Arguments
* user - person removing the item.
*/
/datum/component/food_storage/proc/begin_remove_item(mob/user)
if(do_after(user, 10 SECONDS, target = parent))
remove_item(user)
/**
* Removes the stored item, putting it in user's hands or on the ground, then updates the reference.
*/
* Removes the stored item, putting it in user's hands or on the ground, then updates the reference.
*/
/datum/component/food_storage/proc/remove_item(mob/user)
if(user.put_in_hands(stored_item))
user.visible_message("<span class='warning'>[user.name] slowly pulls [stored_item.name] out of \the [parent].</span>", \
@@ -135,18 +135,18 @@
update_stored_item()
/** Checks for stored items when the food is eaten.
*
* If the food is eaten while an item is stored in it, calculates the odds that the item will be found.
* Then, if the item is found before being bitten, the item is removed.
* If the item is found by biting into it, calls on_accidental_consumption on the stored item.
* Afterwards, removes the item from the food if it was discovered.
*
* Arguments
* target - person doing the eating (can be the same as user)
* user - person causing the eating to happen
* bitecount - how many times the current food has been bitten
* bitesize - how large bties are for this food
*/
*
* If the food is eaten while an item is stored in it, calculates the odds that the item will be found.
* Then, if the item is found before being bitten, the item is removed.
* If the item is found by biting into it, calls on_accidental_consumption on the stored item.
* Afterwards, removes the item from the food if it was discovered.
*
* Arguments
* target - person doing the eating (can be the same as user)
* user - person causing the eating to happen
* bitecount - how many times the current food has been bitten
* bitesize - how large bties are for this food
*/
/datum/component/food_storage/proc/consume_food_storage(datum/source, mob/living/target, mob/living/user, bitecount, bitesize)
SIGNAL_HANDLER
@@ -172,13 +172,13 @@
INVOKE_ASYNC(src, .proc/remove_item, user)
/** Updates the reference of the stored item.
*
* Checks the food's contents for if an alternate item was placed into the food.
* If there is an alternate item, updates the reference to the new item.
* If there isn't, updates the reference to null.
*
* Returns FALSE if the ref is nulled, or TRUE is another item replaced it.
*/
*
* Checks the food's contents for if an alternate item was placed into the food.
* If there is an alternate item, updates the reference to the new item.
* If there isn't, updates the reference to null.
*
* Returns FALSE if the ref is nulled, or TRUE is another item replaced it.
*/
/datum/component/food_storage/proc/update_stored_item()
var/atom/food = parent
if(!food?.contents.len) //if there's no items in the food or food is deleted somehow
+4 -4
View File
@@ -1,8 +1,8 @@
/**
*
* Allows parent (obj) to initiate surgeries.
*
*/
*
* Allows parent (obj) to initiate surgeries.
*
*/
/datum/component/surgery_initiator
dupe_mode = COMPONENT_DUPE_UNIQUE
///allows for post-selection manipulation of parent
+37 -37
View File
@@ -2,14 +2,14 @@
#define MAX_TABLE_MESSES 12
/**
* For when you want to throw a person at something and have fun stuff happen
*
* This component is made for carbon mobs (really, humans), and allows its parent to throw themselves and perform tackles. This is done by enabling throw mode, then clicking on your
* intended target with an empty hand. You will then launch toward your target. If you hit a carbon, you'll roll to see how hard you hit them. If you hit a solid non-mob, you'll
* roll to see how badly you just messed yourself up. If, along your journey, you hit a table, you'll slam onto it and send up to MAX_TABLE_MESSES (8) /obj/items on the table flying,
* and take a bit of extra damage and stun for each thing launched.
*
* There are 2 separate """skill rolls""" involved here, which are handled and explained in [rollTackle()][/datum/component/tackler/proc/rollTackle] (for roll 1, carbons), and [splat()][/datum/component/tackler/proc/splat] (for roll 2, walls and solid objects)
* For when you want to throw a person at something and have fun stuff happen
*
* This component is made for carbon mobs (really, humans), and allows its parent to throw themselves and perform tackles. This is done by enabling throw mode, then clicking on your
* intended target with an empty hand. You will then launch toward your target. If you hit a carbon, you'll roll to see how hard you hit them. If you hit a solid non-mob, you'll
* roll to see how badly you just messed yourself up. If, along your journey, you hit a table, you'll slam onto it and send up to MAX_TABLE_MESSES (8) /obj/items on the table flying,
* and take a bit of extra damage and stun for each thing launched.
*
* There are 2 separate """skill rolls""" involved here, which are handled and explained in [rollTackle()][/datum/component/tackler/proc/rollTackle] (for roll 1, carbons), and [splat()][/datum/component/tackler/proc/splat] (for roll 2, walls and solid objects)
*/
/datum/component/tackler
dupe_mode = COMPONENT_DUPE_UNIQUE
@@ -231,14 +231,14 @@
return COMPONENT_MOVABLE_IMPACT_FLIP_HITPUSH
/**
* This handles all of the modifiers for the actual carbon-on-carbon tackling, and gets its own proc because of how many there are (with plenty more in mind!)
*
* The base roll is between (-3, 3), with negative numbers favoring the target, and positive numbers favoring the tackler. The target and the tackler are both assessed for
* how easy they are to knock over, with clumsiness and dwarfiness being strong maluses for each, and gigantism giving a bonus for each. These numbers and ideas
* are absolutely subject to change.
* This handles all of the modifiers for the actual carbon-on-carbon tackling, and gets its own proc because of how many there are (with plenty more in mind!)
*
* The base roll is between (-3, 3), with negative numbers favoring the target, and positive numbers favoring the tackler. The target and the tackler are both assessed for
* how easy they are to knock over, with clumsiness and dwarfiness being strong maluses for each, and gigantism giving a bonus for each. These numbers and ideas
* are absolutely subject to change.
* In addition, after subtracting the defender's mod and adding the attacker's mod to the roll, the component's base (skill) mod is added as well. Some sources of tackles
* are better at taking people down, like the bruiser and rocket gloves, while the dolphin gloves have a malus in exchange for better mobility.
* In addition, after subtracting the defender's mod and adding the attacker's mod to the roll, the component's base (skill) mod is added as well. Some sources of tackles
* are better at taking people down, like the bruiser and rocket gloves, while the dolphin gloves have a malus in exchange for better mobility.
*/
/datum/component/tackler/proc/rollTackle(mob/living/carbon/target)
var/defense_mod = 0
@@ -315,28 +315,28 @@
/**
* This is where we handle diving into dense atoms, generally with effects ranging from bad to REALLY bad. This works as a percentile roll that is modified in two steps as detailed below. The higher
* the roll, the more severe the result.
*
* Mod 1: Speed-
* * Base tackle speed is 1, which is what normal gripper gloves use. For other sources with higher speed tackles, like dolphin and ESPECIALLY rocket gloves, we obey Newton's laws and hit things harder.
* * For every unit of speed above 1, move the lower bound of the roll up by 15. Unlike Mod 2, this only serves to raise the lower bound, so it can't be directly counteracted by anything you can control.
*
* Mod 2: Misc-
* -Flat modifiers, these take whatever you rolled and add/subtract to it, with the end result capped between the minimum from Mod 1 and 100. Note that since we can't roll higher than 100 to start with,
* wearing a helmet should be enough to remove any chance of permanently paralyzing yourself and dramatically lessen knocking yourself unconscious, even with rocket gloves. Will expand on maybe
* * Wearing a helmet: -6
* * Wearing riot armor: -6
* * Clumsy: +6
*
* Effects: Below are the outcomes based off your roll, in order of increasing severity
*
* * 1-67: Knocked down for a few seconds and a bit of brute and stamina damage
* * 68-85: Knocked silly, gain some confusion as well as the above
* * 86-92: Cranial trauma, get a concussion and more confusion, plus more damage
* * 93-96: Knocked unconscious, get a random mild brain trauma, as well as a fair amount of damage
* * 97-98: Massive head damage, probably crack your skull open, random mild brain trauma
* * 99-Infinity: Break your spinal cord, get paralyzed, take a bunch of damage too. Very unlucky!
* This is where we handle diving into dense atoms, generally with effects ranging from bad to REALLY bad. This works as a percentile roll that is modified in two steps as detailed below. The higher
* the roll, the more severe the result.
*
* Mod 1: Speed-
* * Base tackle speed is 1, which is what normal gripper gloves use. For other sources with higher speed tackles, like dolphin and ESPECIALLY rocket gloves, we obey Newton's laws and hit things harder.
* * For every unit of speed above 1, move the lower bound of the roll up by 15. Unlike Mod 2, this only serves to raise the lower bound, so it can't be directly counteracted by anything you can control.
*
* Mod 2: Misc-
* -Flat modifiers, these take whatever you rolled and add/subtract to it, with the end result capped between the minimum from Mod 1 and 100. Note that since we can't roll higher than 100 to start with,
* wearing a helmet should be enough to remove any chance of permanently paralyzing yourself and dramatically lessen knocking yourself unconscious, even with rocket gloves. Will expand on maybe
* * Wearing a helmet: -6
* * Wearing riot armor: -6
* * Clumsy: +6
*
* Effects: Below are the outcomes based off your roll, in order of increasing severity
*
* * 1-67: Knocked down for a few seconds and a bit of brute and stamina damage
* * 68-85: Knocked silly, gain some confusion as well as the above
* * 86-92: Cranial trauma, get a concussion and more confusion, plus more damage
* * 93-96: Knocked unconscious, get a random mild brain trauma, as well as a fair amount of damage
* * 97-98: Massive head damage, probably crack your skull open, random mild brain trauma
* * 99-Infinity: Break your spinal cord, get paralyzed, take a bunch of damage too. Very unlucky!
*/
/datum/component/tackler/proc/splat(mob/living/carbon/user, atom/hit)
if(istype(hit, /obj/machinery/vending)) // before we do anything else-