Updates to tgstation commit 78e471d
This commit is contained in:
@@ -45996,9 +45996,6 @@
|
||||
sortType = 20
|
||||
},
|
||||
/obj/machinery/atmospherics/pipe/simple/supply/hidden,
|
||||
/obj/machinery/atmospherics/pipe/simple/scrubbers/hidden{
|
||||
dir = 4
|
||||
},
|
||||
/obj/effect/turf_decal/stripes/line{
|
||||
dir = 8
|
||||
},
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
#define SEND_SIGNAL(target, sigtype, arguments...) ( !target.datum_components ? NONE : target._SendSignal(sigtype, list(##arguments)) )
|
||||
#define SEND_SIGNAL(target, sigtype, arguments...) ( !target.comp_lookup || !target.comp_lookup[sigtype] ? NONE : target._SendSignal(sigtype, list(##arguments)) )
|
||||
|
||||
#define SEND_GLOBAL_SIGNAL(sigtype, arguments...) ( !SSdcs.comp_lookup[sigtype] ? NONE : SSdcs._SendGlobalSignal(sigtype, list(##arguments)) )
|
||||
#define SEND_GLOBAL_SIGNAL(sigtype, arguments...) ( SEND_SIGNAL(SSdcs, sigtype, ##arguments) )
|
||||
|
||||
//shorthand
|
||||
#define GET_COMPONENT_FROM(varname, path, target) var##path/##varname = ##target.GetComponent(##path)
|
||||
@@ -20,7 +20,7 @@
|
||||
|
||||
// global signals
|
||||
// These are signals which can be listened to by any component on any parent
|
||||
// GLOBAL SIGNALS MUST START WITH "!"
|
||||
// start global signals with "!", this used to be necessary but now it's just a formatting choice
|
||||
#define COMSIG_GLOB_NEW_Z "!new_z" //from base of datum/controller/subsystem/mapping/proc/add_new_zlevel(): (list/args)
|
||||
#define COMSIG_GLOB_VAR_EDIT "!var_edit" //called after a successful var edit somewhere in the world: (list/args)
|
||||
|
||||
@@ -44,6 +44,8 @@
|
||||
//End positions
|
||||
#define COMPONENT_EXNAME_CHANGED 1
|
||||
#define COMSIG_ATOM_ENTERED "atom_entered" //from base of atom/Entered(): (atom/movable/entering, /atom)
|
||||
#define COMSIG_ATOM_EXIT "atom_exit" //from base of atom/Exit(): (/atom/movable/exiting, /atom/newloc)
|
||||
#define COMPONENT_ATOM_BLOCK_EXIT 1
|
||||
#define COMSIG_ATOM_EXITED "atom_exited" //from base of atom/Exited(): (atom/movable/exiting, atom/newloc)
|
||||
#define COMSIG_ATOM_EX_ACT "atom_ex_act" //from base of atom/ex_act(): (severity, target)
|
||||
#define COMSIG_ATOM_EMP_ACT "atom_emp_act" //from base of atom/emp_act(): (severity)
|
||||
@@ -90,6 +92,8 @@
|
||||
// /atom/movable signals
|
||||
#define COMSIG_MOVABLE_MOVED "movable_moved" //from base of atom/movable/Moved(): (/atom, dir)
|
||||
#define COMSIG_MOVABLE_CROSSED "movable_crossed" //from base of atom/movable/Crossed(): (/atom/movable)
|
||||
#define COMSIG_MOVABLE_UNCROSS "movable_uncross" //from base of atom/movable/Uncross(): (/atom/movable)
|
||||
#define COMPONENT_MOVABLE_BLOCK_UNCROSS 1
|
||||
#define COMSIG_MOVABLE_UNCROSSED "movable_uncrossed" //from base of atom/movable/Uncrossed(): (/atom/movable)
|
||||
#define COMSIG_MOVABLE_COLLIDE "movable_collide" //from base of atom/movable/Collide(): (/atom)
|
||||
#define COMSIG_MOVABLE_IMPACT "movable_impact" //from base of atom/movable/throw_impact(): (/atom/hit_atom, /datum/thrownthing/throwingdatum)
|
||||
@@ -119,7 +123,7 @@
|
||||
#define COMSIG_ITEM_PRE_ATTACK "item_pre_attack" //from base of obj/item/pre_attack(): (atom/target, mob/user, params)
|
||||
#define COMPONENT_NO_ATTACK 1
|
||||
#define COMSIG_ITEM_EQUIPPED "item_equip" //from base of obj/item/equipped(): (/mob/equipper, slot)
|
||||
#define COMSIG_ITEM_DROPPED "item_drop"
|
||||
#define COMSIG_ITEM_DROPPED "item_drop" //from base of obj/item/dropped(): (mob/user)
|
||||
#define COMSIG_ITEM_PICKUP "item_pickup" //from base of obj/item/pickup(): (/mob/taker)
|
||||
#define COMSIG_ITEM_ATTACK_ZONE "item_attack_zone" //from base of mob/living/carbon/attacked_by(): (mob/living/carbon/target, mob/living/user, hit_zone)
|
||||
#define COMSIG_ITEM_IMBUE_SOUL "item_imbue_soul" //return a truthy value to prevent ensouling, checked in /obj/effect/proc_holder/spell/targeted/lichdom/cast(): (mob/user)
|
||||
|
||||
7
code/__DEFINES/rust_g.dm
Normal file
7
code/__DEFINES/rust_g.dm
Normal file
@@ -0,0 +1,7 @@
|
||||
// rust_g.dm - DM API for rust_g extension library
|
||||
#define RUST_G "rust_g"
|
||||
|
||||
#define rustg_dmi_strip_metadata(fname) call(RUST_G, "dmi_strip_metadata")(fname)
|
||||
|
||||
#define rustg_log_write(fname, text) call(RUST_G, "log_write")(fname, text)
|
||||
/proc/rustg_log_close_all() return call(RUST_G, "log_close_all")()
|
||||
@@ -1,13 +1,10 @@
|
||||
//location of the rust-g library
|
||||
#define RUST_G "rust_g"
|
||||
|
||||
//wrapper macros for easier grepping
|
||||
#define DIRECT_OUTPUT(A, B) A << B
|
||||
#define SEND_IMAGE(target, image) DIRECT_OUTPUT(target, image)
|
||||
#define SEND_SOUND(target, sound) DIRECT_OUTPUT(target, sound)
|
||||
#define SEND_TEXT(target, text) DIRECT_OUTPUT(target, text)
|
||||
#define WRITE_FILE(file, text) DIRECT_OUTPUT(file, text)
|
||||
#define WRITE_LOG(log, text) call(RUST_G, "log_write")(log, text)
|
||||
#define WRITE_LOG(log, text) rustg_log_write(log, text)
|
||||
|
||||
//print a warning message to world.log
|
||||
#define WARNING(MSG) warning("[MSG] in [__FILE__] at line [__LINE__] src: [src] usr: [usr].")
|
||||
@@ -156,7 +153,7 @@
|
||||
|
||||
/* Close open log handles. This should be called as late as possible, and no logging should hapen after. */
|
||||
/proc/shutdown_logging()
|
||||
call(RUST_G, "log_close_all")()
|
||||
rustg_log_close_all()
|
||||
|
||||
|
||||
/* Helper procs for building detailed log lines */
|
||||
@@ -176,6 +173,3 @@
|
||||
return "[A.loc] [COORD(T)] ([A.loc.type])"
|
||||
else if(A.loc)
|
||||
return "[A.loc] (0, 0, 0) ([A.loc.type])"
|
||||
|
||||
//this is only used here (for now)
|
||||
#undef RUST_G
|
||||
|
||||
@@ -314,6 +314,9 @@ or shoot a gun to move around via Newton's 3rd Law of Motion."
|
||||
/obj/screen/alert/bloodsense/process()
|
||||
var/atom/blood_target
|
||||
|
||||
if(!mob_viewer.mind)
|
||||
return
|
||||
|
||||
var/datum/antagonist/cult/antag = mob_viewer.mind.has_antag_datum(/datum/antagonist/cult,TRUE)
|
||||
if(!antag)
|
||||
return
|
||||
|
||||
@@ -20,6 +20,7 @@ SUBSYSTEM_DEF(blackbox)
|
||||
record_feedback("amount", "random_seed", Master.random_seed)
|
||||
record_feedback("amount", "dm_version", DM_VERSION)
|
||||
record_feedback("amount", "byond_version", world.byond_version)
|
||||
record_feedback("amount", "byond_build", world.byond_build)
|
||||
. = ..()
|
||||
|
||||
//poll population
|
||||
|
||||
@@ -2,34 +2,5 @@ SUBSYSTEM_DEF(dcs)
|
||||
name = "Datum Component System"
|
||||
flags = SS_NO_INIT | SS_NO_FIRE
|
||||
|
||||
var/list/comp_lookup = list() // A signal:list(components) assoc list
|
||||
|
||||
/datum/controller/subsystem/dcs/proc/_SendGlobalSignal(sigtype, list/arguments)
|
||||
. = NONE
|
||||
for(var/i in comp_lookup[sigtype])
|
||||
var/datum/component/comp = i
|
||||
if(!comp.enabled)
|
||||
continue
|
||||
var/datum/callback/CB = comp.signal_procs[sigtype]
|
||||
if(!CB)
|
||||
continue // Should we error from this?
|
||||
. |= CB.InvokeAsync(arglist(arguments))
|
||||
|
||||
/datum/controller/subsystem/dcs/proc/RegisterSignal(datum/component/comp, sigtype)
|
||||
if(!comp_lookup[sigtype])
|
||||
comp_lookup[sigtype] = list()
|
||||
|
||||
comp_lookup[sigtype][comp] = TRUE
|
||||
|
||||
/datum/controller/subsystem/dcs/proc/UnregisterSignal(datum/component/comp, list/sigtypes)
|
||||
if(!length(sigtypes))
|
||||
sigtypes = list(sigtypes)
|
||||
for(var/sigtype in sigtypes)
|
||||
switch(length(comp_lookup[sigtype]))
|
||||
if(1)
|
||||
comp_lookup -= sigtype
|
||||
if(2 to INFINITY)
|
||||
comp_lookup[sigtype] -= comp
|
||||
|
||||
/datum/controller/subsystem/dcs/Recover()
|
||||
comp_lookup = SSdcs.comp_lookup
|
||||
|
||||
@@ -49,7 +49,11 @@ SUBSYSTEM_DEF(mapping)
|
||||
if(initialized)
|
||||
return
|
||||
if(config.defaulted)
|
||||
to_chat(world, "<span class='boldannounce'>Unable to load next map config, defaulting to Box Station</span>")
|
||||
var/old_config = config
|
||||
config = global.config.defaultmap
|
||||
if(!config || config.defaulted)
|
||||
to_chat(world, "<span class='boldannounce'>Unable to load next or default map config, defaulting to Box Station</span>")
|
||||
config = old_config
|
||||
loader = new
|
||||
loadWorld()
|
||||
repopulate_sorted_areas()
|
||||
|
||||
@@ -392,8 +392,8 @@ SUBSYSTEM_DEF(ticker)
|
||||
captainless=0
|
||||
if(player.mind.assigned_role != player.mind.special_role)
|
||||
SSjob.EquipRank(N, player.mind.assigned_role, 0)
|
||||
if(CONFIG_GET(flag/roundstart_traits))
|
||||
SSquirks.AssignQuirks(player, N.client, TRUE)
|
||||
if(CONFIG_GET(flag/roundstart_traits) && ishuman(N.new_character))
|
||||
SSquirks.AssignQuirks(N.new_character, N.client, TRUE)
|
||||
CHECK_TICK
|
||||
if(captainless)
|
||||
for(var/mob/dead/new_player/N in GLOB.player_list)
|
||||
|
||||
@@ -115,7 +115,7 @@ Stands have a lot of procs which mimic mob procs. Rather than inserting hooks fo
|
||||
* Clears `parent` and removes the component from it's component list
|
||||
1. `/datum/component/proc/_JoinParent` (private, final)
|
||||
* Tries to add the component to it's `parent`s `datum_components` list
|
||||
1. `/datum/component/proc/RegisterSignal(signal(string/list of strings), proc_ref(type), override(boolean))` (protected, final) (Consider removing for performance gainz)
|
||||
1. `/datum/component/proc/RegisterSignal(datum/target, signal(string/list of strings), proc_ref(type), override(boolean))` (protected, final)
|
||||
* If signal is a list it will be as if RegisterSignal was called for each of the entries with the same following arguments
|
||||
* Makes a component listen for the specified `signal` on it's `parent` datum.
|
||||
* When that signal is received `proc_ref` will be called on the component, along with associated arguments
|
||||
|
||||
@@ -58,8 +58,8 @@
|
||||
if(!silent)
|
||||
SEND_SIGNAL(P, COMSIG_COMPONENT_REMOVING, src)
|
||||
parent = null
|
||||
SSdcs.UnregisterSignal(src, signal_procs)
|
||||
LAZYCLEARLIST(signal_procs)
|
||||
for(var/target in signal_procs)
|
||||
UnregisterSignal(target, signal_procs[target])
|
||||
return ..()
|
||||
|
||||
/datum/component/proc/_RemoveFromParent()
|
||||
@@ -78,34 +78,69 @@
|
||||
if(!dc.len)
|
||||
P.datum_components = null
|
||||
|
||||
/datum/component/proc/RegisterSignal(sig_type_or_types, proc_or_callback, override = FALSE)
|
||||
if(QDELETED(src))
|
||||
/datum/component/proc/RegisterSignal(datum/target, sig_type_or_types, proc_or_callback, override = FALSE)
|
||||
if(QDELETED(src) || QDELETED(target))
|
||||
return
|
||||
|
||||
var/list/procs = signal_procs
|
||||
if(!procs)
|
||||
procs = list()
|
||||
signal_procs = procs
|
||||
signal_procs = procs = list()
|
||||
if(!procs[target])
|
||||
procs[target] = list()
|
||||
var/list/lookup = target.comp_lookup
|
||||
if(!lookup)
|
||||
target.comp_lookup = lookup = list()
|
||||
|
||||
if(!istype(proc_or_callback, /datum/callback)) //if it wasnt a callback before, it is now
|
||||
proc_or_callback = CALLBACK(src, proc_or_callback)
|
||||
|
||||
var/list/sig_types = islist(sig_type_or_types) ? sig_type_or_types : list(sig_type_or_types)
|
||||
for(var/sig_type in sig_types)
|
||||
if(!override && procs[sig_type])
|
||||
if(!override && procs[target][sig_type])
|
||||
stack_trace("[sig_type] overridden. Use override = TRUE to suppress this warning")
|
||||
|
||||
if(sig_type[1] == "!")
|
||||
SSdcs.RegisterSignal(src, sig_type)
|
||||
|
||||
procs[sig_type] = proc_or_callback
|
||||
procs[target][sig_type] = proc_or_callback
|
||||
|
||||
if(!lookup[sig_type]) // Nothing has registered here yet
|
||||
lookup[sig_type] = src
|
||||
else if(lookup[sig_type] == src) // We already registered here
|
||||
continue
|
||||
else if(!length(lookup[sig_type])) // One other thing registered here
|
||||
lookup[sig_type] = list(lookup[sig_type]=TRUE)
|
||||
lookup[sig_type][src] = TRUE
|
||||
else // Many other things have registered here
|
||||
lookup[sig_type][src] = TRUE
|
||||
|
||||
enabled = TRUE
|
||||
|
||||
/datum/component/proc/HasSignal(sig_type)
|
||||
return signal_procs[sig_type] != null
|
||||
/datum/component/proc/UnregisterSignal(datum/target, sig_type_or_types)
|
||||
var/list/lookup = target.comp_lookup
|
||||
if(!signal_procs || !signal_procs[target] || !lookup)
|
||||
return
|
||||
if(!islist(sig_type_or_types))
|
||||
sig_type_or_types = list(sig_type_or_types)
|
||||
for(var/sig in sig_type_or_types)
|
||||
switch(length(lookup[sig]))
|
||||
if(2)
|
||||
lookup[sig] = (lookup[sig]-src)[1]
|
||||
if(1)
|
||||
stack_trace("[target] ([target.type]) somehow has single length list inside comp_lookup")
|
||||
if(src in lookup[sig])
|
||||
lookup -= sig
|
||||
if(!length(lookup))
|
||||
target.comp_lookup = null
|
||||
break
|
||||
if(0)
|
||||
lookup -= sig
|
||||
if(!length(lookup))
|
||||
target.comp_lookup = null
|
||||
break
|
||||
else
|
||||
lookup[sig] -= src
|
||||
|
||||
/datum/component/proc/UnregisterSignal(sig_type_or_types)
|
||||
signal_procs -= sig_type_or_types
|
||||
signal_procs[target] -= sig_type_or_types
|
||||
if(!signal_procs[target].len)
|
||||
signal_procs -= target
|
||||
|
||||
/datum/component/proc/InheritComponent(datum/component/C, i_am_original)
|
||||
return
|
||||
@@ -126,23 +161,19 @@
|
||||
. += current_type
|
||||
|
||||
/datum/proc/_SendSignal(sigtype, list/arguments)
|
||||
var/target = datum_components[/datum/component]
|
||||
var/target = comp_lookup[sigtype]
|
||||
if(!length(target))
|
||||
var/datum/component/C = target
|
||||
if(!C.enabled)
|
||||
return NONE
|
||||
var/datum/callback/CB = C.signal_procs[sigtype]
|
||||
if(!CB)
|
||||
return NONE
|
||||
var/datum/callback/CB = C.signal_procs[src][sigtype]
|
||||
return CB.InvokeAsync(arglist(arguments))
|
||||
. = NONE
|
||||
for(var/I in target)
|
||||
var/datum/component/C = I
|
||||
if(!C.enabled)
|
||||
continue
|
||||
var/datum/callback/CB = C.signal_procs[sigtype]
|
||||
if(!CB)
|
||||
continue
|
||||
var/datum/callback/CB = C.signal_procs[src][sigtype]
|
||||
. |= CB.InvokeAsync(arglist(arguments))
|
||||
|
||||
/datum/proc/GetComponent(c_type)
|
||||
|
||||
@@ -15,9 +15,9 @@
|
||||
archdrops[i][ARCH_PROB] = 100
|
||||
stack_trace("ARCHAEOLOGY WARNING: [parent] contained a null probability value in [i].")
|
||||
callback = _callback
|
||||
RegisterSignal(COMSIG_PARENT_ATTACKBY,.proc/Dig)
|
||||
RegisterSignal(COMSIG_ATOM_EX_ACT, .proc/BombDig)
|
||||
RegisterSignal(COMSIG_ATOM_SING_PULL, .proc/SingDig)
|
||||
RegisterSignal(parent, COMSIG_PARENT_ATTACKBY,.proc/Dig)
|
||||
RegisterSignal(parent, COMSIG_ATOM_EX_ACT, .proc/BombDig)
|
||||
RegisterSignal(parent, COMSIG_ATOM_SING_PULL, .proc/SingDig)
|
||||
|
||||
/datum/component/archaeology/InheritComponent(datum/component/archaeology/A, i_am_original)
|
||||
var/list/other_archdrops = A.archdrops
|
||||
|
||||
@@ -9,9 +9,9 @@
|
||||
if(!isobj(parent))
|
||||
return COMPONENT_INCOMPATIBLE
|
||||
|
||||
RegisterSignal(COMSIG_PARENT_EXAMINE, .proc/examine)
|
||||
RegisterSignal(COMSIG_PARENT_ATTACKBY, .proc/applyplate)
|
||||
RegisterSignal(COMSIG_PARENT_PREQDELETED, .proc/dropplates)
|
||||
RegisterSignal(parent, COMSIG_PARENT_EXAMINE, .proc/examine)
|
||||
RegisterSignal(parent, COMSIG_PARENT_ATTACKBY, .proc/applyplate)
|
||||
RegisterSignal(parent, COMSIG_PARENT_PREQDELETED, .proc/dropplates)
|
||||
|
||||
if(_maxamount)
|
||||
maxamount = _maxamount
|
||||
|
||||
@@ -5,8 +5,8 @@
|
||||
if(!ismovableatom(parent))
|
||||
return COMPONENT_INCOMPATIBLE
|
||||
beauty = beautyamount
|
||||
RegisterSignal(COMSIG_ENTER_AREA, .proc/enter_area)
|
||||
RegisterSignal(COMSIG_EXIT_AREA, .proc/exit_area)
|
||||
RegisterSignal(parent, COMSIG_ENTER_AREA, .proc/enter_area)
|
||||
RegisterSignal(parent, COMSIG_EXIT_AREA, .proc/exit_area)
|
||||
var/area/A = get_area(parent)
|
||||
if(!A || A.outdoors)
|
||||
return
|
||||
|
||||
@@ -12,7 +12,7 @@
|
||||
probability = _probability
|
||||
flags = _flags
|
||||
|
||||
RegisterSignal(list(COMSIG_MOVABLE_CROSSED), .proc/Crossed)
|
||||
RegisterSignal(parent, list(COMSIG_MOVABLE_CROSSED), .proc/Crossed)
|
||||
|
||||
/datum/component/caltrop/proc/Crossed(atom/movable/AM)
|
||||
var/atom/A = parent
|
||||
|
||||
@@ -23,7 +23,7 @@
|
||||
))
|
||||
|
||||
/datum/component/chasm/Initialize(turf/target)
|
||||
RegisterSignal(list(COMSIG_MOVABLE_CROSSED, COMSIG_ATOM_ENTERED), .proc/Entered)
|
||||
RegisterSignal(parent, list(COMSIG_MOVABLE_CROSSED, COMSIG_ATOM_ENTERED), .proc/Entered)
|
||||
target_turf = target
|
||||
START_PROCESSING(SSobj, src) // process on create, in case stuff is still there
|
||||
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
/datum/component/cleaning/Initialize()
|
||||
if(!ismovableatom(parent))
|
||||
return COMPONENT_INCOMPATIBLE
|
||||
RegisterSignal(list(COMSIG_MOVABLE_MOVED), .proc/Clean)
|
||||
RegisterSignal(parent, list(COMSIG_MOVABLE_MOVED), .proc/Clean)
|
||||
|
||||
/datum/component/cleaning/proc/Clean()
|
||||
var/atom/movable/AM = parent
|
||||
|
||||
@@ -15,8 +15,8 @@
|
||||
if(!isatom(parent))
|
||||
return COMPONENT_INCOMPATIBLE
|
||||
|
||||
RegisterSignal(COMSIG_PARENT_EXAMINE, .proc/examine)
|
||||
RegisterSignal(COMSIG_PARENT_ATTACKBY,.proc/action)
|
||||
RegisterSignal(parent, COMSIG_PARENT_EXAMINE, .proc/examine)
|
||||
RegisterSignal(parent, COMSIG_PARENT_ATTACKBY,.proc/action)
|
||||
update_parent(index)
|
||||
|
||||
/datum/component/construction/proc/examine(mob/user)
|
||||
|
||||
@@ -12,11 +12,11 @@
|
||||
cleanable = _cleanable
|
||||
|
||||
if(_dir) // If no dir is assigned at start then it follows the atom's dir
|
||||
RegisterSignal(COMSIG_ATOM_DIR_CHANGE, .proc/rotate_react)
|
||||
RegisterSignal(parent, COMSIG_ATOM_DIR_CHANGE, .proc/rotate_react)
|
||||
if(_cleanable)
|
||||
RegisterSignal(COMSIG_COMPONENT_CLEAN_ACT, .proc/clean_react)
|
||||
RegisterSignal(parent, COMSIG_COMPONENT_CLEAN_ACT, .proc/clean_react)
|
||||
if(_description)
|
||||
RegisterSignal(COMSIG_PARENT_EXAMINE, .proc/examine)
|
||||
RegisterSignal(parent, COMSIG_PARENT_EXAMINE, .proc/examine)
|
||||
apply()
|
||||
|
||||
/datum/component/decal/Destroy()
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
if(!isitem(parent))
|
||||
return COMPONENT_INCOMPATIBLE
|
||||
. = ..()
|
||||
RegisterSignal(COMSIG_ATOM_GET_EXAMINE_NAME, .proc/get_examine_name)
|
||||
RegisterSignal(parent, COMSIG_ATOM_GET_EXAMINE_NAME, .proc/get_examine_name)
|
||||
|
||||
/datum/component/decal/blood/generate_appearance(_icon, _icon_state, _dir, _layer, _color)
|
||||
var/obj/item/I = parent
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
/datum/component/earhealing/Initialize()
|
||||
if(!isitem(parent))
|
||||
return COMPONENT_INCOMPATIBLE
|
||||
RegisterSignal(list(COMSIG_ITEM_EQUIPPED, COMSIG_ITEM_DROPPED), .proc/equippedChanged)
|
||||
RegisterSignal(parent, list(COMSIG_ITEM_EQUIPPED, COMSIG_ITEM_DROPPED), .proc/equippedChanged)
|
||||
|
||||
/datum/component/earhealing/proc/equippedChanged(mob/living/carbon/user, slot)
|
||||
if (slot == SLOT_EARS && istype(user))
|
||||
|
||||
@@ -16,7 +16,7 @@
|
||||
)
|
||||
say_lines = text || default_lines
|
||||
|
||||
RegisterSignal(COMSIG_GLOB_VAR_EDIT, .proc/var_edit_react)
|
||||
RegisterSignal(SSdcs, COMSIG_GLOB_VAR_EDIT, .proc/var_edit_react)
|
||||
|
||||
/datum/component/edit_complainer/proc/var_edit_react(list/arguments)
|
||||
var/atom/movable/master = parent
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
if(!istype(parent, /atom))
|
||||
return COMPONENT_INCOMPATIBLE
|
||||
flags = _flags
|
||||
RegisterSignal(list(COMSIG_ATOM_EMP_ACT), .proc/getEmpFlags)
|
||||
RegisterSignal(parent, list(COMSIG_ATOM_EMP_ACT), .proc/getEmpFlags)
|
||||
|
||||
/datum/component/empprotection/proc/getEmpFlags(severity)
|
||||
return flags
|
||||
|
||||
@@ -21,7 +21,7 @@
|
||||
blood_DNA = new_blood_DNA
|
||||
fibers = new_fibers
|
||||
check_blood()
|
||||
RegisterSignal(COMSIG_COMPONENT_CLEAN_ACT, .proc/clean_act)
|
||||
RegisterSignal(parent, COMSIG_COMPONENT_CLEAN_ACT, .proc/clean_act)
|
||||
|
||||
/datum/component/forensics/proc/wipe_fingerprints()
|
||||
fingerprints = null
|
||||
|
||||
@@ -12,15 +12,15 @@
|
||||
if(expire_in)
|
||||
expire_time = world.time + expire_in
|
||||
QDEL_IN(src, expire_in)
|
||||
RegisterSignal(COMSIG_MOVABLE_BUCKLE, .proc/try_infect_buckle)
|
||||
RegisterSignal(COMSIG_MOVABLE_COLLIDE, .proc/try_infect_collide)
|
||||
RegisterSignal(COMSIG_MOVABLE_CROSSED, .proc/try_infect_crossed)
|
||||
RegisterSignal(COMSIG_ITEM_ATTACK_ZONE, .proc/try_infect_attack_zone)
|
||||
RegisterSignal(COMSIG_ITEM_ATTACK, .proc/try_infect_attack)
|
||||
RegisterSignal(COMSIG_ITEM_EQUIPPED, .proc/try_infect_equipped)
|
||||
RegisterSignal(COMSIG_MOVABLE_IMPACT_ZONE, .proc/try_infect_impact_zone)
|
||||
RegisterSignal(COMSIG_FOOD_EATEN, .proc/try_infect_eat)
|
||||
RegisterSignal(COMSIG_COMPONENT_CLEAN_ACT, .proc/clean)
|
||||
RegisterSignal(parent, COMSIG_MOVABLE_BUCKLE, .proc/try_infect_buckle)
|
||||
RegisterSignal(parent, COMSIG_MOVABLE_COLLIDE, .proc/try_infect_collide)
|
||||
RegisterSignal(parent, COMSIG_MOVABLE_CROSSED, .proc/try_infect_crossed)
|
||||
RegisterSignal(parent, COMSIG_ITEM_ATTACK_ZONE, .proc/try_infect_attack_zone)
|
||||
RegisterSignal(parent, COMSIG_ITEM_ATTACK, .proc/try_infect_attack)
|
||||
RegisterSignal(parent, COMSIG_ITEM_EQUIPPED, .proc/try_infect_equipped)
|
||||
RegisterSignal(parent, COMSIG_MOVABLE_IMPACT_ZONE, .proc/try_infect_impact_zone)
|
||||
RegisterSignal(parent, COMSIG_FOOD_EATEN, .proc/try_infect_eat)
|
||||
RegisterSignal(parent, COMSIG_COMPONENT_CLEAN_ACT, .proc/clean)
|
||||
|
||||
/datum/component/infective/proc/try_infect_eat(mob/living/eater, mob/living/feeder)
|
||||
for(var/V in diseases)
|
||||
|
||||
@@ -13,31 +13,21 @@
|
||||
var/requires_mob_riding = TRUE //whether this only works if the attacker is riding a mob, rather than anything they can buckle to.
|
||||
var/requires_mount = TRUE //kinda defeats the point of jousting if you're not mounted but whatever.
|
||||
var/mob/current_holder
|
||||
var/datum/component/redirect/listener
|
||||
var/current_timerid
|
||||
|
||||
/datum/component/jousting/Initialize()
|
||||
if(!isitem(parent))
|
||||
return COMPONENT_INCOMPATIBLE
|
||||
RegisterSignal(COMSIG_ITEM_EQUIPPED, .proc/on_equip)
|
||||
RegisterSignal(COMSIG_ITEM_DROPPED, .proc/on_drop)
|
||||
RegisterSignal(COMSIG_ITEM_ATTACK, .proc/on_attack)
|
||||
|
||||
/datum/component/jousting/Destroy()
|
||||
QDEL_NULL(listener)
|
||||
return ..()
|
||||
RegisterSignal(parent, COMSIG_ITEM_EQUIPPED, .proc/on_equip)
|
||||
RegisterSignal(parent, COMSIG_ITEM_DROPPED, .proc/on_drop)
|
||||
RegisterSignal(parent, COMSIG_ITEM_ATTACK, .proc/on_attack)
|
||||
|
||||
/datum/component/jousting/proc/on_equip(mob/user, slot)
|
||||
RegisterSignal(user, COMSIG_MOVABLE_MOVED, .proc/mob_move, TRUE)
|
||||
current_holder = user
|
||||
if(!listener)
|
||||
listener = user.AddComponent(/datum/component/redirect, COMSIG_MOVABLE_MOVED, CALLBACK(src, .proc/mob_move))
|
||||
else
|
||||
user.TakeComponent(listener)
|
||||
if(QDELING(listener))
|
||||
listener = null
|
||||
|
||||
/datum/component/jousting/proc/on_drop(mob/user)
|
||||
QDEL_NULL(listener)
|
||||
UnregisterSignal(user, COMSIG_MOVABLE_MOVED)
|
||||
current_holder = null
|
||||
current_direction = NONE
|
||||
current_tile_charge = 0
|
||||
|
||||
@@ -8,8 +8,8 @@
|
||||
/datum/component/knockoff/Initialize(knockoff_chance,zone_override,slots_knockoffable)
|
||||
if(!isitem(parent))
|
||||
return COMPONENT_INCOMPATIBLE
|
||||
RegisterSignal(COMSIG_ITEM_EQUIPPED,.proc/OnEquipped)
|
||||
RegisterSignal(COMSIG_ITEM_DROPPED,.proc/OnDropped)
|
||||
RegisterSignal(parent, COMSIG_ITEM_EQUIPPED,.proc/OnEquipped)
|
||||
RegisterSignal(parent, COMSIG_ITEM_DROPPED,.proc/OnDropped)
|
||||
|
||||
src.knockoff_chance = knockoff_chance
|
||||
|
||||
@@ -37,16 +37,9 @@
|
||||
if(!istype(H))
|
||||
return
|
||||
if(slots_knockoffable && !(slot in slots_knockoffable))
|
||||
if(disarm_redirect)
|
||||
QDEL_NULL(disarm_redirect)
|
||||
UnregisterSignal(H, COMSIG_HUMAN_DISARM_HIT)
|
||||
return
|
||||
if(!disarm_redirect)
|
||||
disarm_redirect = H.AddComponent(/datum/component/redirect,list(COMSIG_HUMAN_DISARM_HIT),CALLBACK(src,.proc/Knockoff))
|
||||
RegisterSignal(H, COMSIG_HUMAN_DISARM_HIT, .proc/Knockoff, TRUE)
|
||||
|
||||
/datum/component/knockoff/proc/OnDropped(mob/living/M)
|
||||
if(disarm_redirect)
|
||||
QDEL_NULL(disarm_redirect)
|
||||
|
||||
/datum/component/knockoff/Destroy()
|
||||
QDEL_NULL(disarm_redirect)
|
||||
. = ..()
|
||||
UnregisterSignal(M, COMSIG_HUMAN_DISARM_HIT)
|
||||
23
code/datums/components/magnetic_catch.dm
Normal file
23
code/datums/components/magnetic_catch.dm
Normal file
@@ -0,0 +1,23 @@
|
||||
/datum/component/magnetic_catch/Initialize()
|
||||
if(!isatom(parent))
|
||||
return COMPONENT_INCOMPATIBLE
|
||||
if(ismovableatom(parent))
|
||||
RegisterSignal(parent, COMSIG_MOVABLE_UNCROSS, .proc/uncross_react)
|
||||
else
|
||||
RegisterSignal(parent, COMSIG_ATOM_EXIT, .proc/exit_react)
|
||||
RegisterSignal(parent, COMSIG_PARENT_EXAMINE, .proc/examine)
|
||||
|
||||
/datum/component/magnetic_catch/proc/uncross_react(atom/movable/thing)
|
||||
if(!thing.throwing || thing.throwing.thrower)
|
||||
return
|
||||
qdel(thing.throwing)
|
||||
return COMPONENT_MOVABLE_BLOCK_UNCROSS
|
||||
|
||||
/datum/component/magnetic_catch/proc/exit_react(atom/movable/thing, atom/newloc)
|
||||
if(!thing.throwing || thing.throwing.thrower)
|
||||
return
|
||||
qdel(thing.throwing)
|
||||
return COMPONENT_ATOM_BLOCK_EXIT
|
||||
|
||||
/datum/component/magnetic_catch/proc/examine(mob/user)
|
||||
to_chat(user, "It has been installed with inertia dampening to prevent coffee spills.")
|
||||
@@ -32,8 +32,8 @@
|
||||
precondition = _precondition
|
||||
after_insert = _after_insert
|
||||
|
||||
RegisterSignal(COMSIG_PARENT_ATTACKBY, .proc/OnAttackBy)
|
||||
RegisterSignal(COMSIG_PARENT_EXAMINE, .proc/OnExamine)
|
||||
RegisterSignal(parent, COMSIG_PARENT_ATTACKBY, .proc/OnAttackBy)
|
||||
RegisterSignal(parent, COMSIG_PARENT_EXAMINE, .proc/OnExamine)
|
||||
|
||||
var/list/possible_mats = list()
|
||||
for(var/mat_type in subtypesof(/datum/material))
|
||||
|
||||
@@ -14,9 +14,9 @@
|
||||
START_PROCESSING(SSmood, src)
|
||||
owner = parent
|
||||
soundloop = new(list(owner), FALSE, TRUE)
|
||||
RegisterSignal(COMSIG_ADD_MOOD_EVENT, .proc/add_event)
|
||||
RegisterSignal(COMSIG_CLEAR_MOOD_EVENT, .proc/clear_event)
|
||||
RegisterSignal(COMSIG_ENTER_AREA, .proc/update_beauty)
|
||||
RegisterSignal(parent, COMSIG_ADD_MOOD_EVENT, .proc/add_event)
|
||||
RegisterSignal(parent, COMSIG_CLEAR_MOOD_EVENT, .proc/clear_event)
|
||||
RegisterSignal(parent, COMSIG_ENTER_AREA, .proc/update_beauty)
|
||||
|
||||
/datum/component/mood/Destroy()
|
||||
STOP_PROCESSING(SSmood, src)
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
var/current_paint
|
||||
|
||||
/datum/component/spraycan_paintable/Initialize()
|
||||
RegisterSignal(COMSIG_PARENT_ATTACKBY, .proc/Repaint)
|
||||
RegisterSignal(parent, COMSIG_PARENT_ATTACKBY, .proc/Repaint)
|
||||
|
||||
/datum/component/spraycan_paintable/Destroy()
|
||||
RemoveCurrentCoat()
|
||||
|
||||
@@ -19,10 +19,10 @@
|
||||
can_contaminate = _can_contaminate
|
||||
|
||||
if(istype(parent, /atom))
|
||||
RegisterSignal(COMSIG_PARENT_EXAMINE, .proc/rad_examine)
|
||||
RegisterSignal(parent, COMSIG_PARENT_EXAMINE, .proc/rad_examine)
|
||||
if(istype(parent, /obj/item))
|
||||
RegisterSignal(COMSIG_ITEM_ATTACK, .proc/rad_attack)
|
||||
RegisterSignal(COMSIG_ITEM_ATTACK_OBJ, .proc/rad_attack)
|
||||
RegisterSignal(parent, COMSIG_ITEM_ATTACK, .proc/rad_attack)
|
||||
RegisterSignal(parent, COMSIG_ITEM_ATTACK_OBJ, .proc/rad_attack)
|
||||
else
|
||||
CRASH("Something that wasn't an atom was given /datum/component/radioactive")
|
||||
return
|
||||
|
||||
@@ -22,9 +22,9 @@
|
||||
/datum/component/riding/Initialize()
|
||||
if(!ismovableatom(parent))
|
||||
return COMPONENT_INCOMPATIBLE
|
||||
RegisterSignal(COMSIG_MOVABLE_BUCKLE, .proc/vehicle_mob_buckle)
|
||||
RegisterSignal(COMSIG_MOVABLE_UNBUCKLE, .proc/vehicle_mob_unbuckle)
|
||||
RegisterSignal(COMSIG_MOVABLE_MOVED, .proc/vehicle_moved)
|
||||
RegisterSignal(parent, COMSIG_MOVABLE_BUCKLE, .proc/vehicle_mob_buckle)
|
||||
RegisterSignal(parent, COMSIG_MOVABLE_UNBUCKLE, .proc/vehicle_mob_unbuckle)
|
||||
RegisterSignal(parent, COMSIG_MOVABLE_MOVED, .proc/vehicle_moved)
|
||||
|
||||
/datum/component/riding/proc/vehicle_mob_unbuckle(mob/living/M, force = FALSE)
|
||||
restore_position(M)
|
||||
@@ -193,7 +193,7 @@
|
||||
|
||||
/datum/component/riding/human/Initialize()
|
||||
. = ..()
|
||||
RegisterSignal(COMSIG_HUMAN_MELEE_UNARMED_ATTACK, .proc/on_host_unarmed_melee)
|
||||
RegisterSignal(parent, COMSIG_HUMAN_MELEE_UNARMED_ATTACK, .proc/on_host_unarmed_melee)
|
||||
|
||||
/datum/component/riding/human/proc/on_host_unarmed_melee(atom/target)
|
||||
var/mob/living/carbon/human/AM = parent
|
||||
|
||||
@@ -45,10 +45,10 @@
|
||||
default_rotation_direction = ROTATION_CLOCKWISE
|
||||
|
||||
if(src.rotation_flags & ROTATION_ALTCLICK)
|
||||
RegisterSignal(COMSIG_CLICK_ALT, .proc/HandRot)
|
||||
RegisterSignal(COMSIG_PARENT_EXAMINE, .proc/ExamineMessage)
|
||||
RegisterSignal(parent, COMSIG_CLICK_ALT, .proc/HandRot)
|
||||
RegisterSignal(parent, COMSIG_PARENT_EXAMINE, .proc/ExamineMessage)
|
||||
if(src.rotation_flags & ROTATION_WRENCH)
|
||||
RegisterSignal(COMSIG_PARENT_ATTACKBY, .proc/WrenchRot)
|
||||
RegisterSignal(parent, COMSIG_PARENT_ATTACKBY, .proc/WrenchRot)
|
||||
|
||||
if(src.rotation_flags & ROTATION_VERBS)
|
||||
var/atom/movable/AM = parent
|
||||
|
||||
@@ -1,3 +1,6 @@
|
||||
// This should only be used by non components trying to listen to a signal
|
||||
// If you use this inside a component I will replace your eyes with lemons ~ninjanomnom
|
||||
|
||||
/datum/component/redirect
|
||||
dupe_mode = COMPONENT_DUPE_ALLOWED
|
||||
|
||||
@@ -7,8 +10,8 @@
|
||||
warning("signals are [list2params(signals)], callback is [_callback]]")
|
||||
return COMPONENT_INCOMPATIBLE
|
||||
if(flags & REDIRECT_TRANSFER_WITH_TURF && isturf(parent))
|
||||
RegisterSignal(COMSIG_TURF_CHANGE, .proc/turf_change)
|
||||
RegisterSignal(signals, _callback)
|
||||
RegisterSignal(parent, COMSIG_TURF_CHANGE, .proc/turf_change)
|
||||
RegisterSignal(parent, signals, _callback)
|
||||
|
||||
/datum/component/redirect/proc/turf_change(path, new_baseturfs, flags, list/transfers)
|
||||
transfers += src
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
intensity = max(_intensity, 0)
|
||||
lube_flags = _lube_flags
|
||||
callback = _callback
|
||||
RegisterSignal(list(COMSIG_MOVABLE_CROSSED, COMSIG_ATOM_ENTERED), .proc/Slip)
|
||||
RegisterSignal(parent, list(COMSIG_MOVABLE_CROSSED, COMSIG_ATOM_ENTERED), .proc/Slip)
|
||||
|
||||
/datum/component/slippery/proc/Slip(atom/movable/AM)
|
||||
var/mob/victim = AM
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
var/too_spooky = TRUE //will it spawn a new instrument?
|
||||
|
||||
/datum/component/spooky/Initialize()
|
||||
RegisterSignal(COMSIG_ITEM_ATTACK, .proc/spectral_attack)
|
||||
RegisterSignal(parent, COMSIG_ITEM_ATTACK, .proc/spectral_attack)
|
||||
|
||||
/datum/component/spooky/proc/spectral_attack(mob/living/carbon/C, mob/user)
|
||||
if(ishuman(user)) //this weapon wasn't meant for mortals.
|
||||
|
||||
@@ -24,10 +24,10 @@
|
||||
if(use_delay_override)
|
||||
use_delay = use_delay_override
|
||||
|
||||
RegisterSignal(list(COMSIG_ATOM_ENTERED, COMSIG_ATOM_BLOB_ACT, COMSIG_ATOM_HULK_ATTACK, COMSIG_PARENT_ATTACKBY, COMSIG_MOVABLE_COLLIDE, COMSIG_MOVABLE_IMPACT, COMSIG_ITEM_ATTACK, COMSIG_ITEM_ATTACK_OBJ), .proc/play_squeak)
|
||||
RegisterSignal(COMSIG_MOVABLE_CROSSED, .proc/play_squeak_turf)
|
||||
RegisterSignal(COMSIG_ITEM_ATTACK_SELF, .proc/use_squeak)
|
||||
RegisterSignal(COMSIG_SHOES_STEP_ACTION, .proc/step_squeak)
|
||||
RegisterSignal(parent, list(COMSIG_ATOM_ENTERED, COMSIG_ATOM_BLOB_ACT, COMSIG_ATOM_HULK_ATTACK, COMSIG_PARENT_ATTACKBY, COMSIG_MOVABLE_COLLIDE, COMSIG_MOVABLE_IMPACT, COMSIG_ITEM_ATTACK, COMSIG_ITEM_ATTACK_OBJ), .proc/play_squeak)
|
||||
RegisterSignal(parent, COMSIG_MOVABLE_CROSSED, .proc/play_squeak_turf)
|
||||
RegisterSignal(parent, COMSIG_ITEM_ATTACK_SELF, .proc/use_squeak)
|
||||
RegisterSignal(parent, COMSIG_SHOES_STEP_ACTION, .proc/step_squeak)
|
||||
|
||||
/datum/component/squeak/proc/play_squeak()
|
||||
if(prob(squeak_chance))
|
||||
|
||||
@@ -7,9 +7,9 @@
|
||||
/datum/component/stationloving/Initialize(inform_admins = FALSE, allow_death = FALSE)
|
||||
if(!ismovableatom(parent))
|
||||
return COMPONENT_INCOMPATIBLE
|
||||
RegisterSignal(list(COMSIG_MOVABLE_Z_CHANGED), .proc/check_in_bounds)
|
||||
RegisterSignal(list(COMSIG_PARENT_PREQDELETED), .proc/check_deletion)
|
||||
RegisterSignal(list(COMSIG_ITEM_IMBUE_SOUL), .proc/check_soul_imbue)
|
||||
RegisterSignal(parent, list(COMSIG_MOVABLE_Z_CHANGED), .proc/check_in_bounds)
|
||||
RegisterSignal(parent, list(COMSIG_PARENT_PREQDELETED), .proc/check_deletion)
|
||||
RegisterSignal(parent, list(COMSIG_ITEM_IMBUE_SOUL), .proc/check_soul_imbue)
|
||||
src.inform_admins = inform_admins
|
||||
src.allow_death = allow_death
|
||||
check_in_bounds() // Just in case something is being created outside of station/centcom
|
||||
|
||||
@@ -14,8 +14,8 @@
|
||||
|
||||
/datum/component/storage/concrete/Initialize()
|
||||
. = ..()
|
||||
RegisterSignal(COMSIG_ATOM_CONTENTS_DEL, .proc/on_contents_del)
|
||||
RegisterSignal(COMSIG_OBJ_DECONSTRUCT, .proc/on_deconstruct)
|
||||
RegisterSignal(parent, COMSIG_ATOM_CONTENTS_DEL, .proc/on_contents_del)
|
||||
RegisterSignal(parent, COMSIG_OBJ_DECONSTRUCT, .proc/on_deconstruct)
|
||||
|
||||
/datum/component/storage/concrete/Destroy()
|
||||
var/atom/real_location = real_location()
|
||||
|
||||
@@ -14,6 +14,7 @@
|
||||
to_chat(user, "<span class='danger'>The Bluespace interfaces of the two devices catastrophically malfunction!</span>")
|
||||
qdel(W)
|
||||
playsound(loccheck,'sound/effects/supermatter.ogg', 200, 1)
|
||||
user.gib(TRUE, TRUE, TRUE)
|
||||
for(var/turf/T in range(6,loccheck))
|
||||
if(istype(T, /turf/open/space/transit))
|
||||
continue
|
||||
|
||||
@@ -67,38 +67,38 @@
|
||||
closer = new(null, src)
|
||||
orient2hud()
|
||||
|
||||
RegisterSignal(COMSIG_CONTAINS_STORAGE, .proc/on_check)
|
||||
RegisterSignal(COMSIG_IS_STORAGE_LOCKED, .proc/check_locked)
|
||||
RegisterSignal(COMSIG_TRY_STORAGE_SHOW, .proc/signal_show_attempt)
|
||||
RegisterSignal(COMSIG_TRY_STORAGE_INSERT, .proc/signal_insertion_attempt)
|
||||
RegisterSignal(COMSIG_TRY_STORAGE_CAN_INSERT, .proc/signal_can_insert)
|
||||
RegisterSignal(COMSIG_TRY_STORAGE_TAKE_TYPE, .proc/signal_take_type)
|
||||
RegisterSignal(COMSIG_TRY_STORAGE_FILL_TYPE, .proc/signal_fill_type)
|
||||
RegisterSignal(COMSIG_TRY_STORAGE_SET_LOCKSTATE, .proc/set_locked)
|
||||
RegisterSignal(COMSIG_TRY_STORAGE_TAKE, .proc/signal_take_obj)
|
||||
RegisterSignal(COMSIG_TRY_STORAGE_QUICK_EMPTY, .proc/signal_quick_empty)
|
||||
RegisterSignal(COMSIG_TRY_STORAGE_HIDE_FROM, .proc/signal_hide_attempt)
|
||||
RegisterSignal(COMSIG_TRY_STORAGE_HIDE_ALL, .proc/close_all)
|
||||
RegisterSignal(COMSIG_TRY_STORAGE_RETURN_INVENTORY, .proc/signal_return_inv)
|
||||
RegisterSignal(parent, COMSIG_CONTAINS_STORAGE, .proc/on_check)
|
||||
RegisterSignal(parent, COMSIG_IS_STORAGE_LOCKED, .proc/check_locked)
|
||||
RegisterSignal(parent, COMSIG_TRY_STORAGE_SHOW, .proc/signal_show_attempt)
|
||||
RegisterSignal(parent, COMSIG_TRY_STORAGE_INSERT, .proc/signal_insertion_attempt)
|
||||
RegisterSignal(parent, COMSIG_TRY_STORAGE_CAN_INSERT, .proc/signal_can_insert)
|
||||
RegisterSignal(parent, COMSIG_TRY_STORAGE_TAKE_TYPE, .proc/signal_take_type)
|
||||
RegisterSignal(parent, COMSIG_TRY_STORAGE_FILL_TYPE, .proc/signal_fill_type)
|
||||
RegisterSignal(parent, COMSIG_TRY_STORAGE_SET_LOCKSTATE, .proc/set_locked)
|
||||
RegisterSignal(parent, COMSIG_TRY_STORAGE_TAKE, .proc/signal_take_obj)
|
||||
RegisterSignal(parent, COMSIG_TRY_STORAGE_QUICK_EMPTY, .proc/signal_quick_empty)
|
||||
RegisterSignal(parent, COMSIG_TRY_STORAGE_HIDE_FROM, .proc/signal_hide_attempt)
|
||||
RegisterSignal(parent, COMSIG_TRY_STORAGE_HIDE_ALL, .proc/close_all)
|
||||
RegisterSignal(parent, COMSIG_TRY_STORAGE_RETURN_INVENTORY, .proc/signal_return_inv)
|
||||
|
||||
RegisterSignal(COMSIG_PARENT_ATTACKBY, .proc/attackby)
|
||||
RegisterSignal(parent, COMSIG_PARENT_ATTACKBY, .proc/attackby)
|
||||
|
||||
RegisterSignal(COMSIG_ATOM_ATTACK_HAND, .proc/on_attack_hand)
|
||||
RegisterSignal(COMSIG_ATOM_ATTACK_PAW, .proc/on_attack_hand)
|
||||
RegisterSignal(COMSIG_ATOM_EMP_ACT, .proc/emp_act)
|
||||
RegisterSignal(COMSIG_ATOM_ATTACK_GHOST, .proc/show_to_ghost)
|
||||
RegisterSignal(COMSIG_ATOM_ENTERED, .proc/refresh_mob_views)
|
||||
RegisterSignal(COMSIG_ATOM_EXITED, .proc/_remove_and_refresh)
|
||||
RegisterSignal(parent, COMSIG_ATOM_ATTACK_HAND, .proc/on_attack_hand)
|
||||
RegisterSignal(parent, COMSIG_ATOM_ATTACK_PAW, .proc/on_attack_hand)
|
||||
RegisterSignal(parent, COMSIG_ATOM_EMP_ACT, .proc/emp_act)
|
||||
RegisterSignal(parent, COMSIG_ATOM_ATTACK_GHOST, .proc/show_to_ghost)
|
||||
RegisterSignal(parent, COMSIG_ATOM_ENTERED, .proc/refresh_mob_views)
|
||||
RegisterSignal(parent, COMSIG_ATOM_EXITED, .proc/_remove_and_refresh)
|
||||
|
||||
RegisterSignal(COMSIG_ITEM_PRE_ATTACK, .proc/preattack_intercept)
|
||||
RegisterSignal(COMSIG_ITEM_ATTACK_SELF, .proc/attack_self)
|
||||
RegisterSignal(COMSIG_ITEM_PICKUP, .proc/signal_on_pickup)
|
||||
RegisterSignal(parent, COMSIG_ITEM_PRE_ATTACK, .proc/preattack_intercept)
|
||||
RegisterSignal(parent, COMSIG_ITEM_ATTACK_SELF, .proc/attack_self)
|
||||
RegisterSignal(parent, COMSIG_ITEM_PICKUP, .proc/signal_on_pickup)
|
||||
|
||||
RegisterSignal(COMSIG_MOVABLE_THROW, .proc/close_all)
|
||||
RegisterSignal(parent, COMSIG_MOVABLE_THROW, .proc/close_all)
|
||||
|
||||
RegisterSignal(COMSIG_CLICK_ALT, .proc/on_alt_click)
|
||||
RegisterSignal(COMSIG_MOUSEDROP_ONTO, .proc/mousedrop_onto)
|
||||
RegisterSignal(COMSIG_MOUSEDROPPED_ONTO, .proc/mousedrop_receive)
|
||||
RegisterSignal(parent, COMSIG_CLICK_ALT, .proc/on_alt_click)
|
||||
RegisterSignal(parent, COMSIG_MOUSEDROP_ONTO, .proc/mousedrop_onto)
|
||||
RegisterSignal(parent, COMSIG_MOUSEDROPPED_ONTO, .proc/mousedrop_receive)
|
||||
|
||||
update_actions()
|
||||
|
||||
|
||||
@@ -8,8 +8,8 @@
|
||||
offset_x = rand(-max_x, max_x)
|
||||
offset_y = rand(-max_y, max_y)
|
||||
|
||||
RegisterSignal(COMSIG_MOVABLE_CROSSED, .proc/join_swarm)
|
||||
RegisterSignal(COMSIG_MOVABLE_UNCROSSED, .proc/leave_swarm)
|
||||
RegisterSignal(parent, COMSIG_MOVABLE_CROSSED, .proc/join_swarm)
|
||||
RegisterSignal(parent, COMSIG_MOVABLE_UNCROSSED, .proc/leave_swarm)
|
||||
|
||||
/datum/component/swarming/proc/join_swarm(atom/movable/AM)
|
||||
GET_COMPONENT_FROM(other_swarm, /datum/component/swarming, AM)
|
||||
|
||||
@@ -34,9 +34,9 @@
|
||||
overlay = mutable_appearance('icons/effects/effects.dmi', "thermite")
|
||||
master.add_overlay(overlay)
|
||||
|
||||
RegisterSignal(COMSIG_COMPONENT_CLEAN_ACT, .proc/clean_react)
|
||||
RegisterSignal(COMSIG_PARENT_ATTACKBY, .proc/attackby_react)
|
||||
RegisterSignal(COMSIG_ATOM_FIRE_ACT, .proc/flame_react)
|
||||
RegisterSignal(parent, COMSIG_COMPONENT_CLEAN_ACT, .proc/clean_react)
|
||||
RegisterSignal(parent, COMSIG_PARENT_ATTACKBY, .proc/attackby_react)
|
||||
RegisterSignal(parent, COMSIG_ATOM_FIRE_ACT, .proc/flame_react)
|
||||
|
||||
/datum/component/thermite/Destroy()
|
||||
var/turf/master = parent
|
||||
|
||||
@@ -26,19 +26,19 @@ GLOBAL_LIST_EMPTY(uplinks)
|
||||
if(!isitem(parent))
|
||||
return COMPONENT_INCOMPATIBLE
|
||||
|
||||
RegisterSignal(COMSIG_PARENT_ATTACKBY, .proc/OnAttackBy)
|
||||
RegisterSignal(COMSIG_ITEM_ATTACK_SELF, .proc/interact)
|
||||
RegisterSignal(parent, COMSIG_PARENT_ATTACKBY, .proc/OnAttackBy)
|
||||
RegisterSignal(parent, COMSIG_ITEM_ATTACK_SELF, .proc/interact)
|
||||
if(istype(parent, /obj/item/implant))
|
||||
RegisterSignal(COMSIG_IMPLANT_ACTIVATED, .proc/implant_activation)
|
||||
RegisterSignal(COMSIG_IMPLANT_IMPLANTING, .proc/implanting)
|
||||
RegisterSignal(COMSIG_IMPLANT_OTHER, .proc/old_implant)
|
||||
RegisterSignal(COMSIG_IMPLANT_EXISTING_UPLINK, .proc/new_implant)
|
||||
RegisterSignal(parent, COMSIG_IMPLANT_ACTIVATED, .proc/implant_activation)
|
||||
RegisterSignal(parent, COMSIG_IMPLANT_IMPLANTING, .proc/implanting)
|
||||
RegisterSignal(parent, COMSIG_IMPLANT_OTHER, .proc/old_implant)
|
||||
RegisterSignal(parent, COMSIG_IMPLANT_EXISTING_UPLINK, .proc/new_implant)
|
||||
else if(istype(parent, /obj/item/pda))
|
||||
RegisterSignal(COMSIG_PDA_CHANGE_RINGTONE, .proc/new_ringtone)
|
||||
RegisterSignal(parent, COMSIG_PDA_CHANGE_RINGTONE, .proc/new_ringtone)
|
||||
else if(istype(parent, /obj/item/radio))
|
||||
RegisterSignal(COMSIG_RADIO_NEW_FREQUENCY, .proc/new_frequency)
|
||||
RegisterSignal(parent, COMSIG_RADIO_NEW_FREQUENCY, .proc/new_frequency)
|
||||
else if(istype(parent, /obj/item/pen))
|
||||
RegisterSignal(COMSIG_PEN_ROTATED, .proc/pen_rotation)
|
||||
RegisterSignal(parent, COMSIG_PEN_ROTATED, .proc/pen_rotation)
|
||||
|
||||
GLOB.uplinks += src
|
||||
uplink_items = get_uplink_items(gamemode, TRUE, allow_restricted)
|
||||
|
||||
@@ -1,7 +1,6 @@
|
||||
// A dummy parent type used for easily making components that target an item's wearer rather than the item itself.
|
||||
|
||||
/datum/component/wearertargeting
|
||||
var/datum/component/mobhook
|
||||
var/list/valid_slots = list()
|
||||
var/list/signals = list()
|
||||
var/datum/callback/callback = CALLBACK(GLOBAL_PROC, .proc/pass)
|
||||
@@ -10,17 +9,14 @@
|
||||
/datum/component/wearertargeting/Initialize()
|
||||
if(!isitem(parent))
|
||||
return COMPONENT_INCOMPATIBLE
|
||||
RegisterSignal(list(COMSIG_ITEM_EQUIPPED, COMSIG_ITEM_DROPPED), .proc/checkMobHook)
|
||||
RegisterSignal(parent, COMSIG_ITEM_EQUIPPED, .proc/on_equip)
|
||||
RegisterSignal(parent, COMSIG_ITEM_DROPPED, .proc/on_drop)
|
||||
|
||||
/datum/component/wearertargeting/Destroy()
|
||||
QDEL_NULL(mobhook)
|
||||
return ..()
|
||||
|
||||
/datum/component/wearertargeting/proc/checkMobHook(mob/user, slot)
|
||||
if ((slot in valid_slots) && istype(user, mobtype))
|
||||
if (mobhook && mobhook.parent != user)
|
||||
QDEL_NULL(mobhook)
|
||||
if (!mobhook)
|
||||
mobhook = user.AddComponent(/datum/component/redirect, signals, callback)
|
||||
/datum/component/wearertargeting/proc/on_equip(mob/equipper, slot)
|
||||
if((slot in valid_slots) && istype(equipper, mobtype))
|
||||
RegisterSignal(equipper, signals, callback, TRUE)
|
||||
else
|
||||
QDEL_NULL(mobhook)
|
||||
UnregisterSignal(equipper, signals)
|
||||
|
||||
/datum/component/wearertargeting/proc/on_drop(mob/user)
|
||||
UnregisterSignal(user, signals)
|
||||
|
||||
@@ -26,8 +26,8 @@
|
||||
if(!isopenturf(parent))
|
||||
return COMPONENT_INCOMPATIBLE
|
||||
add_wet(strength, duration_minimum, duration_add, duration_maximum)
|
||||
RegisterSignal(COMSIG_TURF_IS_WET, .proc/is_wet)
|
||||
RegisterSignal(COMSIG_TURF_MAKE_DRY, .proc/dry)
|
||||
RegisterSignal(parent, COMSIG_TURF_IS_WET, .proc/is_wet)
|
||||
RegisterSignal(parent, COMSIG_TURF_MAKE_DRY, .proc/dry)
|
||||
permanent = _permanent
|
||||
if(!permanent)
|
||||
START_PROCESSING(SSwet_floors, src)
|
||||
|
||||
@@ -2,6 +2,7 @@
|
||||
var/gc_destroyed //Time when this object was destroyed.
|
||||
var/list/active_timers //for SStimer
|
||||
var/list/datum_components //for /datum/components
|
||||
var/list/comp_lookup //for /datum/components
|
||||
var/datum_flags = NONE
|
||||
var/datum/weakref/weak_reference
|
||||
|
||||
@@ -41,6 +42,19 @@
|
||||
qdel(C, FALSE, TRUE)
|
||||
dc.Cut()
|
||||
|
||||
var/list/lookup = comp_lookup
|
||||
if(lookup)
|
||||
for(var/sig in lookup)
|
||||
var/list/comps = lookup[sig]
|
||||
if(length(comps))
|
||||
for(var/i in comps)
|
||||
var/datum/component/comp = i
|
||||
comp.UnregisterSignal(src, sig)
|
||||
else
|
||||
var/datum/component/comp = comps
|
||||
comp.UnregisterSignal(src, sig)
|
||||
comp_lookup = lookup = null
|
||||
|
||||
return QDEL_HINT_QUEUE
|
||||
|
||||
#ifdef DATUMVAR_DEBUGGING_MODE
|
||||
|
||||
@@ -42,10 +42,8 @@
|
||||
|
||||
//add this disease if the host does not already have too many
|
||||
/datum/disease/proc/try_infect(var/mob/living/infectee, make_copy = TRUE)
|
||||
if(infectee.diseases.len < DISEASE_LIMIT)
|
||||
infect(infectee, make_copy)
|
||||
return TRUE
|
||||
return FALSE
|
||||
infect(infectee, make_copy)
|
||||
return TRUE
|
||||
|
||||
//add the disease with no checks
|
||||
/datum/disease/proc/infect(var/mob/living/infectee, make_copy = TRUE)
|
||||
|
||||
@@ -56,22 +56,20 @@
|
||||
return ..()
|
||||
|
||||
/datum/disease/advance/try_infect(var/mob/living/infectee, make_copy = TRUE)
|
||||
var/replace_num = infectee.diseases.len + 1 - DISEASE_LIMIT
|
||||
//see if we are more transmittable than enough diseases to replace them
|
||||
//diseases replaced in this way do not confer immunity
|
||||
var/list/advance_diseases = list()
|
||||
for(var/datum/disease/advance/P in infectee.diseases)
|
||||
advance_diseases += P
|
||||
var/replace_num = advance_diseases.len + 1 - DISEASE_LIMIT //amount of diseases that need to be removed to fit this one
|
||||
if(replace_num > 0)
|
||||
//see if we are more transmittable than enough diseases to replace them
|
||||
//diseases replaced in this way do not confer immunity
|
||||
var/list/L = list()
|
||||
for(var/datum/disease/advance/P in infectee.diseases)
|
||||
L += P
|
||||
sortTim(L, /proc/cmp_advdisease_resistance_asc)
|
||||
var/datum/disease/advance/competition = L[replace_num]
|
||||
if(totalTransmittable() > competition.totalResistance())
|
||||
for(var/i in 1 to replace_num)
|
||||
var/datum/disease/advance/A = L[replace_num]
|
||||
A.cure(FALSE)
|
||||
else
|
||||
//we are not strong enough to bully our way in
|
||||
return FALSE
|
||||
sortTim(advance_diseases, /proc/cmp_advdisease_resistance_asc)
|
||||
for(var/i in 1 to replace_num)
|
||||
var/datum/disease/advance/competition = advance_diseases[i]
|
||||
if(totalTransmittable() > competition.totalResistance())
|
||||
competition.cure(FALSE)
|
||||
else
|
||||
return FALSE //we are not strong enough to bully our way in
|
||||
infect(infectee, make_copy)
|
||||
return TRUE
|
||||
|
||||
|
||||
@@ -34,6 +34,16 @@
|
||||
if(length(place.baseturfs) < 2) // Some snowflake shuttle shit
|
||||
continue
|
||||
place.baseturfs.Insert(3, /turf/baseturf_skipover/shuttle)
|
||||
|
||||
for(var/obj/structure/closet/closet in place)
|
||||
if(closet.anchorable)
|
||||
closet.anchored = TRUE
|
||||
|
||||
for(var/obj/structure/table/table in place)
|
||||
table.AddComponent(/datum/component/magnetic_catch)
|
||||
|
||||
for(var/obj/structure/rack/rack in place)
|
||||
rack.AddComponent(/datum/component/magnetic_catch)
|
||||
|
||||
//Whatever special stuff you want
|
||||
/datum/map_template/shuttle/proc/on_bought()
|
||||
@@ -156,7 +166,7 @@
|
||||
suffix = "discoinferno"
|
||||
name = "Disco Inferno"
|
||||
description = "The glorious results of centuries of plasma research done by Nanotrasen employees. This is the reason why you are here. Get on and dance like you're on fire, burn baby burn!"
|
||||
admin_notes = "Flaming hot."
|
||||
admin_notes = "Flaming hot. The main area has a dance machine as well as plasma floor tiles that will be ignited by players every single time."
|
||||
credit_cost = 10000
|
||||
|
||||
/datum/map_template/shuttle/emergency/arena
|
||||
@@ -201,7 +211,7 @@
|
||||
Probably best if you don't rifle around in whatever equipment they were transporting. I hope you're friendly with your coworkers, because there is very little space in this thing.\n\
|
||||
\n\
|
||||
Contains contraband armory guns, maintenance loot, and abandoned crates!"
|
||||
admin_notes = "Due to origin as a solo piloted secure vessel, has an active GPS onboard labeled STV5."
|
||||
admin_notes = "Due to origin as a solo piloted secure vessel, has an active GPS onboard labeled STV5. Has roughly as much space as Hi Daniel, except with explosive crates."
|
||||
|
||||
/datum/map_template/shuttle/emergency/meta
|
||||
suffix = "meta"
|
||||
@@ -240,7 +250,9 @@
|
||||
suffix = "cere"
|
||||
name = "Cere Station Emergency Shuttle"
|
||||
description = "The large, beefed-up version of the box-standard shuttle. Includes an expanded brig, fully stocked medbay, enhanced cargo storage with mech chargers, \
|
||||
an engine room stocked with various supplies, and a crew capacity of 80+ to top it all off. Live large, live Cere."
|
||||
an engine room stocked with various supplies, and a crew capacity of 80+ to top it all off. Live large, live Cere."
|
||||
admin_notes = "Seriously big, even larger than the Delta shuttle."
|
||||
credit_cost = 10000
|
||||
|
||||
/datum/map_template/shuttle/emergency/supermatter
|
||||
suffix = "supermatter"
|
||||
@@ -260,6 +272,7 @@
|
||||
name = "Oh, Hi Daniel"
|
||||
description = "How was space work today? Oh, pretty good. We got a new space station and the company will make a lot of money. What space station? I cannot tell you; it's space confidential. \
|
||||
Aw, come space on. Why not? No, I can't. Anyway, how is your space roleplay life?"
|
||||
admin_notes = "Tiny, with a single airlock and wooden walls. What could go wrong?"
|
||||
credit_cost = -5000
|
||||
|
||||
/datum/map_template/shuttle/emergency/goon
|
||||
@@ -350,7 +363,7 @@
|
||||
suffix = "raven"
|
||||
name = "CentCom Raven Battlecruiser"
|
||||
description = "The CentCom Raven Battlecruiser is currently docked at the CentCom ship bay awaiting a mission, this Battlecruiser has been reassigned as an emergency escape shuttle for currently unknown reasons. The CentCom Raven Battlecruiser should comfortably fit a medium to large crew size crew and is complete with all required facitlities including a top of the range CentCom Medical Bay."
|
||||
admin_notes = "The long way home"
|
||||
admin_notes = "Comes with turrets that will target any simplemob."
|
||||
credit_cost = 12500
|
||||
|
||||
/datum/map_template/shuttle/arrival/box
|
||||
|
||||
@@ -414,7 +414,7 @@
|
||||
if(!prob(prb))
|
||||
return FALSE //you lucked out, no shock for you
|
||||
do_sparks(5, TRUE, src)
|
||||
var/tmp/check_range = TRUE
|
||||
var/check_range = TRUE
|
||||
if(electrocute_mob(user, get_area(src), src, 1, check_range))
|
||||
shockCooldown = world.time + 10
|
||||
return TRUE
|
||||
|
||||
@@ -479,6 +479,8 @@ For the other part of the code, check silicon say.dm. Particularly robot talk.*/
|
||||
continue
|
||||
if(another.validate_location(T))
|
||||
unset_holo(holo_owner)
|
||||
if(another.masters && another.masters[holo_owner])
|
||||
another.clear_holo(holo_owner)
|
||||
another.set_holo(holo_owner, h)
|
||||
return TRUE
|
||||
return FALSE
|
||||
|
||||
@@ -167,7 +167,7 @@
|
||||
else
|
||||
toggle_mode()
|
||||
|
||||
/obj/machinery/iv_drip/verb/eject_beaker(mob/user)
|
||||
/obj/machinery/iv_drip/verb/eject_beaker()
|
||||
set category = "Object"
|
||||
set name = "Remove IV Container"
|
||||
set src in view(1)
|
||||
|
||||
@@ -292,13 +292,13 @@ GLOBAL_VAR_INIT(rpg_loot_items, FALSE)
|
||||
if(throwing)
|
||||
throwing.finalize(FALSE)
|
||||
if(loc == user)
|
||||
if(!allow_attack_hand_drop(user) || !user.dropItemToGround(src))
|
||||
if(!allow_attack_hand_drop(user) || !user.temporarilyRemoveItemFromInventory(src))
|
||||
return
|
||||
|
||||
pickup(user)
|
||||
add_fingerprint(user)
|
||||
if(!user.put_in_active_hand(src))
|
||||
dropped(user)
|
||||
user.dropItemToGround(src)
|
||||
|
||||
/obj/item/proc/allow_attack_hand_drop(mob/user)
|
||||
return TRUE
|
||||
@@ -314,13 +314,13 @@ GLOBAL_VAR_INIT(rpg_loot_items, FALSE)
|
||||
if(throwing)
|
||||
throwing.finalize(FALSE)
|
||||
if(loc == user)
|
||||
if(!user.dropItemToGround(src))
|
||||
if(!user.temporarilyRemoveItemFromInventory(src))
|
||||
return
|
||||
|
||||
pickup(user)
|
||||
add_fingerprint(user)
|
||||
if(!user.put_in_active_hand(src))
|
||||
dropped(user)
|
||||
user.dropItemToGround(src)
|
||||
|
||||
/obj/item/attack_alien(mob/user)
|
||||
var/mob/living/carbon/alien/A = user
|
||||
|
||||
@@ -112,8 +112,7 @@
|
||||
|
||||
/obj/item/areaeditor/blueprints/proc/get_images(turf/T, viewsize)
|
||||
. = list()
|
||||
for(var/tt in RANGE_TURFS(viewsize, T))
|
||||
var/turf/TT = tt
|
||||
for(var/turf/TT in range(viewsize, T))
|
||||
if(TT.blueprint_data)
|
||||
. += TT.blueprint_data
|
||||
|
||||
|
||||
@@ -42,8 +42,8 @@
|
||||
sprite_name = "miniFE"
|
||||
dog_fashion = null
|
||||
|
||||
/obj/item/extinguisher/New()
|
||||
..()
|
||||
/obj/item/extinguisher/Initialize()
|
||||
. = ..()
|
||||
create_reagents(max_water)
|
||||
reagents.add_reagent(chem, max_water)
|
||||
|
||||
|
||||
@@ -62,6 +62,76 @@
|
||||
return 1
|
||||
return 0
|
||||
|
||||
/obj/item/robot_suit/wrench_act(mob/living/user, obj/item/I) //Deconstucts empty borg shell. Flashes remain unbroken because they haven't been used yet
|
||||
var/turf/T = get_turf(src)
|
||||
if(l_leg || r_leg || chest || l_arm || r_arm || head)
|
||||
if(I.use_tool(src, user, 5, volume=50))
|
||||
if(l_leg)
|
||||
l_leg.forceMove(T)
|
||||
l_leg = null
|
||||
if(r_leg)
|
||||
r_leg.forceMove(T)
|
||||
r_leg = null
|
||||
if(chest)
|
||||
if (chest.cell) //Sanity check.
|
||||
chest.cell.forceMove(T)
|
||||
chest.cell = null
|
||||
chest.forceMove(T)
|
||||
new /obj/item/stack/cable_coil(T, 1)
|
||||
chest.wired = FALSE
|
||||
chest = null
|
||||
if(l_arm)
|
||||
l_arm.forceMove(T)
|
||||
l_arm = null
|
||||
if(r_arm)
|
||||
r_arm.forceMove(T)
|
||||
r_arm = null
|
||||
if(head)
|
||||
head.forceMove(T)
|
||||
head.flash1.forceMove(T)
|
||||
head.flash1 = null
|
||||
head.flash2.forceMove(T)
|
||||
head.flash2 = null
|
||||
head = null
|
||||
to_chat(user, "<span class='notice'>You disassemble the cyborg shell.</span>")
|
||||
else
|
||||
to_chat(user, "<span class='notice'>There is nothing to remove from the endoskeleton.</span>")
|
||||
updateicon()
|
||||
|
||||
/obj/item/robot_suit/proc/put_in_hand_or_drop(mob/living/user, obj/item/I) //normal put_in_hands() drops the item ontop of the player, this drops it at the suit's loc
|
||||
if(!user.put_in_hands(I))
|
||||
I.forceMove(drop_location())
|
||||
return FALSE
|
||||
return TRUE
|
||||
|
||||
/obj/item/robot_suit/screwdriver_act(mob/living/user, obj/item/I) //Swaps the power cell if you're holding a new one in your other hand.
|
||||
if(!chest) //can't remove a cell if there's no chest to remove it from.
|
||||
to_chat(user, "<span class='notice'>[src] has no attached torso.</span>")
|
||||
return
|
||||
|
||||
var/obj/item/stock_parts/cell/temp_cell = user.is_holding_item_of_type(/obj/item/stock_parts/cell)
|
||||
var/swap_failed
|
||||
if(!temp_cell) //if we're not holding a cell
|
||||
swap_failed = TRUE
|
||||
else if(!user.transferItemToLoc(temp_cell, chest))
|
||||
swap_failed = TRUE
|
||||
to_chat(user, "<span class='warning'>[temp_cell] is stuck to your hand, you can't put it in [src]!</span>")
|
||||
|
||||
if(chest.cell) //drop the chest's current cell no matter what.
|
||||
put_in_hand_or_drop(user, chest.cell)
|
||||
|
||||
if(swap_failed) //we didn't transfer any new items.
|
||||
if(chest.cell) //old cell ejected, nothing inserted.
|
||||
to_chat(user, "<span class='notice'>You remove [chest.cell] from [src].</span>")
|
||||
chest.cell = null
|
||||
else
|
||||
to_chat(user, "<span class='notice'>The power cell slot in [src]'s torso is empty.</span>")
|
||||
return
|
||||
|
||||
to_chat(user, "<span class='notice'>You [chest.cell ? "replace [src]'s [chest.cell.name] with [temp_cell]" : "insert [temp_cell] into [src]"].</span>")
|
||||
chest.cell = temp_cell
|
||||
return TRUE
|
||||
|
||||
/obj/item/robot_suit/attackby(obj/item/W, mob/user, params)
|
||||
|
||||
if(istype(W, /obj/item/stack/sheet/metal))
|
||||
@@ -161,6 +231,9 @@
|
||||
else if(istype(W, /obj/item/mmi))
|
||||
var/obj/item/mmi/M = W
|
||||
if(check_completion())
|
||||
if(!chest.cell)
|
||||
to_chat(user, "<span class='warning'>The endoskeleton still needs a power cell!</span>")
|
||||
return
|
||||
if(!isturf(loc))
|
||||
to_chat(user, "<span class='warning'>You can't put [M] in, the frame has to be standing on the ground to be perfectly precise!</span>")
|
||||
return
|
||||
|
||||
@@ -14,23 +14,22 @@
|
||||
grind_results = list("silicon" = 20, "copper" = 5)
|
||||
|
||||
/obj/item/stack/light_w/attackby(obj/item/O, mob/user, params)
|
||||
var/atom/Tsec = user.drop_location()
|
||||
if(istype(O, /obj/item/wirecutters))
|
||||
var/obj/item/stack/cable_coil/CC = new (Tsec, 5)
|
||||
CC.add_fingerprint(user)
|
||||
amount--
|
||||
var/obj/item/stack/sheet/glass/G = new (Tsec)
|
||||
G.add_fingerprint(user)
|
||||
if(amount <= 0)
|
||||
qdel(src)
|
||||
|
||||
else if(istype(O, /obj/item/stack/sheet/metal))
|
||||
if(istype(O, /obj/item/stack/sheet/metal))
|
||||
var/obj/item/stack/sheet/metal/M = O
|
||||
if (M.use(1))
|
||||
var/obj/item/L = new /obj/item/stack/tile/light(user.loc)
|
||||
var/obj/item/L = new /obj/item/stack/tile/light(user.drop_location())
|
||||
to_chat(user, "<span class='notice'>You make a light tile.</span>")
|
||||
L.add_fingerprint(user)
|
||||
use(1)
|
||||
else
|
||||
to_chat(user, "<span class='warning'>You need one metal sheet to finish the light tile!</span>")
|
||||
else
|
||||
return ..()
|
||||
|
||||
/obj/item/stack/light_w/wirecutter_act(mob/living/user, obj/item/I)
|
||||
var/atom/Tsec = user.drop_location()
|
||||
var/obj/item/stack/cable_coil/CC = new (Tsec, 5)
|
||||
CC.add_fingerprint(user)
|
||||
var/obj/item/stack/sheet/glass/G = new (Tsec)
|
||||
G.add_fingerprint(user)
|
||||
use(1)
|
||||
|
||||
@@ -132,7 +132,7 @@
|
||||
if (istype(E, /datum/stack_recipe))
|
||||
var/datum/stack_recipe/R = E
|
||||
var/max_multiplier = round(get_amount() / R.req_amount)
|
||||
var/title as text
|
||||
var/title
|
||||
var/can_build = 1
|
||||
can_build = can_build && (max_multiplier>0)
|
||||
|
||||
|
||||
@@ -14,45 +14,44 @@
|
||||
resistance_flags = FIRE_PROOF
|
||||
|
||||
var/obj/item/noz
|
||||
var/on = FALSE
|
||||
var/volume = 500
|
||||
|
||||
/obj/item/watertank/New()
|
||||
..()
|
||||
/obj/item/watertank/Initialize()
|
||||
. = ..()
|
||||
create_reagents(volume)
|
||||
noz = make_noz()
|
||||
|
||||
/obj/item/watertank/ui_action_click()
|
||||
toggle_mister()
|
||||
/obj/item/watertank/ui_action_click(mob/user)
|
||||
toggle_mister(user)
|
||||
|
||||
/obj/item/watertank/item_action_slot_check(slot, mob/user)
|
||||
if(slot == user.getBackSlot())
|
||||
return 1
|
||||
|
||||
/obj/item/watertank/verb/toggle_mister()
|
||||
set name = "Toggle Mister"
|
||||
set category = "Object"
|
||||
if (usr.get_item_by_slot(usr.getBackSlot()) != src)
|
||||
to_chat(usr, "<span class='warning'>The watertank must be worn properly to use!</span>")
|
||||
/obj/item/watertank/proc/toggle_mister(mob/living/user)
|
||||
if(!istype(user))
|
||||
return
|
||||
if(usr.incapacitated())
|
||||
if(user.get_item_by_slot(user.getBackSlot()) != src)
|
||||
to_chat(user, "<span class='warning'>The watertank must be worn properly to use!</span>")
|
||||
return
|
||||
if(user.incapacitated())
|
||||
return
|
||||
on = !on
|
||||
|
||||
var/mob/living/carbon/human/user = usr
|
||||
if(on)
|
||||
if(noz == null)
|
||||
noz = make_noz()
|
||||
|
||||
if(QDELETED(noz))
|
||||
noz = make_noz()
|
||||
if(noz in src)
|
||||
//Detach the nozzle into the user's hands
|
||||
if(!user.put_in_hands(noz))
|
||||
on = FALSE
|
||||
to_chat(user, "<span class='warning'>You need a free hand to hold the mister!</span>")
|
||||
return
|
||||
else
|
||||
//Remove from their hands and put back "into" the tank
|
||||
remove_noz()
|
||||
return
|
||||
|
||||
/obj/item/watertank/verb/toggle_mister_verb()
|
||||
set name = "Toggle Mister"
|
||||
set category = "Object"
|
||||
toggle_mister(usr)
|
||||
|
||||
/obj/item/watertank/proc/make_noz()
|
||||
return new /obj/item/reagent_containers/spray/mister(src)
|
||||
@@ -66,19 +65,17 @@
|
||||
if(ismob(noz.loc))
|
||||
var/mob/M = noz.loc
|
||||
M.temporarilyRemoveItemFromInventory(noz, TRUE)
|
||||
return
|
||||
noz.forceMove(src)
|
||||
|
||||
/obj/item/watertank/Destroy()
|
||||
if (on)
|
||||
qdel(noz)
|
||||
QDEL_NULL(noz)
|
||||
return ..()
|
||||
|
||||
/obj/item/watertank/attack_hand(mob/user)
|
||||
. = ..()
|
||||
if(.)
|
||||
return
|
||||
if(loc == user)
|
||||
ui_action_click()
|
||||
if (user.get_item_by_slot(user.getBackSlot()) == src)
|
||||
toggle_mister(user)
|
||||
else
|
||||
return ..()
|
||||
|
||||
/obj/item/watertank/MouseDrop(obj/over_object)
|
||||
var/mob/M = loc
|
||||
@@ -114,40 +111,28 @@
|
||||
amount_per_transfer_from_this = 50
|
||||
possible_transfer_amounts = list(25,50,100)
|
||||
volume = 500
|
||||
item_flags = NOBLUDGEON
|
||||
item_flags = NOBLUDGEON | ABSTRACT // don't put in storage
|
||||
container_type = OPENCONTAINER
|
||||
slot_flags = 0
|
||||
|
||||
var/obj/item/watertank/tank
|
||||
|
||||
/obj/item/reagent_containers/spray/mister/New(parent_tank)
|
||||
..()
|
||||
if(check_tank_exists(parent_tank, src))
|
||||
tank = parent_tank
|
||||
reagents = tank.reagents //This mister is really just a proxy for the tank's reagents
|
||||
forceMove(tank)
|
||||
return
|
||||
|
||||
/obj/item/reagent_containers/spray/mister/dropped(mob/user)
|
||||
..()
|
||||
to_chat(user, "<span class='notice'>The mister snaps back onto the watertank.</span>")
|
||||
tank.on = 0
|
||||
forceMove(tank)
|
||||
/obj/item/reagent_containers/spray/mister/Initialize()
|
||||
. = ..()
|
||||
tank = loc
|
||||
if(!istype(tank))
|
||||
return INITIALIZE_HINT_QDEL
|
||||
reagents = tank.reagents //This mister is really just a proxy for the tank's reagents
|
||||
|
||||
/obj/item/reagent_containers/spray/mister/attack_self()
|
||||
return
|
||||
|
||||
/proc/check_tank_exists(parent_tank, mob/living/carbon/human/M, obj/O)
|
||||
if (!parent_tank || !istype(parent_tank, /obj/item/watertank)) //To avoid weird issues from admin spawns
|
||||
qdel(O)
|
||||
return 0
|
||||
else
|
||||
return 1
|
||||
|
||||
/obj/item/reagent_containers/spray/mister/Move()
|
||||
/obj/item/reagent_containers/spray/mister/doMove(atom/destination)
|
||||
if(destination && (destination != tank.loc || !ismob(destination)))
|
||||
if (loc != tank)
|
||||
to_chat(tank.loc, "<span class='notice'>The mister snaps back onto the watertank.</span>")
|
||||
destination = tank
|
||||
..()
|
||||
if(loc != tank.loc)
|
||||
forceMove(tank.loc)
|
||||
|
||||
/obj/item/reagent_containers/spray/mister/afterattack(obj/target, mob/user, proximity)
|
||||
if(target.loc == loc) //Safety check so you don't fill your mister with mutagen or something and then blast yourself in the face with it
|
||||
@@ -161,8 +146,8 @@
|
||||
icon_state = "waterbackpackjani"
|
||||
item_state = "waterbackpackjani"
|
||||
|
||||
/obj/item/watertank/janitor/New()
|
||||
..()
|
||||
/obj/item/watertank/janitor/Initialize()
|
||||
. = ..()
|
||||
reagents.add_reagent("cleaner", 500)
|
||||
|
||||
/obj/item/reagent_containers/spray/mister/janitor
|
||||
@@ -197,8 +182,8 @@
|
||||
volume = 200
|
||||
slowdown = 0
|
||||
|
||||
/obj/item/watertank/atmos/New()
|
||||
..()
|
||||
/obj/item/watertank/atmos/Initialize()
|
||||
. = ..()
|
||||
reagents.add_reagent("water", 200)
|
||||
|
||||
/obj/item/watertank/atmos/make_noz()
|
||||
@@ -226,25 +211,27 @@
|
||||
precision = 1
|
||||
cooling_power = 5
|
||||
w_class = WEIGHT_CLASS_HUGE
|
||||
item_flags = ABSTRACT // don't put in storage
|
||||
var/obj/item/watertank/tank
|
||||
var/nozzle_mode = 0
|
||||
var/metal_synthesis_cooldown = 0
|
||||
var/resin_cooldown = 0
|
||||
|
||||
/obj/item/extinguisher/mini/nozzle/New(parent_tank)
|
||||
..()
|
||||
if(check_tank_exists(parent_tank, src))
|
||||
tank = parent_tank
|
||||
reagents = tank.reagents
|
||||
max_water = tank.volume
|
||||
forceMove(tank)
|
||||
/obj/item/extinguisher/mini/nozzle/Initialize()
|
||||
. = ..()
|
||||
tank = loc
|
||||
if (!istype(tank))
|
||||
return INITIALIZE_HINT_QDEL
|
||||
reagents = tank.reagents
|
||||
max_water = tank.volume
|
||||
|
||||
|
||||
/obj/item/extinguisher/mini/nozzle/Move()
|
||||
/obj/item/extinguisher/mini/nozzle/doMove(atom/destination)
|
||||
if(destination && (destination != tank.loc || !ismob(destination)))
|
||||
if(loc != tank)
|
||||
to_chat(tank.loc, "<span class='notice'>The nozzle snaps back onto the tank!</span>")
|
||||
destination = tank
|
||||
..()
|
||||
if(loc != tank.loc)
|
||||
forceMove(tank)
|
||||
return
|
||||
|
||||
/obj/item/extinguisher/mini/nozzle/attack_self(mob/user)
|
||||
switch(nozzle_mode)
|
||||
@@ -265,12 +252,6 @@
|
||||
return
|
||||
return
|
||||
|
||||
/obj/item/extinguisher/mini/nozzle/dropped(mob/user)
|
||||
..()
|
||||
to_chat(user, "<span class='notice'>The nozzle snaps back onto the tank!</span>")
|
||||
tank.on = 0
|
||||
forceMove(tank)
|
||||
|
||||
/obj/item/extinguisher/mini/nozzle/afterattack(atom/target, mob/user)
|
||||
if(nozzle_mode == EXTINGUISHER)
|
||||
..()
|
||||
@@ -453,8 +434,8 @@
|
||||
volume = 2000
|
||||
slowdown = 0
|
||||
|
||||
/obj/item/watertank/op/New()
|
||||
..()
|
||||
/obj/item/watertank/op/Initialize()
|
||||
. = ..()
|
||||
reagents.add_reagent("mutagen",350)
|
||||
reagents.add_reagent("napalm",125)
|
||||
reagents.add_reagent("welding_fuel",125)
|
||||
|
||||
@@ -32,7 +32,7 @@
|
||||
desc = "A Nanotrasen Bluespace drop pod, this one has been marked with Central Command's designations. Teleports back to Centcom after delivery."
|
||||
icon_state = "centcompod"
|
||||
|
||||
/obj/structure/closet/supplypod/Initialize(mapload, var/SO)
|
||||
/obj/structure/closet/supplypod/Initialize(mapload, SO)
|
||||
. = ..()
|
||||
if(istype(SO, /datum/supply_order))
|
||||
SupplyOrder = SO//uses Supply Order passed from expressconsole into BDPtarget
|
||||
@@ -84,7 +84,7 @@
|
||||
randomdir = FALSE
|
||||
icon_state = "supplypod_falling"
|
||||
|
||||
/obj/effect/temp_visual/DPfall/Initialize(var/dropLocation, var/podID)
|
||||
/obj/effect/temp_visual/DPfall/Initialize(dropLocation, podID)
|
||||
if (podID == POD_STANDARD)
|
||||
icon_state = "supplypod_falling"
|
||||
name = "Supply Drop Pod"
|
||||
@@ -104,7 +104,7 @@
|
||||
light_range = 2
|
||||
var/obj/effect/temp_visual/fallingPod
|
||||
|
||||
/obj/effect/DPtarget/Initialize(mapload, var/SO, var/podID, var/target)
|
||||
/obj/effect/DPtarget/Initialize(mapload, SO, podID)
|
||||
. = ..()
|
||||
var/delayTime = 17 //We're forcefully adminspawned, make it faster
|
||||
switch(podID)
|
||||
@@ -117,12 +117,12 @@
|
||||
|
||||
addtimer(CALLBACK(src, .proc/beginLaunch, SO, podID), delayTime)//standard pods take 3 seconds to come in, bluespace pods take 1.5
|
||||
|
||||
/obj/effect/DPtarget/proc/beginLaunch(var/SO, var/podID)
|
||||
/obj/effect/DPtarget/proc/beginLaunch(SO, podID)
|
||||
fallingPod = new /obj/effect/temp_visual/DPfall(drop_location(), podID)
|
||||
animate(fallingPod, pixel_z = 0, time = 3, easing = LINEAR_EASING)//make and animate a falling pod
|
||||
addtimer(CALLBACK(src, .proc/endLaunch, SO, podID), 3, TIMER_CLIENT_TIME)//fall 0.3seconds
|
||||
|
||||
/obj/effect/DPtarget/proc/endLaunch(var/SO, var/podID)
|
||||
/obj/effect/DPtarget/proc/endLaunch(SO, podID)
|
||||
if(podID == POD_STANDARD)
|
||||
new /obj/structure/closet/supplypod(drop_location(), SO)//pod is created
|
||||
explosion(src,0,0,2, flame_range = 3) //less advanced equipment than bluespace pod, so larger explosion when landing
|
||||
@@ -132,6 +132,8 @@
|
||||
else if(podID == POD_CENTCOM)
|
||||
new /obj/structure/closet/supplypod/bluespacepod/centcompod(drop_location(), SO)//CentCom supplypods dont create explosions; instead they directly deal 40 fire damage to people on the turf
|
||||
var/turf/T = get_turf(src)
|
||||
playsound(src, "explosion", 80, 1)
|
||||
new /obj/effect/hotspot(T)
|
||||
T.hotspot_expose(700, 50, 1)//same as fireball
|
||||
for(var/mob/living/M in T.contents)
|
||||
M.adjustFireLoss(40)
|
||||
|
||||
@@ -88,6 +88,7 @@
|
||||
icon_state = "heater"
|
||||
desc = "Directs energy into compressed particles in order to power engines."
|
||||
engine_power = 0 // todo make these into 2x1 parts
|
||||
CanAtmosPass = ATMOS_PASS_NO
|
||||
|
||||
/obj/structure/shuttle/engine/platform
|
||||
name = "engine platform"
|
||||
|
||||
@@ -38,6 +38,17 @@ GLOBAL_LIST_INIT(blacklisted_automated_baseturfs, typecacheof(list(
|
||||
T.setDir(dir)
|
||||
return T
|
||||
|
||||
/turf/open/copyTurf(turf/T, copy_air = FALSE)
|
||||
. = ..()
|
||||
if (isopenturf(T))
|
||||
GET_COMPONENT(slip, /datum/component/wet_floor)
|
||||
if(slip)
|
||||
var/datum/component/wet_floor/WF = T.AddComponent(/datum/component/wet_floor)
|
||||
WF.InheritComponent(slip)
|
||||
if (copy_air)
|
||||
var/turf/open/openTurf = T
|
||||
openTurf.air.copy_from(air)
|
||||
|
||||
//wrapper for ChangeTurf()s that you want to prevent/affect without overriding ChangeTurf() itself
|
||||
/turf/proc/TerraformTurf(path, new_baseturf, flags)
|
||||
return ChangeTurf(path, new_baseturf, flags)
|
||||
@@ -227,7 +238,7 @@ GLOBAL_LIST_INIT(blacklisted_automated_baseturfs, typecacheof(list(
|
||||
|
||||
// Copy an existing turf and put it on top
|
||||
// Returns the new turf
|
||||
/turf/proc/CopyOnTop(turf/copytarget, ignore_bottom=1, depth=INFINITY)
|
||||
/turf/proc/CopyOnTop(turf/copytarget, ignore_bottom=1, depth=INFINITY, copy_air = FALSE)
|
||||
var/list/new_baseturfs = list()
|
||||
new_baseturfs += baseturfs
|
||||
new_baseturfs += type
|
||||
@@ -244,7 +255,7 @@ GLOBAL_LIST_INIT(blacklisted_automated_baseturfs, typecacheof(list(
|
||||
target_baseturfs -= new_baseturfs & GLOB.blacklisted_automated_baseturfs
|
||||
new_baseturfs += target_baseturfs
|
||||
|
||||
var/turf/newT = copytarget.copyTurf(src)
|
||||
var/turf/newT = copytarget.copyTurf(src, copy_air)
|
||||
newT.baseturfs = new_baseturfs
|
||||
return newT
|
||||
|
||||
|
||||
@@ -8,7 +8,7 @@
|
||||
. = ..()
|
||||
AddComponent(/datum/component/rad_insulation, RAD_MEDIUM_INSULATION)
|
||||
|
||||
/turf/closed/ChangeTurf()
|
||||
/turf/closed/AfterChange()
|
||||
. = ..()
|
||||
SSair.high_pressure_delta -= src
|
||||
|
||||
|
||||
@@ -235,14 +235,6 @@
|
||||
new /datum/forced_movement(C, get_ranged_target_turf(C, olddir, 1), 1, FALSE) //spinning would be bad for ice, fucks up the next dir
|
||||
return 1
|
||||
|
||||
/turf/open/copyTurf(turf/T)
|
||||
. = ..()
|
||||
if(. && isopenturf(T))
|
||||
GET_COMPONENT(slip, /datum/component/wet_floor)
|
||||
if(slip)
|
||||
var/datum/component/wet_floor/WF = T.AddComponent(/datum/component/wet_floor)
|
||||
WF.InheritComponent(slip)
|
||||
|
||||
/turf/open/proc/MakeSlippery(wet_setting = TURF_WET_WATER, min_wet_time = 0, wet_time_to_add = 0, max_wet_time = MAXIMUM_WET_TIME, permanent)
|
||||
AddComponent(/datum/component/wet_floor, wet_setting, min_wet_time, wet_time_to_add, max_wet_time, permanent)
|
||||
|
||||
|
||||
@@ -55,6 +55,7 @@
|
||||
return
|
||||
if(target == src)
|
||||
ScrapeAway()
|
||||
return
|
||||
if(target != null)
|
||||
severity = 3
|
||||
|
||||
|
||||
@@ -1356,8 +1356,9 @@ GLOBAL_LIST_EMPTY(custom_outfits) //Admin created outfits
|
||||
alert("ERROR: Incorrect / improper path given.")
|
||||
return
|
||||
//send the pod
|
||||
target.Stun(10)//takes 0.53 seconds for CentCom pod to land
|
||||
new /obj/effect/DPtarget(get_turf(target), delivery, POD_CENTCOM, target)
|
||||
if(iscarbon(target))
|
||||
target.Stun(10)//takes 0.53 seconds for CentCom pod to land
|
||||
new /obj/effect/DPtarget(get_turf(target), delivery, POD_CENTCOM)
|
||||
|
||||
var/msg = "[key_name_admin(usr)] punished [key_name_admin(target)] with [punishment]."
|
||||
message_admins(msg)
|
||||
|
||||
@@ -215,7 +215,7 @@
|
||||
var/cooldown = 0
|
||||
var/base_cooldown = 1200
|
||||
|
||||
/datum/action/innate/cult/master/cultmark/New()
|
||||
/datum/action/innate/cult/master/cultmark/New(Target)
|
||||
CM = new()
|
||||
CM.attached_action = src
|
||||
..()
|
||||
@@ -299,7 +299,7 @@
|
||||
name = "Mark a Blood Target for the Cult"
|
||||
desc = "Marks a target for the entire cult to track."
|
||||
|
||||
/datum/action/innate/cult/master/cultmark/IsAvailable()
|
||||
/datum/action/innate/cult/master/cultmark/ghost/IsAvailable()
|
||||
if(istype(owner, /mob/dead/observer) && iscultist(owner.mind.current))
|
||||
return TRUE
|
||||
else
|
||||
|
||||
@@ -588,7 +588,7 @@ This is here to make the tiles around the station mininuke change when it's arme
|
||||
CRASH("A fake nuke disk tried to call process(). Who the fuck and how the fuck")
|
||||
var/turf/newturf = get_turf(src)
|
||||
if(newturf && lastlocation == newturf)
|
||||
if(last_disk_move < world.time - 5000 && prob((world.time - 5000 - last_disk_move)*0.00001))
|
||||
if(last_disk_move < world.time - 5000 && prob((world.time - 5000 - last_disk_move)*0.0001))
|
||||
var/datum/round_event_control/operative/loneop = locate(/datum/round_event_control/operative) in SSevents.control
|
||||
if(istype(loneop))
|
||||
loneop.weight += 1
|
||||
|
||||
@@ -278,7 +278,7 @@
|
||||
return NUKE_RESULT_WRONG_STATION
|
||||
else if (!disk_rescued && !station_was_nuked && nuke_off_station && syndies_didnt_escape)
|
||||
return NUKE_RESULT_WRONG_STATION_DEAD
|
||||
else if ((disk_rescued || evacuation) && operatives_dead())
|
||||
else if ((disk_rescued && evacuation) && operatives_dead())
|
||||
return NUKE_RESULT_CREW_WIN_SYNDIES_DEAD
|
||||
else if (disk_rescued)
|
||||
return NUKE_RESULT_CREW_WIN
|
||||
|
||||
@@ -1,12 +1,12 @@
|
||||
//node2, air2, network2 correspond to input
|
||||
//node1, air1, network1 correspond to output
|
||||
#define CIRCULATOR_COLD 0
|
||||
#define CIRCULATOR_HOT 1
|
||||
#define CIRCULATOR_HOT 0
|
||||
#define CIRCULATOR_COLD 1
|
||||
|
||||
/obj/machinery/atmospherics/components/binary/circulator
|
||||
name = "circulator/heat exchanger"
|
||||
desc = "A gas circulator pump and heat exchanger."
|
||||
icon_state = "circ-off"
|
||||
icon_state = "circ-off-0"
|
||||
|
||||
var/active = FALSE
|
||||
|
||||
@@ -185,4 +185,4 @@
|
||||
|
||||
flipped = !flipped
|
||||
to_chat(usr, "<span class='notice'>You flip [src].</span>")
|
||||
update_icon()
|
||||
update_icon()
|
||||
|
||||
@@ -79,7 +79,7 @@ Thus, the two variables affect pump operation are set in New():
|
||||
if((input_starting_pressure < 0.01) || (output_starting_pressure > 9000))
|
||||
return
|
||||
|
||||
var/transfer_ratio = min(1, transfer_rate/air1.volume)
|
||||
var/transfer_ratio = transfer_rate/air1.volume
|
||||
|
||||
var/datum/gas_mixture/removed = air1.remove_ratio(transfer_ratio)
|
||||
|
||||
|
||||
@@ -225,7 +225,7 @@ GLOBAL_LIST_EMPTY(asset_datums)
|
||||
|
||||
var/res_name = "spritesheet_[name].css"
|
||||
var/fname = "data/spritesheets/[res_name]"
|
||||
call("rust_g", "file_write")(generate_css(), fname)
|
||||
text2file(generate_css(), fname)
|
||||
register_asset(res_name, file(fname))
|
||||
|
||||
for(var/size_id in sizes)
|
||||
@@ -249,7 +249,7 @@ GLOBAL_LIST_EMPTY(asset_datums)
|
||||
// save flattened version
|
||||
var/fname = "data/spritesheets/[name]_[size_id].png"
|
||||
fcopy(size[SPRSZ_ICON], fname)
|
||||
var/error = call("rust_g", "dmi_strip_metadata")(fname)
|
||||
var/error = rustg_dmi_strip_metadata(fname)
|
||||
if(length(error))
|
||||
stack_trace("Failed to strip [name]_[size_id].png: [error]")
|
||||
size[SPRSZ_STRIPPED] = icon(fname)
|
||||
@@ -587,7 +587,11 @@ GLOBAL_LIST_EMPTY(asset_datums)
|
||||
if (machine)
|
||||
item = machine
|
||||
var/icon_file = initial(item.icon)
|
||||
var/icon/I = icon(icon_file, initial(item.icon_state), SOUTH)
|
||||
var/icon_state = initial(item.icon_state)
|
||||
if (!(icon_state in icon_states(icon_file)))
|
||||
warning("design [D] with icon '[icon_file]' missing state '[icon_state]'")
|
||||
continue
|
||||
var/icon/I = icon(icon_file, icon_state, SOUTH)
|
||||
|
||||
// computers (and snowflakes) get their screen and keyboard sprites
|
||||
if (ispath(item, /obj/machinery/computer) || ispath(item, /obj/machinery/power/solar_control))
|
||||
|
||||
@@ -594,3 +594,12 @@
|
||||
icon = 'icons/obj/clothing/clockwork_garb.dmi'
|
||||
icon_state = "clockwork_cuirass_old"
|
||||
armor = list("melee" = 5, "bullet" = 0, "laser" = -5, "energy" = 0, "bomb" = 10, "bio" = 0, "rad" = 0, "fire" = 20, "acid" = 20)
|
||||
|
||||
/obj/item/clothing/suit/ghost_sheet
|
||||
name = "ghost sheet"
|
||||
desc = "The hands float by themselves, so it's extra spooky."
|
||||
icon_state = "ghost_sheet"
|
||||
item_state = "ghost_sheet_item"
|
||||
w_class = WEIGHT_CLASS_TINY
|
||||
flags_inv = HIDEGLOVES|HIDEMASK|HIDEEARS|HIDEFACE|HIDEHAIR|HIDEFACIALHAIR
|
||||
alternate_worn_layer = UNDER_HEAD_LAYER
|
||||
|
||||
@@ -669,3 +669,11 @@
|
||||
tools = list(TOOL_SCREWDRIVER, TOOL_WIRECUTTER)
|
||||
reqs = list(/obj/item/clothing/glasses/sunglasses/reagent = 1)
|
||||
category = CAT_CLOTHING
|
||||
|
||||
/datum/crafting_recipe/ghostsheet
|
||||
name = "Ghost Sheet"
|
||||
result = /obj/item/clothing/suit/ghost_sheet
|
||||
time = 5
|
||||
tools = list(TOOL_WIRECUTTER)
|
||||
reqs = list(/obj/item/bedsheet = 1)
|
||||
category = CAT_CLOTHING
|
||||
|
||||
@@ -1,5 +1,8 @@
|
||||
//Vars that will not be copied when using /DuplicateObject
|
||||
GLOBAL_LIST_INIT(duplicate_forbidden_vars,list("tag", "datum_components", "area","type","loc","locs","vars", "parent","parent_type", "verbs","ckey","key","power_supply","contents","reagents","stat","x","y","z","group","atmos_adjacent_turfs"))
|
||||
GLOBAL_LIST_INIT(duplicate_forbidden_vars,list(
|
||||
"tag", "datum_components", "area", "type", "loc", "locs", "vars", "parent", "parent_type", "verbs", "ckey", "key",
|
||||
"power_supply", "contents", "reagents", "stat", "x", "y", "z", "group", "atmos_adjacent_turfs", "comp_lookup"
|
||||
))
|
||||
|
||||
/proc/DuplicateObject(atom/original, perfectcopy = TRUE, sameloc = FALSE, atom/newloc = null, nerf = FALSE, holoitem=FALSE)
|
||||
if(!original)
|
||||
|
||||
@@ -15,7 +15,7 @@
|
||||
var/productivity = 0
|
||||
var/max_items = 40
|
||||
var/datum/techweb/stored_research
|
||||
var/list/show_categories = list("Food", "Botany Chemicals", "Leather and Cloth")
|
||||
var/list/show_categories = list("Food", "Botany Chemicals", "Organic Materials")
|
||||
var/list/timesFiveCategories = list("Food", "Botany Chemicals")
|
||||
|
||||
/obj/machinery/biogenerator/Initialize()
|
||||
|
||||
@@ -60,3 +60,5 @@
|
||||
var/next_hallucination = 0
|
||||
var/cpr_time = 1 //CPR cooldown.
|
||||
var/damageoverlaytemp = 0
|
||||
|
||||
var/drunkenness = 0 //Overall drunkenness - check handle_alcohol() in life.dm for effects
|
||||
|
||||
@@ -44,7 +44,6 @@
|
||||
|
||||
var/name_override //For temporary visible name changes
|
||||
|
||||
var/drunkenness = 0 //Overall drunkenness - check handle_alcohol() in life.dm for effects
|
||||
var/datum/personal_crafting/handcrafting
|
||||
var/datum/physiology/physiology
|
||||
|
||||
|
||||
@@ -339,108 +339,8 @@
|
||||
// Tissues die without blood circulation
|
||||
adjustBruteLoss(2)
|
||||
|
||||
/*
|
||||
Alcohol Poisoning Chart
|
||||
Note that all higher effects of alcohol poisoning will inherit effects for smaller amounts (i.e. light poisoning inherts from slight poisoning)
|
||||
In addition, severe effects won't always trigger unless the drink is poisonously strong
|
||||
All effects don't start immediately, but rather get worse over time; the rate is affected by the imbiber's alcohol tolerance
|
||||
|
||||
0: Non-alcoholic
|
||||
1-10: Barely classifiable as alcohol - occassional slurring
|
||||
11-20: Slight alcohol content - slurring
|
||||
21-30: Below average - imbiber begins to look slightly drunk
|
||||
31-40: Just below average - no unique effects
|
||||
41-50: Average - mild disorientation, imbiber begins to look drunk
|
||||
51-60: Just above average - disorientation, vomiting, imbiber begins to look heavily drunk
|
||||
61-70: Above average - small chance of blurry vision, imbiber begins to look smashed
|
||||
71-80: High alcohol content - blurry vision, imbiber completely shitfaced
|
||||
81-90: Extremely high alcohol content - light brain damage, passing out
|
||||
91-100: Dangerously toxic - swift death
|
||||
*/
|
||||
#define BALLMER_POINTS 5
|
||||
GLOBAL_LIST_INIT(ballmer_good_msg, list("Hey guys, what if we rolled out a bluespace wiring system so mice can't destroy the powergrid anymore?",
|
||||
"Hear me out here. What if, and this is just a theory, we made R&D controllable from our PDAs?",
|
||||
"I'm thinking we should roll out a git repository for our research under the AGPLv3 license so that we can share it among the other stations freely.",
|
||||
"I dunno about you guys, but IDs and PDAs being separate is clunky as fuck. Maybe we should merge them into a chip in our arms? That way they can't be stolen easily.",
|
||||
"Why the fuck aren't we just making every pair of shoes into galoshes? We have the technology."))
|
||||
GLOBAL_LIST_INIT(ballmer_windows_me_msg, list("Yo man, what if, we like, uh, put a webserver that's automatically turned on with default admin passwords into every PDA?",
|
||||
"So like, you know how we separate our codebase from the master copy that runs on our consumer boxes? What if we merged the two and undid the separation between codebase and server?",
|
||||
"Dude, radical idea: H.O.N.K mechs but with no bananium required.",
|
||||
"Best idea ever: Disposal pipes instead of hallways."))
|
||||
/mob/living/carbon/human/handle_status_effects()
|
||||
..()
|
||||
|
||||
|
||||
if(drunkenness)
|
||||
drunkenness = max(drunkenness - (drunkenness * 0.04), 0)
|
||||
if(drunkenness >= 6)
|
||||
if(prob(25))
|
||||
slurring += 2
|
||||
jitteriness = max(jitteriness - 3, 0)
|
||||
if(has_trait(TRAIT_DRUNK_HEALING))
|
||||
adjustBruteLoss(-0.12, FALSE)
|
||||
adjustFireLoss(-0.06, FALSE)
|
||||
|
||||
if(drunkenness >= 11 && slurring < 5)
|
||||
slurring += 1.2
|
||||
|
||||
if(mind && (mind.assigned_role == "Scientist" || mind.assigned_role == "Research Director"))
|
||||
if(SSresearch.science_tech)
|
||||
if(drunkenness >= 12.9 && drunkenness <= 13.8)
|
||||
drunkenness = round(drunkenness, 0.01)
|
||||
var/ballmer_percent = 0
|
||||
if(drunkenness == 13.35) // why run math if I dont have to
|
||||
ballmer_percent = 1
|
||||
else
|
||||
ballmer_percent = (-abs(drunkenness - 13.35) / 0.9) + 1
|
||||
if(prob(5))
|
||||
say(pick(GLOB.ballmer_good_msg))
|
||||
SSresearch.science_tech.add_point_list(list(TECHWEB_POINT_TYPE_GENERIC = BALLMER_POINTS * ballmer_percent))
|
||||
if(drunkenness > 26) // by this point you're into windows ME territory
|
||||
if(prob(5))
|
||||
SSresearch.science_tech.remove_point_list(list(TECHWEB_POINT_TYPE_GENERIC = BALLMER_POINTS))
|
||||
say(pick(GLOB.ballmer_windows_me_msg))
|
||||
|
||||
if(drunkenness >= 41)
|
||||
if(prob(25))
|
||||
confused += 2
|
||||
Dizzy(10)
|
||||
if(has_trait(TRAIT_DRUNK_HEALING)) // effects stack with lower tiers
|
||||
adjustBruteLoss(-0.3, FALSE)
|
||||
adjustFireLoss(-0.15, FALSE)
|
||||
|
||||
if(drunkenness >= 51)
|
||||
if(prob(5))
|
||||
confused += 10
|
||||
vomit()
|
||||
Dizzy(25)
|
||||
|
||||
if(drunkenness >= 61)
|
||||
if(prob(50))
|
||||
blur_eyes(5)
|
||||
if(has_trait(TRAIT_DRUNK_HEALING))
|
||||
adjustBruteLoss(-0.4, FALSE)
|
||||
adjustFireLoss(-0.2, FALSE)
|
||||
|
||||
if(drunkenness >= 71)
|
||||
blur_eyes(5)
|
||||
|
||||
if(drunkenness >= 81)
|
||||
adjustToxLoss(0.2)
|
||||
if(prob(5) && !stat)
|
||||
to_chat(src, "<span class='warning'>Maybe you should lie down for a bit...</span>")
|
||||
|
||||
if(drunkenness >= 91)
|
||||
adjustBrainLoss(0.4, 60)
|
||||
if(prob(20) && !stat)
|
||||
if(SSshuttle.emergency.mode == SHUTTLE_DOCKED && is_station_level(z)) //QoL mainly
|
||||
to_chat(src, "<span class='warning'>You're so tired... but you can't miss that shuttle...</span>")
|
||||
else
|
||||
to_chat(src, "<span class='warning'>Just a quick nap...</span>")
|
||||
Sleeping(900)
|
||||
|
||||
if(drunkenness >= 101)
|
||||
adjustToxLoss(4) //Let's be honest you shouldn't be alive by now
|
||||
|
||||
#undef THERMAL_PROTECTION_HEAD
|
||||
#undef THERMAL_PROTECTION_CHEST
|
||||
|
||||
@@ -325,6 +325,36 @@
|
||||
M.adjustBruteLoss(5)
|
||||
nutrition += 10
|
||||
|
||||
|
||||
/*
|
||||
Alcohol Poisoning Chart
|
||||
Note that all higher effects of alcohol poisoning will inherit effects for smaller amounts (i.e. light poisoning inherts from slight poisoning)
|
||||
In addition, severe effects won't always trigger unless the drink is poisonously strong
|
||||
All effects don't start immediately, but rather get worse over time; the rate is affected by the imbiber's alcohol tolerance
|
||||
|
||||
0: Non-alcoholic
|
||||
1-10: Barely classifiable as alcohol - occassional slurring
|
||||
11-20: Slight alcohol content - slurring
|
||||
21-30: Below average - imbiber begins to look slightly drunk
|
||||
31-40: Just below average - no unique effects
|
||||
41-50: Average - mild disorientation, imbiber begins to look drunk
|
||||
51-60: Just above average - disorientation, vomiting, imbiber begins to look heavily drunk
|
||||
61-70: Above average - small chance of blurry vision, imbiber begins to look smashed
|
||||
71-80: High alcohol content - blurry vision, imbiber completely shitfaced
|
||||
81-90: Extremely high alcohol content - light brain damage, passing out
|
||||
91-100: Dangerously toxic - swift death
|
||||
*/
|
||||
#define BALLMER_POINTS 5
|
||||
GLOBAL_LIST_INIT(ballmer_good_msg, list("Hey guys, what if we rolled out a bluespace wiring system so mice can't destroy the powergrid anymore?",
|
||||
"Hear me out here. What if, and this is just a theory, we made R&D controllable from our PDAs?",
|
||||
"I'm thinking we should roll out a git repository for our research under the AGPLv3 license so that we can share it among the other stations freely.",
|
||||
"I dunno about you guys, but IDs and PDAs being separate is clunky as fuck. Maybe we should merge them into a chip in our arms? That way they can't be stolen easily.",
|
||||
"Why the fuck aren't we just making every pair of shoes into galoshes? We have the technology."))
|
||||
GLOBAL_LIST_INIT(ballmer_windows_me_msg, list("Yo man, what if, we like, uh, put a webserver that's automatically turned on with default admin passwords into every PDA?",
|
||||
"So like, you know how we separate our codebase from the master copy that runs on our consumer boxes? What if we merged the two and undid the separation between codebase and server?",
|
||||
"Dude, radical idea: H.O.N.K mechs but with no bananium required.",
|
||||
"Best idea ever: Disposal pipes instead of hallways."))
|
||||
|
||||
//this updates all special effects: stun, sleeping, knockdown, druggy, stuttering, etc..
|
||||
/mob/living/carbon/handle_status_effects()
|
||||
..()
|
||||
@@ -404,6 +434,77 @@
|
||||
if(hallucination)
|
||||
handle_hallucinations()
|
||||
|
||||
if(drunkenness)
|
||||
drunkenness = max(drunkenness - (drunkenness * 0.04), 0)
|
||||
if(drunkenness >= 6)
|
||||
if(prob(25))
|
||||
slurring += 2
|
||||
jitteriness = max(jitteriness - 3, 0)
|
||||
if(has_trait(TRAIT_DRUNK_HEALING))
|
||||
adjustBruteLoss(-0.12, FALSE)
|
||||
adjustFireLoss(-0.06, FALSE)
|
||||
|
||||
if(drunkenness >= 11 && slurring < 5)
|
||||
slurring += 1.2
|
||||
|
||||
if(mind && (mind.assigned_role == "Scientist" || mind.assigned_role == "Research Director"))
|
||||
if(SSresearch.science_tech)
|
||||
if(drunkenness >= 12.9 && drunkenness <= 13.8)
|
||||
drunkenness = round(drunkenness, 0.01)
|
||||
var/ballmer_percent = 0
|
||||
if(drunkenness == 13.35) // why run math if I dont have to
|
||||
ballmer_percent = 1
|
||||
else
|
||||
ballmer_percent = (-abs(drunkenness - 13.35) / 0.9) + 1
|
||||
if(prob(5))
|
||||
say(pick(GLOB.ballmer_good_msg))
|
||||
SSresearch.science_tech.add_point_list(list(TECHWEB_POINT_TYPE_GENERIC = BALLMER_POINTS * ballmer_percent))
|
||||
if(drunkenness > 26) // by this point you're into windows ME territory
|
||||
if(prob(5))
|
||||
SSresearch.science_tech.remove_point_list(list(TECHWEB_POINT_TYPE_GENERIC = BALLMER_POINTS))
|
||||
say(pick(GLOB.ballmer_windows_me_msg))
|
||||
|
||||
if(drunkenness >= 41)
|
||||
if(prob(25))
|
||||
confused += 2
|
||||
Dizzy(10)
|
||||
if(has_trait(TRAIT_DRUNK_HEALING)) // effects stack with lower tiers
|
||||
adjustBruteLoss(-0.3, FALSE)
|
||||
adjustFireLoss(-0.15, FALSE)
|
||||
|
||||
if(drunkenness >= 51)
|
||||
if(prob(5))
|
||||
confused += 10
|
||||
vomit()
|
||||
Dizzy(25)
|
||||
|
||||
if(drunkenness >= 61)
|
||||
if(prob(50))
|
||||
blur_eyes(5)
|
||||
if(has_trait(TRAIT_DRUNK_HEALING))
|
||||
adjustBruteLoss(-0.4, FALSE)
|
||||
adjustFireLoss(-0.2, FALSE)
|
||||
|
||||
if(drunkenness >= 71)
|
||||
blur_eyes(5)
|
||||
|
||||
if(drunkenness >= 81)
|
||||
adjustToxLoss(0.2)
|
||||
if(prob(5) && !stat)
|
||||
to_chat(src, "<span class='warning'>Maybe you should lie down for a bit...</span>")
|
||||
|
||||
if(drunkenness >= 91)
|
||||
adjustBrainLoss(0.4, 60)
|
||||
if(prob(20) && !stat)
|
||||
if(SSshuttle.emergency.mode == SHUTTLE_DOCKED && is_station_level(z)) //QoL mainly
|
||||
to_chat(src, "<span class='warning'>You're so tired... but you can't miss that shuttle...</span>")
|
||||
else
|
||||
to_chat(src, "<span class='warning'>Just a quick nap...</span>")
|
||||
Sleeping(900)
|
||||
|
||||
if(drunkenness >= 101)
|
||||
adjustToxLoss(4) //Let's be honest you shouldn't be alive by now
|
||||
|
||||
//used in human and monkey handle_environment()
|
||||
/mob/living/carbon/proc/natural_bodytemperature_stabilization()
|
||||
var/body_temperature_difference = BODYTEMP_NORMAL - bodytemperature
|
||||
|
||||
@@ -220,7 +220,7 @@
|
||||
return TRUE
|
||||
|
||||
if(target && target.stat == CONSCIOUS) // make sure target exists
|
||||
if(Adjacent(target) && isturf(target.loc)) // if right next to perp
|
||||
if(Adjacent(target) && isturf(target.loc) && !IsDeadOrIncap()) // if right next to perp
|
||||
|
||||
// check if target has a weapon
|
||||
var/obj/item/W
|
||||
|
||||
@@ -330,7 +330,7 @@
|
||||
return(gain)
|
||||
|
||||
/mob/living/narsie_act()
|
||||
if(status_flags & GODMODE)
|
||||
if(status_flags & GODMODE || QDELETED(src))
|
||||
return
|
||||
|
||||
if(is_servant_of_ratvar(src) && !stat)
|
||||
|
||||
@@ -96,8 +96,11 @@
|
||||
|
||||
// Return to the Core.
|
||||
/mob/living/silicon/ai/proc/view_core()
|
||||
|
||||
current = null
|
||||
if(istype(current,/obj/machinery/holopad))
|
||||
var/obj/machinery/holopad/H = current
|
||||
H.clear_holo(src)
|
||||
else
|
||||
current = null
|
||||
cameraFollow = null
|
||||
unset_machine()
|
||||
|
||||
|
||||
@@ -111,7 +111,7 @@
|
||||
taste_description = "french cuisine"
|
||||
taste_mult = 1.3
|
||||
|
||||
/datum/reagent/toxin/leaper_venom/on_mob_life(mob/living/M)
|
||||
/datum/reagent/toxin/leaper_venom/on_mob_life(mob/living/carbon/M)
|
||||
if(volume >= 10)
|
||||
M.adjustToxLoss(5, 0)
|
||||
..()
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
/obj/item/modular_computer/tablet //Its called tablet for theme of 90ies but actually its a "big smartphone" sized
|
||||
name = "tablet computer"
|
||||
icon = 'icons/obj/modular_tablet.dmi'
|
||||
icon_state = "tablet"
|
||||
icon_state = "tablet-red"
|
||||
icon_state_unpowered = "tablet"
|
||||
icon_state_powered = "tablet"
|
||||
icon_state_menu = "menu"
|
||||
|
||||
@@ -38,7 +38,7 @@ The holder (reagents datum) is the datum that holds a list of all reagents curre
|
||||
If the specified amount is greater than what is available, it will use
|
||||
the amount of the reagent that is available. If no reagent exists, returns null.
|
||||
|
||||
metabolize(var/mob/M)
|
||||
metabolize(var/mob/living/carbon/C)
|
||||
This proc is called by the mobs life proc. It simply calls on_mob_life for
|
||||
all contained reagents. You shouldnt have to use this one directly.
|
||||
|
||||
@@ -116,7 +116,7 @@ The holder (reagents datum) is the datum that holds a list of all reagents curre
|
||||
# About Reagents:
|
||||
Reagents are all the things you can mix and fille in bottles etc. This can be anything from rejuvs over water to ... iron. Each reagent also has a few procs - i'll explain those below.
|
||||
```
|
||||
reaction_mob(var/mob/M, var/method=TOUCH)
|
||||
reaction_mob(var/mob/living/L, var/method=TOUCH)
|
||||
This is called by the holder's reation proc.
|
||||
This version is only called when the reagent
|
||||
reacts with a mob. The method var can be either
|
||||
@@ -135,7 +135,7 @@ Reagents are all the things you can mix and fille in bottles etc. This can be an
|
||||
with a turf. You'll want to put stuff like extra
|
||||
slippery floors for lube or something in here.
|
||||
|
||||
on_mob_life(var/mob/M)
|
||||
on_mob_life(var/mob/living/L)
|
||||
This proc is called everytime the mobs life proc executes.
|
||||
This is the place where you put damage for toxins ,
|
||||
drowsyness for sleep toxins etc etc.
|
||||
@@ -241,7 +241,7 @@ By default, all atom have a reagents var - but its empty. if you want to use an
|
||||
Checks if something can be injected to.
|
||||
If this returns 1, you can use syringes and droppers
|
||||
to draw from and add to the contents of this object.
|
||||
|
||||
|
||||
atom/proc/is_drawable()
|
||||
Checks if something can be drawn from.
|
||||
If this returns 1, you can use syringes and droppers
|
||||
@@ -255,4 +255,4 @@ Credit goes to Cogwerks, and all the other goonstation coders for the original i
|
||||
- Any of the Secret Chems
|
||||
- Goon in-joke chems (Eg. Cat Drugs, Hairgrownium)
|
||||
- Liquid Electricity
|
||||
- Rajajajah
|
||||
- Rajajajah
|
||||
|
||||
@@ -51,17 +51,17 @@
|
||||
/datum/reagent/proc/reaction_turf(turf/T, volume)
|
||||
return
|
||||
|
||||
/datum/reagent/proc/on_mob_life(mob/living/M)
|
||||
/datum/reagent/proc/on_mob_life(mob/living/carbon/M)
|
||||
current_cycle++
|
||||
holder.remove_reagent(src.id, metabolization_rate * M.metabolism_efficiency) //By default it slowly disappears.
|
||||
return
|
||||
|
||||
// Called when this reagent is first added to a mob
|
||||
/datum/reagent/proc/on_mob_add(mob/M)
|
||||
/datum/reagent/proc/on_mob_add(mob/living/L)
|
||||
return
|
||||
|
||||
// Called when this reagent is removed while inside a mob
|
||||
/datum/reagent/proc/on_mob_delete(mob/M)
|
||||
/datum/reagent/proc/on_mob_delete(mob/living/L)
|
||||
return
|
||||
|
||||
/datum/reagent/proc/on_move(mob/M)
|
||||
|
||||
@@ -34,17 +34,16 @@ All effects don't start immediately, but rather get worse over time; the rate is
|
||||
91-100: Dangerously toxic - swift death
|
||||
*/
|
||||
|
||||
/datum/reagent/consumable/ethanol/on_mob_life(mob/living/M)
|
||||
if(ishuman(M))
|
||||
var/mob/living/carbon/human/H = M
|
||||
if(H.drunkenness < volume * boozepwr * ALCOHOL_THRESHOLD_MODIFIER)
|
||||
var/booze_power = boozepwr
|
||||
if(H.has_trait(TRAIT_ALCOHOL_TOLERANCE)) //we're an accomplished drinker
|
||||
booze_power *= 0.7
|
||||
H.drunkenness = max((H.drunkenness + (sqrt(volume) * booze_power * ALCOHOL_RATE)), 0) //Volume, power, and server alcohol rate effect how quickly one gets drunk
|
||||
var/obj/item/organ/liver/L = H.getorganslot(ORGAN_SLOT_LIVER)
|
||||
H.applyLiverDamage((max(sqrt(volume) * (boozepwr ** ALCOHOL_EXPONENT) * L.alcohol_tolerance, 0))/150)
|
||||
return ..() || .
|
||||
/datum/reagent/consumable/ethanol/on_mob_life(mob/living/carbon/C)
|
||||
if(C.drunkenness < volume * boozepwr * ALCOHOL_THRESHOLD_MODIFIER)
|
||||
var/booze_power = boozepwr
|
||||
if(C.has_trait(TRAIT_ALCOHOL_TOLERANCE)) //we're an accomplished drinker
|
||||
booze_power *= 0.7
|
||||
C.drunkenness = max((C.drunkenness + (sqrt(volume) * booze_power * ALCOHOL_RATE)), 0) //Volume, power, and server alcohol rate effect how quickly one gets drunk
|
||||
var/obj/item/organ/liver/L = C.getorganslot(ORGAN_SLOT_LIVER)
|
||||
if (istype(L))
|
||||
C.applyLiverDamage((max(sqrt(volume) * (boozepwr ** ALCOHOL_EXPONENT) * L.alcohol_tolerance, 0))/150)
|
||||
return ..()
|
||||
|
||||
/datum/reagent/consumable/ethanol/reaction_obj(obj/O, reac_volume)
|
||||
if(istype(O, /obj/item/paper))
|
||||
@@ -107,7 +106,7 @@ All effects don't start immediately, but rather get worse over time; the rate is
|
||||
glass_name = "glass of green beer"
|
||||
glass_desc = "A freezing pint of green beer. Festive."
|
||||
|
||||
/datum/reagent/consumable/ethanol/beer/green/on_mob_life(mob/living/M)
|
||||
/datum/reagent/consumable/ethanol/beer/green/on_mob_life(mob/living/carbon/M)
|
||||
if(M.color != color)
|
||||
M.add_atom_colour(color, TEMPORARY_COLOUR_PRIORITY)
|
||||
return ..()
|
||||
@@ -126,7 +125,7 @@ All effects don't start immediately, but rather get worse over time; the rate is
|
||||
glass_desc = "DAMN, THIS THING LOOKS ROBUST!"
|
||||
shot_glass_icon_state = "shotglasscream"
|
||||
|
||||
/datum/reagent/consumable/ethanol/kahlua/on_mob_life(mob/living/M)
|
||||
/datum/reagent/consumable/ethanol/kahlua/on_mob_life(mob/living/carbon/M)
|
||||
M.dizziness = max(0,M.dizziness-5)
|
||||
M.drowsyness = max(0,M.drowsyness-3)
|
||||
M.AdjustSleeping(-40, FALSE)
|
||||
@@ -161,7 +160,7 @@ All effects don't start immediately, but rather get worse over time; the rate is
|
||||
glass_name = "glass of Thirteen Loko"
|
||||
glass_desc = "This is a glass of Thirteen Loko, it appears to be of the highest quality. The drink, not the glass."
|
||||
|
||||
/datum/reagent/consumable/ethanol/thirteenloko/on_mob_life(mob/living/M)
|
||||
/datum/reagent/consumable/ethanol/thirteenloko/on_mob_life(mob/living/carbon/M)
|
||||
M.drowsyness = max(0,M.drowsyness-7)
|
||||
M.AdjustSleeping(-40)
|
||||
M.adjust_bodytemperature(-5 * TEMPERATURE_DAMAGE_COEFFICIENT, BODYTEMP_NORMAL)
|
||||
@@ -222,7 +221,7 @@ All effects don't start immediately, but rather get worse over time; the rate is
|
||||
glass_desc = "The glass contain wodka. Xynta."
|
||||
shot_glass_icon_state = "shotglassclear"
|
||||
|
||||
/datum/reagent/consumable/ethanol/vodka/on_mob_life(mob/living/M)
|
||||
/datum/reagent/consumable/ethanol/vodka/on_mob_life(mob/living/carbon/M)
|
||||
M.radiation = max(M.radiation-2,0)
|
||||
return ..()
|
||||
|
||||
@@ -238,7 +237,7 @@ All effects don't start immediately, but rather get worse over time; the rate is
|
||||
glass_name = "glass of bilk"
|
||||
glass_desc = "A brew of milk and beer. For those alcoholics who fear osteoporosis."
|
||||
|
||||
/datum/reagent/consumable/ethanol/bilk/on_mob_life(mob/living/M)
|
||||
/datum/reagent/consumable/ethanol/bilk/on_mob_life(mob/living/carbon/M)
|
||||
if(M.getBruteLoss() && prob(10))
|
||||
M.heal_bodypart_damage(1)
|
||||
. = 1
|
||||
@@ -255,7 +254,7 @@ All effects don't start immediately, but rather get worse over time; the rate is
|
||||
glass_name = "Three Mile Island Ice Tea"
|
||||
glass_desc = "A glass of this is sure to prevent a meltdown."
|
||||
|
||||
/datum/reagent/consumable/ethanol/threemileisland/on_mob_life(mob/living/M)
|
||||
/datum/reagent/consumable/ethanol/threemileisland/on_mob_life(mob/living/carbon/M)
|
||||
M.set_drugginess(50)
|
||||
return ..()
|
||||
|
||||
@@ -361,7 +360,7 @@ All effects don't start immediately, but rather get worse over time; the rate is
|
||||
glass_desc = "It's as strong as it smells."
|
||||
shot_glass_icon_state = "shotglassgreen"
|
||||
|
||||
/datum/reagent/consumable/ethanol/absinthe/on_mob_life(mob/living/M)
|
||||
/datum/reagent/consumable/ethanol/absinthe/on_mob_life(mob/living/carbon/M)
|
||||
if(prob(10) && !M.has_trait(TRAIT_ALCOHOL_TOLERANCE))
|
||||
M.hallucination += 4 //Reference to the urban myth
|
||||
..()
|
||||
@@ -446,7 +445,7 @@ All effects don't start immediately, but rather get worse over time; the rate is
|
||||
glass_name = "Cuba Libre"
|
||||
glass_desc = "A classic mix of rum, cola, and lime. A favorite of revolutionaries everywhere!"
|
||||
|
||||
/datum/reagent/consumable/ethanol/cuba_libre/on_mob_life(mob/living/M)
|
||||
/datum/reagent/consumable/ethanol/cuba_libre/on_mob_life(mob/living/carbon/M)
|
||||
if(M.mind && M.mind.has_antag_datum(/datum/antagonist/rev)) //Cuba Libre, the traditional drink of revolutions! Heals revolutionaries.
|
||||
M.adjustBruteLoss(-1, 0)
|
||||
M.adjustFireLoss(-1, 0)
|
||||
@@ -510,7 +509,7 @@ All effects don't start immediately, but rather get worse over time; the rate is
|
||||
glass_name = "Screwdriver"
|
||||
glass_desc = "A simple, yet superb mixture of Vodka and orange juice. Just the thing for the tired engineer."
|
||||
|
||||
/datum/reagent/consumable/ethanol/screwdrivercocktail/on_mob_life(mob/living/M)
|
||||
/datum/reagent/consumable/ethanol/screwdrivercocktail/on_mob_life(mob/living/carbon/M)
|
||||
if(M.mind && M.mind.assigned_role in list("Station Engineer", "Atmospheric Technician", "Chief Engineer")) //Engineers lose radiation poisoning at a massive rate.
|
||||
M.radiation = max(M.radiation - 25, 0)
|
||||
return ..()
|
||||
@@ -537,11 +536,9 @@ All effects don't start immediately, but rather get worse over time; the rate is
|
||||
glass_name = "Bloody Mary"
|
||||
glass_desc = "Tomato juice, mixed with Vodka and a lil' bit of lime. Tastes like liquid murder."
|
||||
|
||||
/datum/reagent/consumable/ethanol/bloody_mary/on_mob_life(mob/living/M)
|
||||
if(iscarbon(M))
|
||||
var/mob/living/carbon/C = M
|
||||
if(C.blood_volume < BLOOD_VOLUME_NORMAL)
|
||||
C.blood_volume = min(BLOOD_VOLUME_NORMAL, C.blood_volume + 3) //Bloody Mary quickly restores blood loss.
|
||||
/datum/reagent/consumable/ethanol/bloody_mary/on_mob_life(mob/living/carbon/C)
|
||||
if(C.blood_volume < BLOOD_VOLUME_NORMAL)
|
||||
C.blood_volume = min(BLOOD_VOLUME_NORMAL, C.blood_volume + 3) //Bloody Mary quickly restores blood loss.
|
||||
..()
|
||||
|
||||
/datum/reagent/consumable/ethanol/brave_bull
|
||||
@@ -584,7 +581,7 @@ All effects don't start immediately, but rather get worse over time; the rate is
|
||||
light_holder = new(M)
|
||||
light_holder.set_light(3, 0.7, "#FFCC00") //Tequila Sunrise makes you radiate dim light, like a sunrise!
|
||||
|
||||
/datum/reagent/consumable/ethanol/tequila_sunrise/on_mob_life(mob/living/M)
|
||||
/datum/reagent/consumable/ethanol/tequila_sunrise/on_mob_life(mob/living/carbon/M)
|
||||
if(QDELETED(light_holder))
|
||||
M.reagents.del_reagent("tequilasunrise") //If we lost our light object somehow, remove the reagent
|
||||
else if(light_holder.loc != M)
|
||||
@@ -607,7 +604,7 @@ All effects don't start immediately, but rather get worse over time; the rate is
|
||||
glass_desc = "Whoah, this thing is on FIRE!"
|
||||
shot_glass_icon_state = "toxinsspecialglass"
|
||||
|
||||
/datum/reagent/consumable/ethanol/toxins_special/on_mob_life(var/mob/living/M as mob)
|
||||
/datum/reagent/consumable/ethanol/toxins_special/on_mob_life(var/mob/living/M)
|
||||
M.adjust_bodytemperature(15 * TEMPERATURE_DAMAGE_COEFFICIENT, 0, BODYTEMP_NORMAL + 20) //310.15 is the normal bodytemp.
|
||||
return ..()
|
||||
|
||||
@@ -623,7 +620,7 @@ All effects don't start immediately, but rather get worse over time; the rate is
|
||||
glass_name = "Beepsky Smash"
|
||||
glass_desc = "Heavy, hot and strong. Just like the Iron fist of the LAW."
|
||||
|
||||
/datum/reagent/consumable/ethanol/beepsky_smash/on_mob_life(mob/living/M)
|
||||
/datum/reagent/consumable/ethanol/beepsky_smash/on_mob_life(mob/living/carbon/M)
|
||||
if(M.has_trait(TRAIT_ALCOHOL_TOLERANCE))
|
||||
M.Stun(30, 0) //this realistically does nothing to prevent chainstunning but will cause them to recover faster once it's out of their system
|
||||
else
|
||||
@@ -661,7 +658,7 @@ All effects don't start immediately, but rather get worse over time; the rate is
|
||||
boozepwr = 5 //We've had worse in the mines
|
||||
dorf_mode = TRUE
|
||||
|
||||
/datum/reagent/consumable/ethanol/manly_dorf/on_mob_life(mob/living/M)
|
||||
/datum/reagent/consumable/ethanol/manly_dorf/on_mob_life(mob/living/carbon/M)
|
||||
if(dorf_mode)
|
||||
M.adjustBruteLoss(-2)
|
||||
M.adjustFireLoss(-2)
|
||||
@@ -763,7 +760,7 @@ All effects don't start immediately, but rather get worse over time; the rate is
|
||||
glass_desc = "A scientist's drink of choice, for thinking how to blow up the station."
|
||||
|
||||
|
||||
/datum/reagent/consumable/ethanol/manhattan_proj/on_mob_life(mob/living/M)
|
||||
/datum/reagent/consumable/ethanol/manhattan_proj/on_mob_life(mob/living/carbon/M)
|
||||
M.set_drugginess(30)
|
||||
return ..()
|
||||
|
||||
@@ -789,7 +786,7 @@ All effects don't start immediately, but rather get worse over time; the rate is
|
||||
glass_name = "Anti-freeze"
|
||||
glass_desc = "The ultimate refreshment."
|
||||
|
||||
/datum/reagent/consumable/ethanol/antifreeze/on_mob_life(mob/living/M)
|
||||
/datum/reagent/consumable/ethanol/antifreeze/on_mob_life(mob/living/carbon/M)
|
||||
M.adjust_bodytemperature(20 * TEMPERATURE_DAMAGE_COEFFICIENT, 0, BODYTEMP_NORMAL + 20) //310.15 is the normal bodytemp.
|
||||
return ..()
|
||||
|
||||
@@ -804,7 +801,7 @@ All effects don't start immediately, but rather get worse over time; the rate is
|
||||
glass_name = "Barefoot"
|
||||
glass_desc = "Barefoot and pregnant."
|
||||
|
||||
/datum/reagent/consumable/ethanol/barefoot/on_mob_life(mob/living/M)
|
||||
/datum/reagent/consumable/ethanol/barefoot/on_mob_life(mob/living/carbon/M)
|
||||
if(ishuman(M)) //Barefoot causes the imbiber to quickly regenerate brute trauma if they're not wearing shoes.
|
||||
var/mob/living/carbon/human/H = M
|
||||
if(!H.shoes)
|
||||
@@ -902,7 +899,7 @@ All effects don't start immediately, but rather get worse over time; the rate is
|
||||
glass_name = "Sbiten"
|
||||
glass_desc = "A spicy mix of Vodka and Spice. Very hot."
|
||||
|
||||
/datum/reagent/consumable/ethanol/sbiten/on_mob_life(mob/living/M)
|
||||
/datum/reagent/consumable/ethanol/sbiten/on_mob_life(mob/living/carbon/M)
|
||||
M.adjust_bodytemperature(50 * TEMPERATURE_DAMAGE_COEFFICIENT, 0 ,BODYTEMP_HEAT_DAMAGE_LIMIT) //310.15 is the normal bodytemp.
|
||||
return ..()
|
||||
|
||||
@@ -940,7 +937,7 @@ All effects don't start immediately, but rather get worse over time; the rate is
|
||||
glass_name = "iced beer"
|
||||
glass_desc = "A beer so frosty, the air around it freezes."
|
||||
|
||||
/datum/reagent/consumable/ethanol/iced_beer/on_mob_life(mob/living/M)
|
||||
/datum/reagent/consumable/ethanol/iced_beer/on_mob_life(mob/living/carbon/M)
|
||||
M.adjust_bodytemperature(-20 * TEMPERATURE_DAMAGE_COEFFICIENT, T0C) //310.15 is the normal bodytemp.
|
||||
return ..()
|
||||
|
||||
@@ -1022,7 +1019,7 @@ All effects don't start immediately, but rather get worse over time; the rate is
|
||||
glass_name = "Changeling Sting"
|
||||
glass_desc = "A stingy drink."
|
||||
|
||||
/datum/reagent/consumable/ethanol/changelingsting/on_mob_life(mob/living/M)
|
||||
/datum/reagent/consumable/ethanol/changelingsting/on_mob_life(mob/living/carbon/M)
|
||||
if(M.mind) //Changeling Sting assists in the recharging of changeling chemicals.
|
||||
var/datum/antagonist/changeling/changeling = M.mind.has_antag_datum(/datum/antagonist/changeling)
|
||||
if(changeling)
|
||||
@@ -1052,7 +1049,7 @@ All effects don't start immediately, but rather get worse over time; the rate is
|
||||
glass_name = "Syndicate Bomb"
|
||||
glass_desc = "A syndicate bomb."
|
||||
|
||||
/datum/reagent/consumable/ethanol/syndicatebomb/on_mob_life(mob/living/M)
|
||||
/datum/reagent/consumable/ethanol/syndicatebomb/on_mob_life(mob/living/carbon/M)
|
||||
if(prob(5))
|
||||
playsound(get_turf(M), 'sound/effects/explosionfar.ogg', 100, 1)
|
||||
return ..()
|
||||
@@ -1092,8 +1089,8 @@ All effects don't start immediately, but rather get worse over time; the rate is
|
||||
glass_name = "Banana Honk"
|
||||
glass_desc = "A drink from Clown Heaven."
|
||||
|
||||
/datum/reagent/consumable/ethanol/bananahonk/on_mob_life(mob/living/M)
|
||||
if((ishuman(M) && M.job in list("Clown") ) || ismonkey(M))
|
||||
/datum/reagent/consumable/ethanol/bananahonk/on_mob_life(mob/living/carbon/M)
|
||||
if((ishuman(M) && M.job == "Clown") || ismonkey(M))
|
||||
M.heal_bodypart_damage(1,1)
|
||||
. = 1
|
||||
return ..() || .
|
||||
@@ -1110,8 +1107,8 @@ All effects don't start immediately, but rather get worse over time; the rate is
|
||||
glass_name = "Silencer"
|
||||
glass_desc = "A drink from Mime Heaven."
|
||||
|
||||
/datum/reagent/consumable/ethanol/silencer/on_mob_life(mob/living/M)
|
||||
if(ishuman(M) && M.job in list("Mime"))
|
||||
/datum/reagent/consumable/ethanol/silencer/on_mob_life(mob/living/carbon/M)
|
||||
if(ishuman(M) && M.job == "Mime")
|
||||
M.heal_bodypart_damage(1,1)
|
||||
. = 1
|
||||
return ..() || .
|
||||
@@ -1165,7 +1162,7 @@ All effects don't start immediately, but rather get worse over time; the rate is
|
||||
glass_desc = "Induces magnetism in the imbiber. Started as a barroom prank but evolved to become popular with miners and scrappers. Metallic aftertaste."
|
||||
|
||||
|
||||
/datum/reagent/consumable/ethanol/fetching_fizz/on_mob_life(mob/living/M)
|
||||
/datum/reagent/consumable/ethanol/fetching_fizz/on_mob_life(mob/living/carbon/M)
|
||||
for(var/obj/item/stack/ore/O in orange(3, M))
|
||||
step_towards(O, get_turf(M))
|
||||
return ..()
|
||||
@@ -1183,7 +1180,7 @@ All effects don't start immediately, but rather get worse over time; the rate is
|
||||
glass_name = "Hearty Punch"
|
||||
glass_desc = "Aromatic beverage served piping hot. According to folk tales it can almost wake the dead."
|
||||
|
||||
/datum/reagent/consumable/ethanol/hearty_punch/on_mob_life(mob/living/M)
|
||||
/datum/reagent/consumable/ethanol/hearty_punch/on_mob_life(mob/living/carbon/M)
|
||||
if(M.health <= 0)
|
||||
M.adjustBruteLoss(-3, 0)
|
||||
M.adjustFireLoss(-3, 0)
|
||||
@@ -1217,7 +1214,7 @@ All effects don't start immediately, but rather get worse over time; the rate is
|
||||
glass_name = "Atomic Bomb"
|
||||
glass_desc = "Nanotrasen cannot take legal responsibility for your actions after imbibing."
|
||||
|
||||
/datum/reagent/consumable/ethanol/atomicbomb/on_mob_life(mob/living/M)
|
||||
/datum/reagent/consumable/ethanol/atomicbomb/on_mob_life(mob/living/carbon/M)
|
||||
M.set_drugginess(50)
|
||||
if(!M.has_trait(TRAIT_ALCOHOL_TOLERANCE))
|
||||
M.confused = max(M.confused+2,0)
|
||||
@@ -1246,7 +1243,7 @@ All effects don't start immediately, but rather get worse over time; the rate is
|
||||
glass_name = "Pan-Galactic Gargle Blaster"
|
||||
glass_desc = "Like having your brain smashed out by a slice of lemon wrapped around a large gold brick."
|
||||
|
||||
/datum/reagent/consumable/ethanol/gargle_blaster/on_mob_life(mob/living/M)
|
||||
/datum/reagent/consumable/ethanol/gargle_blaster/on_mob_life(mob/living/carbon/M)
|
||||
M.dizziness +=1.5
|
||||
switch(current_cycle)
|
||||
if(15 to 45)
|
||||
@@ -1305,7 +1302,7 @@ All effects don't start immediately, but rather get worse over time; the rate is
|
||||
glass_name = "Hippie's Delight"
|
||||
glass_desc = "A drink enjoyed by people during the 1960's."
|
||||
|
||||
/datum/reagent/consumable/ethanol/hippies_delight/on_mob_life(mob/living/M)
|
||||
/datum/reagent/consumable/ethanol/hippies_delight/on_mob_life(mob/living/carbon/M)
|
||||
if (!M.slurring)
|
||||
M.slurring = 1
|
||||
switch(current_cycle)
|
||||
@@ -1361,7 +1358,7 @@ All effects don't start immediately, but rather get worse over time; the rate is
|
||||
glass_name = "Nar'Sour"
|
||||
glass_desc = "A new hit cocktail inspired by THE ARM Breweries will have you shouting Fuu ma'jin in no time!"
|
||||
|
||||
/datum/reagent/consumable/ethanol/narsour/on_mob_life(mob/living/M)
|
||||
/datum/reagent/consumable/ethanol/narsour/on_mob_life(mob/living/carbon/M)
|
||||
M.cultslurring = min(M.cultslurring + 3, 3)
|
||||
M.stuttering = min(M.stuttering + 3, 3)
|
||||
..()
|
||||
@@ -1410,7 +1407,7 @@ All effects don't start immediately, but rather get worse over time; the rate is
|
||||
glass_name = "Quadruple Sec"
|
||||
glass_desc = "An intimidating and lawful beverage dares you to violate the law and make its day. Still can't drink it on duty, though."
|
||||
|
||||
/datum/reagent/consumable/ethanol/quadruple_sec/on_mob_life(mob/living/M)
|
||||
/datum/reagent/consumable/ethanol/quadruple_sec/on_mob_life(mob/living/carbon/M)
|
||||
if(M.mind && M.mind.assigned_role in list("Security Officer", "Detective", "Head of Security", "Warden", "Lawyer")) //Securidrink in line with the screwderiver for engineers or nothing for mimes.
|
||||
M.heal_bodypart_damage(1, 1)
|
||||
M.adjustBruteLoss(-2,0)
|
||||
@@ -1428,7 +1425,7 @@ All effects don't start immediately, but rather get worse over time; the rate is
|
||||
glass_name = "Quintuple Sec"
|
||||
glass_desc = "Now you are become law, destroyer of clowns."
|
||||
|
||||
/datum/reagent/consumable/ethanol/quintuple_sec/on_mob_life(mob/living/M)
|
||||
/datum/reagent/consumable/ethanol/quintuple_sec/on_mob_life(mob/living/carbon/M)
|
||||
if(M.mind && M.mind.assigned_role in list("Security Officer", "Detective", "Head of Security", "Warden", "Lawyer")) //Securidrink in line with the screwderiver for engineers or nothing for mimes but STRONG..
|
||||
M.heal_bodypart_damage(2,2,2)
|
||||
M.adjustBruteLoss(-5,0)
|
||||
@@ -1510,7 +1507,7 @@ All effects don't start immediately, but rather get worse over time; the rate is
|
||||
glass_desc = "Squirt cider will toughen you right up. Too bad about the musty aftertaste."
|
||||
shot_glass_icon_state = "shotglassgreen"
|
||||
|
||||
/datum/reagent/consumable/ethanol/squirt_cider/on_mob_life(mob/living/M)
|
||||
/datum/reagent/consumable/ethanol/squirt_cider/on_mob_life(mob/living/carbon/M)
|
||||
M.satiety += 5 //for context, vitamins give 30 satiety per tick
|
||||
..()
|
||||
. = TRUE
|
||||
@@ -1538,7 +1535,7 @@ All effects don't start immediately, but rather get worse over time; the rate is
|
||||
glass_name = "Sugar Rush"
|
||||
glass_desc = "If you can't mix a Sugar Rush, you can't tend bar."
|
||||
|
||||
/datum/reagent/consumable/ethanol/sugar_rush/on_mob_life(mob/living/M)
|
||||
/datum/reagent/consumable/ethanol/sugar_rush/on_mob_life(mob/living/carbon/M)
|
||||
M.satiety -= 10 //junky as hell! a whole glass will keep you from being able to eat junk food
|
||||
..()
|
||||
. = TRUE
|
||||
@@ -1579,7 +1576,7 @@ All effects don't start immediately, but rather get worse over time; the rate is
|
||||
glass_name = "Peppermint Patty"
|
||||
glass_desc = "A boozy minty hot cocoa that warms your belly on a cold night."
|
||||
|
||||
/datum/reagent/consumable/ethanol/peppermint_patty/on_mob_life(mob/living/M)
|
||||
/datum/reagent/consumable/ethanol/peppermint_patty/on_mob_life(mob/living/carbon/M)
|
||||
M.adjust_bodytemperature(5 * TEMPERATURE_DAMAGE_COEFFICIENT, 0, BODYTEMP_NORMAL)
|
||||
..()
|
||||
|
||||
@@ -1682,8 +1679,7 @@ All effects don't start immediately, but rather get worse over time; the rate is
|
||||
glass_name = "glass of fernet"
|
||||
glass_desc = "A glass of pure Fernet. Only an absolute madman would drink this alone." //Hi Kevum
|
||||
|
||||
/datum/reagent/consumable/ethanol/fernet/on_mob_life(mob/living/M)
|
||||
|
||||
/datum/reagent/consumable/ethanol/fernet/on_mob_life(mob/living/carbon/M)
|
||||
if(M.nutrition <= NUTRITION_LEVEL_STARVING)
|
||||
M.adjustToxLoss(1*REM, 0)
|
||||
M.nutrition = max(M.nutrition - 5, 0)
|
||||
@@ -1701,8 +1697,7 @@ All effects don't start immediately, but rather get worse over time; the rate is
|
||||
glass_name = "glass of fernet cola"
|
||||
glass_desc = "A sawed-off cola bottle filled with Fernet Cola. Nothing better after eating like a lardass."
|
||||
|
||||
/datum/reagent/consumable/ethanol/fernetcola/on_mob_life(mob/living/M)
|
||||
|
||||
/datum/reagent/consumable/ethanol/fernetcola/on_mob_life(mob/living/carbon/M)
|
||||
if(M.nutrition <= NUTRITION_LEVEL_STARVING)
|
||||
M.adjustToxLoss(0.5*REM, 0)
|
||||
M.nutrition = max(M.nutrition - 3, 0)
|
||||
@@ -1721,8 +1716,7 @@ All effects don't start immediately, but rather get worse over time; the rate is
|
||||
glass_name = "glass of fanciulli"
|
||||
glass_desc = "A glass of Fanciulli. It's just Manhattan with Fernet."
|
||||
|
||||
/datum/reagent/consumable/ethanol/fanciulli/on_mob_life(mob/living/M)
|
||||
|
||||
/datum/reagent/consumable/ethanol/fanciulli/on_mob_life(mob/living/carbon/M)
|
||||
M.nutrition = max(M.nutrition - 5, 0)
|
||||
M.overeatduration = 0
|
||||
return ..()
|
||||
@@ -1746,7 +1740,7 @@ All effects don't start immediately, but rather get worse over time; the rate is
|
||||
glass_desc = "A glass of Branca Menta, perfect for those lazy and hot sunday summer afternoons." //Get lazy literally by drinking this
|
||||
|
||||
|
||||
/datum/reagent/consumable/ethanol/branca_menta/on_mob_life(mob/living/M)
|
||||
/datum/reagent/consumable/ethanol/branca_menta/on_mob_life(mob/living/carbon/M)
|
||||
M.adjust_bodytemperature(-20 * TEMPERATURE_DAMAGE_COEFFICIENT, T0C)
|
||||
return ..()
|
||||
|
||||
|
||||
@@ -199,11 +199,9 @@
|
||||
M.reagents.add_reagent("spore", 0.2*reac_volume)
|
||||
M.apply_damage(0.7*reac_volume, TOX)
|
||||
|
||||
/datum/reagent/blob/regenerative_materia/on_mob_life(mob/living/M)
|
||||
M.adjustToxLoss(1*REM)
|
||||
if(iscarbon(M))
|
||||
var/mob/living/carbon/N = M
|
||||
N.hal_screwyhud = SCREWYHUD_HEALTHY //fully healed, honest
|
||||
/datum/reagent/blob/regenerative_materia/on_mob_life(mob/living/carbon/C)
|
||||
C.adjustToxLoss(1*REM)
|
||||
C.hal_screwyhud = SCREWYHUD_HEALTHY //fully healed, honest
|
||||
..()
|
||||
|
||||
/datum/reagent/blob/regenerative_materia/on_mob_delete(mob/living/M)
|
||||
@@ -346,7 +344,7 @@
|
||||
M.reagents.add_reagent("cryogenic_poison", 0.3*reac_volume)
|
||||
M.apply_damage(0.2*reac_volume, BRUTE)
|
||||
|
||||
/datum/reagent/blob/cryogenic_poison/on_mob_life(mob/living/M)
|
||||
/datum/reagent/blob/cryogenic_poison/on_mob_life(mob/living/carbon/M)
|
||||
M.adjustBruteLoss(0.3*REM, 0)
|
||||
M.adjustFireLoss(0.3*REM, 0)
|
||||
M.adjustToxLoss(0.3*REM, 0)
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
glass_name = "glass of orange juice"
|
||||
glass_desc = "Vitamins! Yay!"
|
||||
|
||||
/datum/reagent/consumable/orangejuice/on_mob_life(mob/living/M)
|
||||
/datum/reagent/consumable/orangejuice/on_mob_life(mob/living/carbon/M)
|
||||
if(M.getOxyLoss() && prob(30))
|
||||
M.adjustOxyLoss(-1, 0)
|
||||
. = 1
|
||||
@@ -30,7 +30,7 @@
|
||||
glass_name = "glass of tomato juice"
|
||||
glass_desc = "Are you sure this is tomato juice?"
|
||||
|
||||
/datum/reagent/consumable/tomatojuice/on_mob_life(mob/living/M)
|
||||
/datum/reagent/consumable/tomatojuice/on_mob_life(mob/living/carbon/M)
|
||||
if(M.getFireLoss() && prob(20))
|
||||
M.heal_bodypart_damage(0,1, 0)
|
||||
. = 1
|
||||
@@ -46,7 +46,7 @@
|
||||
glass_name = "glass of lime juice"
|
||||
glass_desc = "A glass of sweet-sour lime juice."
|
||||
|
||||
/datum/reagent/consumable/limejuice/on_mob_life(mob/living/M)
|
||||
/datum/reagent/consumable/limejuice/on_mob_life(mob/living/carbon/M)
|
||||
if(M.getToxLoss() && prob(20))
|
||||
M.adjustToxLoss(-1*REM, 0)
|
||||
. = 1
|
||||
@@ -62,7 +62,7 @@
|
||||
glass_name = "glass of carrot juice"
|
||||
glass_desc = "It's just like a carrot but without crunching."
|
||||
|
||||
/datum/reagent/consumable/carrotjuice/on_mob_life(mob/living/M)
|
||||
/datum/reagent/consumable/carrotjuice/on_mob_life(mob/living/carbon/M)
|
||||
M.adjust_blurriness(-1)
|
||||
M.adjust_blindness(-1)
|
||||
switch(current_cycle)
|
||||
@@ -101,7 +101,7 @@
|
||||
glass_name = "glass of berry juice"
|
||||
glass_desc = "Berry juice. Or maybe it's poison. Who cares?"
|
||||
|
||||
/datum/reagent/consumable/poisonberryjuice/on_mob_life(mob/living/M)
|
||||
/datum/reagent/consumable/poisonberryjuice/on_mob_life(mob/living/carbon/M)
|
||||
M.adjustToxLoss(1, 0)
|
||||
. = 1
|
||||
..()
|
||||
@@ -136,8 +136,8 @@
|
||||
glass_name = "glass of banana juice"
|
||||
glass_desc = "The raw essence of a banana. HONK."
|
||||
|
||||
/datum/reagent/consumable/banana/on_mob_life(mob/living/M)
|
||||
if((ishuman(M) && M.job in list("Clown") ) || ismonkey(M))
|
||||
/datum/reagent/consumable/banana/on_mob_life(mob/living/carbon/M)
|
||||
if((ishuman(M) && M.job == "Clown") || ismonkey(M))
|
||||
M.heal_bodypart_damage(1,1, 0)
|
||||
. = 1
|
||||
..()
|
||||
@@ -152,8 +152,8 @@
|
||||
glass_desc = "Absolutely nothing."
|
||||
shot_glass_icon_state = "shotglass"
|
||||
|
||||
/datum/reagent/consumable/nothing/on_mob_life(mob/living/M)
|
||||
if(ishuman(M) && M.job in list("Mime"))
|
||||
/datum/reagent/consumable/nothing/on_mob_life(mob/living/carbon/M)
|
||||
if(ishuman(M) && M.job == "Mime")
|
||||
M.heal_bodypart_damage(1,1, 0)
|
||||
. = 1
|
||||
..()
|
||||
@@ -167,8 +167,6 @@
|
||||
taste_description = "laughter"
|
||||
|
||||
/datum/reagent/consumable/laughter/on_mob_life(mob/living/carbon/M)
|
||||
if(!iscarbon(M))
|
||||
return
|
||||
M.emote("laugh")
|
||||
..()
|
||||
|
||||
@@ -181,8 +179,6 @@
|
||||
taste_description = "laughter"
|
||||
|
||||
/datum/reagent/consumable/superlaughter/on_mob_life(mob/living/carbon/M)
|
||||
if(!iscarbon(M))
|
||||
return
|
||||
if(prob(30))
|
||||
M.visible_message("<span class='danger'>[M] bursts out into a fit of uncontrollable laughter!</span>", "<span class='userdanger'>You burst out in a fit of uncontrollable laughter!</span>")
|
||||
M.Stun(5)
|
||||
@@ -216,7 +212,7 @@
|
||||
glass_name = "glass of milk"
|
||||
glass_desc = "White and nutritious goodness!"
|
||||
|
||||
/datum/reagent/consumable/milk/on_mob_life(mob/living/M)
|
||||
/datum/reagent/consumable/milk/on_mob_life(mob/living/carbon/M)
|
||||
if(M.getBruteLoss() && prob(20))
|
||||
M.heal_bodypart_damage(1,0, 0)
|
||||
. = 1
|
||||
@@ -238,7 +234,7 @@
|
||||
glass_name = "glass of soy milk"
|
||||
glass_desc = "White and nutritious soy goodness!"
|
||||
|
||||
/datum/reagent/consumable/soymilk/on_mob_life(mob/living/M)
|
||||
/datum/reagent/consumable/soymilk/on_mob_life(mob/living/carbon/M)
|
||||
if(M.getBruteLoss() && prob(20))
|
||||
M.heal_bodypart_damage(1,0, 0)
|
||||
. = 1
|
||||
@@ -254,7 +250,7 @@
|
||||
glass_name = "glass of cream"
|
||||
glass_desc = "Ewwww..."
|
||||
|
||||
/datum/reagent/consumable/cream/on_mob_life(mob/living/M)
|
||||
/datum/reagent/consumable/cream/on_mob_life(mob/living/carbon/M)
|
||||
if(M.getBruteLoss() && prob(20))
|
||||
M.heal_bodypart_damage(1,0, 0)
|
||||
. = 1
|
||||
@@ -276,7 +272,7 @@
|
||||
M.Jitter(5)
|
||||
..()
|
||||
|
||||
/datum/reagent/consumable/coffee/on_mob_life(mob/living/M)
|
||||
/datum/reagent/consumable/coffee/on_mob_life(mob/living/carbon/M)
|
||||
M.dizziness = max(0,M.dizziness-5)
|
||||
M.drowsyness = max(0,M.drowsyness-3)
|
||||
M.AdjustSleeping(-40, FALSE)
|
||||
@@ -298,7 +294,7 @@
|
||||
glass_name = "glass of tea"
|
||||
glass_desc = "Drinking it from here would not seem right."
|
||||
|
||||
/datum/reagent/consumable/tea/on_mob_life(mob/living/M)
|
||||
/datum/reagent/consumable/tea/on_mob_life(mob/living/carbon/M)
|
||||
M.dizziness = max(0,M.dizziness-2)
|
||||
M.drowsyness = max(0,M.drowsyness-1)
|
||||
M.jitteriness = max(0,M.jitteriness-3)
|
||||
@@ -320,7 +316,7 @@
|
||||
glass_name = "Arnold Palmer"
|
||||
glass_desc = "You feel like taking a few golf swings after a few swigs of this."
|
||||
|
||||
/datum/reagent/consumable/tea/arnold_palmer/on_mob_life(mob/living/M)
|
||||
/datum/reagent/consumable/tea/arnold_palmer/on_mob_life(mob/living/carbon/M)
|
||||
if(prob(5))
|
||||
to_chat(M, "<span class = 'notice'>[pick("You remember to square your shoulders.","You remember to keep your head down.","You can't decide between squaring your shoulders and keeping your head down.","You remember to relax.","You think about how someday you'll get two strokes off your golf game.")]</span>")
|
||||
..()
|
||||
@@ -337,7 +333,7 @@
|
||||
glass_name = "iced coffee"
|
||||
glass_desc = "A drink to perk you up and refresh you!"
|
||||
|
||||
/datum/reagent/consumable/icecoffee/on_mob_life(mob/living/M)
|
||||
/datum/reagent/consumable/icecoffee/on_mob_life(mob/living/carbon/M)
|
||||
M.dizziness = max(0,M.dizziness-5)
|
||||
M.drowsyness = max(0,M.drowsyness-3)
|
||||
M.AdjustSleeping(-40, FALSE)
|
||||
@@ -357,7 +353,7 @@
|
||||
glass_name = "iced tea"
|
||||
glass_desc = "All natural, antioxidant-rich flavour sensation."
|
||||
|
||||
/datum/reagent/consumable/icetea/on_mob_life(mob/living/M)
|
||||
/datum/reagent/consumable/icetea/on_mob_life(mob/living/carbon/M)
|
||||
M.dizziness = max(0,M.dizziness-2)
|
||||
M.drowsyness = max(0,M.drowsyness-1)
|
||||
M.AdjustSleeping(-40, FALSE)
|
||||
@@ -377,7 +373,7 @@
|
||||
glass_name = "glass of Space Cola"
|
||||
glass_desc = "A glass of refreshing Space Cola."
|
||||
|
||||
/datum/reagent/consumable/space_cola/on_mob_life(mob/living/M)
|
||||
/datum/reagent/consumable/space_cola/on_mob_life(mob/living/carbon/M)
|
||||
M.drowsyness = max(0,M.drowsyness-5)
|
||||
M.adjust_bodytemperature(-5 * TEMPERATURE_DAMAGE_COEFFICIENT, BODYTEMP_NORMAL)
|
||||
..()
|
||||
@@ -392,19 +388,15 @@
|
||||
glass_name = "glass of Nuka Cola"
|
||||
glass_desc = "Don't cry, Don't raise your eye, It's only nuclear wasteland."
|
||||
|
||||
/datum/reagent/consumable/nuka_cola/on_mob_add(mob/M)
|
||||
/datum/reagent/consumable/nuka_cola/on_mob_add(mob/living/L)
|
||||
..()
|
||||
if(isliving(M))
|
||||
var/mob/living/L = M
|
||||
L.add_trait(TRAIT_GOTTAGOFAST, id)
|
||||
L.add_trait(TRAIT_GOTTAGOFAST, id)
|
||||
|
||||
/datum/reagent/consumable/nuka_cola/on_mob_delete(mob/M)
|
||||
if(isliving(M))
|
||||
var/mob/living/L = M
|
||||
L.remove_trait(TRAIT_GOTTAGOFAST, id)
|
||||
/datum/reagent/consumable/nuka_cola/on_mob_delete(mob/living/L)
|
||||
L.remove_trait(TRAIT_GOTTAGOFAST, id)
|
||||
..()
|
||||
|
||||
/datum/reagent/consumable/nuka_cola/on_mob_life(mob/living/M)
|
||||
/datum/reagent/consumable/nuka_cola/on_mob_life(mob/living/carbon/M)
|
||||
M.Jitter(20)
|
||||
M.set_drugginess(30)
|
||||
M.dizziness +=1.5
|
||||
@@ -424,7 +416,7 @@
|
||||
glass_name = "glass of Space Mountain Wind"
|
||||
glass_desc = "Space Mountain Wind. As you know, there are no mountains in space, only wind."
|
||||
|
||||
/datum/reagent/consumable/spacemountainwind/on_mob_life(mob/living/M)
|
||||
/datum/reagent/consumable/spacemountainwind/on_mob_life(mob/living/carbon/M)
|
||||
M.drowsyness = max(0,M.drowsyness-7)
|
||||
M.AdjustSleeping(-20, FALSE)
|
||||
M.adjust_bodytemperature(-5 * TEMPERATURE_DAMAGE_COEFFICIENT, BODYTEMP_NORMAL)
|
||||
@@ -442,7 +434,7 @@
|
||||
glass_name = "glass of Dr. Gibb"
|
||||
glass_desc = "Dr. Gibb. Not as dangerous as the glass_name might imply."
|
||||
|
||||
/datum/reagent/consumable/dr_gibb/on_mob_life(mob/living/M)
|
||||
/datum/reagent/consumable/dr_gibb/on_mob_life(mob/living/carbon/M)
|
||||
M.drowsyness = max(0,M.drowsyness-6)
|
||||
M.adjust_bodytemperature(-5 * TEMPERATURE_DAMAGE_COEFFICIENT, BODYTEMP_NORMAL)
|
||||
..()
|
||||
@@ -458,7 +450,7 @@
|
||||
glass_desc = "Space-up. It helps you keep your cool."
|
||||
|
||||
|
||||
/datum/reagent/consumable/space_up/on_mob_life(mob/living/M)
|
||||
/datum/reagent/consumable/space_up/on_mob_life(mob/living/carbon/M)
|
||||
M.adjust_bodytemperature(-8 * TEMPERATURE_DAMAGE_COEFFICIENT, BODYTEMP_NORMAL)
|
||||
..()
|
||||
|
||||
@@ -473,7 +465,7 @@
|
||||
glass_desc = "You're pretty certain a real fruit has never actually touched this."
|
||||
|
||||
|
||||
/datum/reagent/consumable/lemon_lime/on_mob_life(mob/living/M)
|
||||
/datum/reagent/consumable/lemon_lime/on_mob_life(mob/living/carbon/M)
|
||||
M.adjust_bodytemperature(-8 * TEMPERATURE_DAMAGE_COEFFICIENT, BODYTEMP_NORMAL)
|
||||
..()
|
||||
|
||||
@@ -487,7 +479,7 @@
|
||||
glass_name = "glass of Pwr Game"
|
||||
glass_desc = "Goes well with a Vlad's salad."
|
||||
|
||||
/datum/reagent/consumable/pwr_game/on_mob_life(mob/living/M)
|
||||
/datum/reagent/consumable/pwr_game/on_mob_life(mob/living/carbon/M)
|
||||
M.adjust_bodytemperature(-8 * TEMPERATURE_DAMAGE_COEFFICIENT, BODYTEMP_NORMAL)
|
||||
..()
|
||||
|
||||
@@ -501,7 +493,7 @@
|
||||
glass_name = "glass of Shambler's juice"
|
||||
glass_desc = "Mmm mm, shambly."
|
||||
|
||||
/datum/reagent/consumable/shamblers/on_mob_life(mob/living/M)
|
||||
/datum/reagent/consumable/shamblers/on_mob_life(mob/living/carbon/M)
|
||||
M.adjust_bodytemperature(-8 * TEMPERATURE_DAMAGE_COEFFICIENT, BODYTEMP_NORMAL)
|
||||
..()
|
||||
/datum/reagent/consumable/sodawater
|
||||
@@ -514,7 +506,7 @@
|
||||
glass_name = "glass of soda water"
|
||||
glass_desc = "Soda water. Why not make a scotch and soda?"
|
||||
|
||||
/datum/reagent/consumable/sodawater/on_mob_life(mob/living/M)
|
||||
/datum/reagent/consumable/sodawater/on_mob_life(mob/living/carbon/M)
|
||||
M.dizziness = max(0,M.dizziness-5)
|
||||
M.drowsyness = max(0,M.drowsyness-3)
|
||||
M.adjust_bodytemperature(-5 * TEMPERATURE_DAMAGE_COEFFICIENT, BODYTEMP_NORMAL)
|
||||
@@ -530,7 +522,7 @@
|
||||
glass_name = "glass of tonic water"
|
||||
glass_desc = "Quinine tastes funny, but at least it'll keep that Space Malaria away."
|
||||
|
||||
/datum/reagent/consumable/tonic/on_mob_life(mob/living/M)
|
||||
/datum/reagent/consumable/tonic/on_mob_life(mob/living/carbon/M)
|
||||
M.dizziness = max(0,M.dizziness-5)
|
||||
M.drowsyness = max(0,M.drowsyness-3)
|
||||
M.AdjustSleeping(-40, FALSE)
|
||||
@@ -549,7 +541,7 @@
|
||||
glass_name = "glass of ice"
|
||||
glass_desc = "Generally, you're supposed to put something else in there too..."
|
||||
|
||||
/datum/reagent/consumable/ice/on_mob_life(mob/living/M)
|
||||
/datum/reagent/consumable/ice/on_mob_life(mob/living/carbon/M)
|
||||
M.adjust_bodytemperature(-5 * TEMPERATURE_DAMAGE_COEFFICIENT, BODYTEMP_NORMAL)
|
||||
..()
|
||||
|
||||
@@ -563,7 +555,7 @@
|
||||
glass_name = "soy latte"
|
||||
glass_desc = "A nice and refreshing beverage while you're reading."
|
||||
|
||||
/datum/reagent/consumable/soy_latte/on_mob_life(mob/living/M)
|
||||
/datum/reagent/consumable/soy_latte/on_mob_life(mob/living/carbon/M)
|
||||
M.dizziness = max(0,M.dizziness-5)
|
||||
M.drowsyness = max(0,M.drowsyness-3)
|
||||
M.SetSleeping(0, FALSE)
|
||||
@@ -584,7 +576,7 @@
|
||||
glass_name = "cafe latte"
|
||||
glass_desc = "A nice, strong and refreshing beverage while you're reading."
|
||||
|
||||
/datum/reagent/consumable/cafe_latte/on_mob_life(mob/living/M)
|
||||
/datum/reagent/consumable/cafe_latte/on_mob_life(mob/living/carbon/M)
|
||||
M.dizziness = max(0,M.dizziness-5)
|
||||
M.drowsyness = max(0,M.drowsyness-3)
|
||||
M.SetSleeping(0, FALSE)
|
||||
@@ -605,7 +597,7 @@
|
||||
glass_name = "Doctor's Delight"
|
||||
glass_desc = "The space doctor's favorite. Guaranteed to restore bodily injury; side effects include cravings and hunger."
|
||||
|
||||
/datum/reagent/consumable/doctor_delight/on_mob_life(mob/living/M)
|
||||
/datum/reagent/consumable/doctor_delight/on_mob_life(mob/living/carbon/M)
|
||||
M.adjustBruteLoss(-0.5, 0)
|
||||
M.adjustFireLoss(-0.5, 0)
|
||||
M.adjustToxLoss(-0.5, 0)
|
||||
@@ -739,4 +731,4 @@
|
||||
color = "#EA1D26"
|
||||
taste_description = "sweet pomegranates"
|
||||
glass_name = "glass of grenadine"
|
||||
glass_desc = "Delicious flavored syrup."
|
||||
glass_desc = "Delicious flavored syrup."
|
||||
|
||||
@@ -16,7 +16,7 @@
|
||||
color = "#60A584" // rgb: 96, 165, 132
|
||||
overdose_threshold = 30
|
||||
|
||||
/datum/reagent/drug/space_drugs/on_mob_life(mob/living/M)
|
||||
/datum/reagent/drug/space_drugs/on_mob_life(mob/living/carbon/M)
|
||||
M.set_drugginess(15)
|
||||
if(isturf(M.loc) && !isspaceturf(M.loc))
|
||||
if(M.canmove)
|
||||
@@ -45,7 +45,7 @@
|
||||
taste_description = "smoke"
|
||||
trippy = FALSE
|
||||
|
||||
/datum/reagent/drug/nicotine/on_mob_life(mob/living/M)
|
||||
/datum/reagent/drug/nicotine/on_mob_life(mob/living/carbon/M)
|
||||
if(prob(1))
|
||||
var/smoke_message = pick("You feel relaxed.", "You feel calmed.","You feel alert.","You feel rugged.")
|
||||
to_chat(M, "<span class='notice'>[smoke_message]</span>")
|
||||
@@ -66,7 +66,7 @@
|
||||
overdose_threshold = 20
|
||||
addiction_threshold = 10
|
||||
|
||||
/datum/reagent/drug/crank/on_mob_life(mob/living/M)
|
||||
/datum/reagent/drug/crank/on_mob_life(mob/living/carbon/M)
|
||||
if(prob(5))
|
||||
var/high_message = pick("You feel jittery.", "You feel like you gotta go fast.", "You feel like you need to step it up.")
|
||||
to_chat(M, "<span class='notice'>[high_message]</span>")
|
||||
@@ -114,7 +114,7 @@
|
||||
addiction_threshold = 15
|
||||
|
||||
|
||||
/datum/reagent/drug/krokodil/on_mob_life(mob/living/M)
|
||||
/datum/reagent/drug/krokodil/on_mob_life(mob/living/carbon/M)
|
||||
var/high_message = pick("You feel calm.", "You feel collected.", "You feel like you need to relax.")
|
||||
if(prob(5))
|
||||
to_chat(M, "<span class='notice'>[high_message]</span>")
|
||||
@@ -165,19 +165,15 @@
|
||||
addiction_threshold = 10
|
||||
metabolization_rate = 0.75 * REAGENTS_METABOLISM
|
||||
|
||||
/datum/reagent/drug/methamphetamine/on_mob_add(mob/M)
|
||||
/datum/reagent/drug/methamphetamine/on_mob_add(mob/living/L)
|
||||
..()
|
||||
if(isliving(M))
|
||||
var/mob/living/L = M
|
||||
L.add_trait(TRAIT_GOTTAGOREALLYFAST, id)
|
||||
L.add_trait(TRAIT_GOTTAGOREALLYFAST, id)
|
||||
|
||||
/datum/reagent/drug/methamphetamine/on_mob_delete(mob/M)
|
||||
if(isliving(M))
|
||||
var/mob/living/L = M
|
||||
L.remove_trait(TRAIT_GOTTAGOREALLYFAST, id)
|
||||
/datum/reagent/drug/methamphetamine/on_mob_delete(mob/living/L)
|
||||
L.remove_trait(TRAIT_GOTTAGOREALLYFAST, id)
|
||||
..()
|
||||
|
||||
/datum/reagent/drug/methamphetamine/on_mob_life(mob/living/M)
|
||||
/datum/reagent/drug/methamphetamine/on_mob_life(mob/living/carbon/M)
|
||||
var/high_message = pick("You feel hyper.", "You feel like you need to go faster.", "You feel like you can run the world.")
|
||||
if(prob(5))
|
||||
to_chat(M, "<span class='notice'>[high_message]</span>")
|
||||
@@ -252,27 +248,23 @@
|
||||
taste_description = "salt" // because they're bathsalts?
|
||||
var/datum/brain_trauma/special/psychotic_brawling/bath_salts/rage
|
||||
|
||||
/datum/reagent/drug/bath_salts/on_mob_add(mob/M)
|
||||
/datum/reagent/drug/bath_salts/on_mob_add(mob/living/L)
|
||||
..()
|
||||
if(isliving(M))
|
||||
var/mob/living/L = M
|
||||
L.add_trait(TRAIT_STUNIMMUNE, id)
|
||||
L.add_trait(TRAIT_SLEEPIMMUNE, id)
|
||||
if(iscarbon(L))
|
||||
var/mob/living/carbon/C = L
|
||||
rage = new()
|
||||
C.gain_trauma(rage, TRAUMA_RESILIENCE_ABSOLUTE)
|
||||
L.add_trait(TRAIT_STUNIMMUNE, id)
|
||||
L.add_trait(TRAIT_SLEEPIMMUNE, id)
|
||||
if(iscarbon(L))
|
||||
var/mob/living/carbon/C = L
|
||||
rage = new()
|
||||
C.gain_trauma(rage, TRAUMA_RESILIENCE_ABSOLUTE)
|
||||
|
||||
/datum/reagent/drug/bath_salts/on_mob_delete(mob/M)
|
||||
if(isliving(M))
|
||||
var/mob/living/L = M
|
||||
L.remove_trait(TRAIT_STUNIMMUNE, id)
|
||||
L.remove_trait(TRAIT_SLEEPIMMUNE, id)
|
||||
if(rage)
|
||||
QDEL_NULL(rage)
|
||||
/datum/reagent/drug/bath_salts/on_mob_delete(mob/living/L)
|
||||
L.remove_trait(TRAIT_STUNIMMUNE, id)
|
||||
L.remove_trait(TRAIT_SLEEPIMMUNE, id)
|
||||
if(rage)
|
||||
QDEL_NULL(rage)
|
||||
..()
|
||||
|
||||
/datum/reagent/drug/bath_salts/on_mob_life(mob/living/M)
|
||||
/datum/reagent/drug/bath_salts/on_mob_life(mob/living/carbon/M)
|
||||
var/high_message = pick("You feel amped up.", "You feel ready.", "You feel like you can push it to the limit.")
|
||||
if(prob(5))
|
||||
to_chat(M, "<span class='notice'>[high_message]</span>")
|
||||
@@ -352,7 +344,7 @@
|
||||
reagent_state = LIQUID
|
||||
color = "#78FFF0"
|
||||
|
||||
/datum/reagent/drug/aranesp/on_mob_life(mob/living/M)
|
||||
/datum/reagent/drug/aranesp/on_mob_life(mob/living/carbon/M)
|
||||
var/high_message = pick("You feel amped up.", "You feel ready.", "You feel like you can push it to the limit.")
|
||||
if(prob(5))
|
||||
to_chat(M, "<span class='notice'>[high_message]</span>")
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
taste_mult = 4
|
||||
var/nutriment_factor = 1 * REAGENTS_METABOLISM
|
||||
|
||||
/datum/reagent/consumable/on_mob_life(mob/living/M)
|
||||
/datum/reagent/consumable/on_mob_life(mob/living/carbon/M)
|
||||
current_cycle++
|
||||
M.nutrition += nutriment_factor
|
||||
holder.remove_reagent(src.id, metabolization_rate)
|
||||
@@ -30,7 +30,7 @@
|
||||
var/brute_heal = 1
|
||||
var/burn_heal = 0
|
||||
|
||||
/datum/reagent/consumable/nutriment/on_mob_life(mob/living/M)
|
||||
/datum/reagent/consumable/nutriment/on_mob_life(mob/living/carbon/M)
|
||||
if(prob(50))
|
||||
M.heal_bodypart_damage(brute_heal,burn_heal, 0)
|
||||
. = 1
|
||||
@@ -78,7 +78,7 @@
|
||||
brute_heal = 1
|
||||
burn_heal = 1
|
||||
|
||||
/datum/reagent/consumable/nutriment/vitamin/on_mob_life(mob/living/M)
|
||||
/datum/reagent/consumable/nutriment/vitamin/on_mob_life(mob/living/carbon/M)
|
||||
if(M.satiety < 600)
|
||||
M.satiety += 30
|
||||
. = ..()
|
||||
@@ -183,7 +183,7 @@
|
||||
taste_description = "hot peppers"
|
||||
taste_mult = 1.5
|
||||
|
||||
/datum/reagent/consumable/capsaicin/on_mob_life(mob/living/M)
|
||||
/datum/reagent/consumable/capsaicin/on_mob_life(mob/living/carbon/M)
|
||||
var/heating = 0
|
||||
switch(current_cycle)
|
||||
if(1 to 15)
|
||||
@@ -214,7 +214,7 @@
|
||||
color = "#8BA6E9" // rgb: 139, 166, 233
|
||||
taste_description = "mint"
|
||||
|
||||
/datum/reagent/consumable/frostoil/on_mob_life(mob/living/M)
|
||||
/datum/reagent/consumable/frostoil/on_mob_life(mob/living/carbon/M)
|
||||
var/cooling = 0
|
||||
switch(current_cycle)
|
||||
if(1 to 15)
|
||||
@@ -320,7 +320,7 @@
|
||||
victim.Knockdown(100)
|
||||
victim.update_damage_hud()
|
||||
|
||||
/datum/reagent/consumable/condensedcapsaicin/on_mob_life(mob/living/M)
|
||||
/datum/reagent/consumable/condensedcapsaicin/on_mob_life(mob/living/carbon/M)
|
||||
if(prob(5))
|
||||
M.visible_message("<span class='warning'>[M] [pick("dry heaves!","coughs!","splutters!")]</span>")
|
||||
..()
|
||||
@@ -374,7 +374,7 @@
|
||||
glass_name = "glass of chocolate"
|
||||
glass_desc = "Tasty."
|
||||
|
||||
/datum/reagent/consumable/hot_coco/on_mob_life(mob/living/M)
|
||||
/datum/reagent/consumable/hot_coco/on_mob_life(mob/living/carbon/M)
|
||||
M.adjust_bodytemperature(5 * TEMPERATURE_DAMAGE_COEFFICIENT, 0, BODYTEMP_NORMAL)
|
||||
..()
|
||||
|
||||
@@ -386,7 +386,7 @@
|
||||
metabolization_rate = 0.2 * REAGENTS_METABOLISM
|
||||
taste_description = "mushroom"
|
||||
|
||||
/datum/reagent/mushroomhallucinogen/on_mob_life(mob/living/M)
|
||||
/datum/reagent/mushroomhallucinogen/on_mob_life(mob/living/carbon/M)
|
||||
if(!M.slurring)
|
||||
M.slurring = 1
|
||||
switch(current_cycle)
|
||||
@@ -416,7 +416,7 @@
|
||||
color = "#FF00FF" // rgb: 255, 0, 255
|
||||
taste_description = "childhood whimsy"
|
||||
|
||||
/datum/reagent/consumable/sprinkles/on_mob_life(mob/living/M)
|
||||
/datum/reagent/consumable/sprinkles/on_mob_life(mob/living/carbon/M)
|
||||
if(ishuman(M) && M.job in list("Security Officer", "Head of Security", "Detective", "Warden"))
|
||||
M.heal_bodypart_damage(1,1, 0)
|
||||
. = 1
|
||||
@@ -465,7 +465,7 @@
|
||||
color = "#302000" // rgb: 48, 32, 0
|
||||
taste_description = "wet and cheap noodles"
|
||||
|
||||
/datum/reagent/consumable/hot_ramen/on_mob_life(mob/living/M)
|
||||
/datum/reagent/consumable/hot_ramen/on_mob_life(mob/living/carbon/M)
|
||||
M.adjust_bodytemperature(10 * TEMPERATURE_DAMAGE_COEFFICIENT, 0, BODYTEMP_NORMAL)
|
||||
..()
|
||||
|
||||
@@ -477,7 +477,7 @@
|
||||
color = "#302000" // rgb: 48, 32, 0
|
||||
taste_description = "wet and cheap noodles on fire"
|
||||
|
||||
/datum/reagent/consumable/hell_ramen/on_mob_life(mob/living/M)
|
||||
/datum/reagent/consumable/hell_ramen/on_mob_life(mob/living/carbon/M)
|
||||
M.adjust_bodytemperature(10 * TEMPERATURE_DAMAGE_COEFFICIENT)
|
||||
..()
|
||||
|
||||
@@ -549,7 +549,7 @@
|
||||
metabolization_rate = 3 * REAGENTS_METABOLISM
|
||||
taste_description = "sweet slime"
|
||||
|
||||
/datum/reagent/consumable/corn_syrup/on_mob_life(mob/living/M)
|
||||
/datum/reagent/consumable/corn_syrup/on_mob_life(mob/living/carbon/M)
|
||||
holder.add_reagent("sugar", 3)
|
||||
..()
|
||||
|
||||
@@ -562,7 +562,7 @@
|
||||
metabolization_rate = 1 * REAGENTS_METABOLISM
|
||||
taste_description = "sweetness"
|
||||
|
||||
/datum/reagent/consumable/honey/on_mob_life(mob/living/M)
|
||||
/datum/reagent/consumable/honey/on_mob_life(mob/living/carbon/M)
|
||||
M.reagents.add_reagent("sugar",3)
|
||||
if(prob(55))
|
||||
M.adjustBruteLoss(-1*REM, 0)
|
||||
@@ -615,7 +615,7 @@
|
||||
M.blur_eyes(5)
|
||||
..()
|
||||
|
||||
/datum/reagent/consumable/tearjuice/on_mob_life(mob/living/M)
|
||||
/datum/reagent/consumable/tearjuice/on_mob_life(mob/living/carbon/M)
|
||||
..()
|
||||
if(M.eye_blurry) //Don't worsen vision if it was otherwise fine
|
||||
M.blur_eyes(4)
|
||||
@@ -632,7 +632,7 @@
|
||||
nutriment_factor = 15 * REAGENTS_METABOLISM
|
||||
color = "#664330" // rgb: 102, 67, 48
|
||||
|
||||
/datum/reagent/consumable/nutriment/stabilized/on_mob_life(mob/living/M)
|
||||
/datum/reagent/consumable/nutriment/stabilized/on_mob_life(mob/living/carbon/M)
|
||||
if(M.nutrition > NUTRITION_LEVEL_FULL - 25)
|
||||
M.nutrition -= 3*nutriment_factor
|
||||
..()
|
||||
@@ -647,7 +647,7 @@
|
||||
color = "#1d043d"
|
||||
taste_description = "bitter mushroom"
|
||||
|
||||
/datum/reagent/consumable/entpoly/on_mob_life(mob/living/M)
|
||||
/datum/reagent/consumable/entpoly/on_mob_life(mob/living/carbon/M)
|
||||
if(current_cycle >= 10)
|
||||
M.Unconscious(40, 0)
|
||||
. = 1
|
||||
@@ -681,7 +681,7 @@
|
||||
nutriment_factor = 3 * REAGENTS_METABOLISM
|
||||
taste_description = "fruity mushroom"
|
||||
|
||||
/datum/reagent/consumable/vitfro/on_mob_life(mob/living/M)
|
||||
/datum/reagent/consumable/vitfro/on_mob_life(mob/living/carbon/M)
|
||||
if(prob(80))
|
||||
M.adjustBruteLoss(-1*REM, 0)
|
||||
M.adjustFireLoss(-1*REM, 0)
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
id = "medicine"
|
||||
taste_description = "bitterness"
|
||||
|
||||
/datum/reagent/medicine/on_mob_life(mob/living/M)
|
||||
/datum/reagent/medicine/on_mob_life(mob/living/carbon/M)
|
||||
current_cycle++
|
||||
holder.remove_reagent(src.id, metabolization_rate / M.metabolism_efficiency) //medicine reagents stay longer if you have a better metabolism
|
||||
|
||||
@@ -20,7 +20,7 @@
|
||||
description = "Leporazine will effectively regulate a patient's body temperature, ensuring it never leaves safe levels."
|
||||
color = "#C8A5DC" // rgb: 200, 165, 220
|
||||
|
||||
/datum/reagent/medicine/leporazine/on_mob_life(mob/living/M)
|
||||
/datum/reagent/medicine/leporazine/on_mob_life(mob/living/carbon/M)
|
||||
if(M.bodytemperature > BODYTEMP_NORMAL)
|
||||
M.adjust_bodytemperature(-40 * TEMPERATURE_DAMAGE_COEFFICIENT, BODYTEMP_NORMAL)
|
||||
else if(M.bodytemperature < (BODYTEMP_NORMAL + 1))
|
||||
@@ -80,7 +80,7 @@
|
||||
description = "Increases resistance to stuns as well as reducing drowsiness and hallucinations."
|
||||
color = "#FF00FF"
|
||||
|
||||
/datum/reagent/medicine/synaptizine/on_mob_life(mob/living/M)
|
||||
/datum/reagent/medicine/synaptizine/on_mob_life(mob/living/carbon/M)
|
||||
M.drowsyness = max(M.drowsyness-5, 0)
|
||||
M.AdjustStun(-20, 0)
|
||||
M.AdjustKnockdown(-20, 0)
|
||||
@@ -99,7 +99,7 @@
|
||||
description = "Reduces drowsiness, hallucinations, and Histamine from body."
|
||||
color = "#EC536D" // rgb: 236, 83, 109
|
||||
|
||||
/datum/reagent/medicine/synaphydramine/on_mob_life(mob/living/M)
|
||||
/datum/reagent/medicine/synaphydramine/on_mob_life(mob/living/carbon/M)
|
||||
M.drowsyness = max(M.drowsyness-5, 0)
|
||||
if(holder.has_reagent("mindbreaker"))
|
||||
holder.remove_reagent("mindbreaker", 5)
|
||||
@@ -117,7 +117,7 @@
|
||||
description = "Instantly restores all hearing to the patient, but does not cure deafness."
|
||||
color = "#6600FF" // rgb: 100, 165, 255
|
||||
|
||||
/datum/reagent/medicine/inacusiate/on_mob_life(mob/living/M)
|
||||
/datum/reagent/medicine/inacusiate/on_mob_life(mob/living/carbon/M)
|
||||
M.restoreEars()
|
||||
..()
|
||||
|
||||
@@ -128,7 +128,7 @@
|
||||
color = "#0000C8"
|
||||
taste_description = "sludge"
|
||||
|
||||
/datum/reagent/medicine/cryoxadone/on_mob_life(mob/living/M)
|
||||
/datum/reagent/medicine/cryoxadone/on_mob_life(mob/living/carbon/M)
|
||||
var/power = -0.00003 * (M.bodytemperature ** 2) + 3
|
||||
if(M.bodytemperature < T0C)
|
||||
M.adjustOxyLoss(-3 * power, 0)
|
||||
@@ -149,7 +149,7 @@
|
||||
taste_description = "muscle"
|
||||
metabolization_rate = 1.5 * REAGENTS_METABOLISM
|
||||
|
||||
/datum/reagent/medicine/clonexadone/on_mob_life(mob/living/M)
|
||||
/datum/reagent/medicine/clonexadone/on_mob_life(mob/living/carbon/M)
|
||||
if(M.bodytemperature < T0C)
|
||||
M.adjustCloneLoss(0.00006 * (M.bodytemperature ** 2) - 6, 0)
|
||||
M.remove_trait(TRAIT_DISFIGURED, TRAIT_GENERIC)
|
||||
@@ -164,7 +164,7 @@
|
||||
color = "#f7832a"
|
||||
taste_description = "spicy jelly"
|
||||
|
||||
/datum/reagent/medicine/pyroxadone/on_mob_life(mob/living/M)
|
||||
/datum/reagent/medicine/pyroxadone/on_mob_life(mob/living/carbon/M)
|
||||
if(M.bodytemperature > BODYTEMP_HEAT_DAMAGE_LIMIT)
|
||||
var/power = 0
|
||||
switch(M.bodytemperature)
|
||||
@@ -195,7 +195,7 @@
|
||||
overdose_threshold = 30
|
||||
taste_description = "fish"
|
||||
|
||||
/datum/reagent/medicine/rezadone/on_mob_life(mob/living/M)
|
||||
/datum/reagent/medicine/rezadone/on_mob_life(mob/living/carbon/M)
|
||||
M.setCloneLoss(0) //Rezadone is almost never used in favor of cryoxadone. Hopefully this will change that.
|
||||
M.heal_bodypart_damage(1,1)
|
||||
M.remove_trait(TRAIT_DISFIGURED, TRAIT_GENERIC)
|
||||
@@ -237,7 +237,7 @@
|
||||
M.emote("scream")
|
||||
..()
|
||||
|
||||
/datum/reagent/medicine/silver_sulfadiazine/on_mob_life(mob/living/M)
|
||||
/datum/reagent/medicine/silver_sulfadiazine/on_mob_life(mob/living/carbon/M)
|
||||
M.adjustFireLoss(-2*REM, 0)
|
||||
..()
|
||||
. = 1
|
||||
@@ -251,7 +251,7 @@
|
||||
metabolization_rate = 0.5 * REAGENTS_METABOLISM
|
||||
overdose_threshold = 25
|
||||
|
||||
/datum/reagent/medicine/oxandrolone/on_mob_life(mob/living/M)
|
||||
/datum/reagent/medicine/oxandrolone/on_mob_life(mob/living/carbon/M)
|
||||
if(M.getFireLoss() > 50)
|
||||
M.adjustFireLoss(-4*REM, 0) //Twice as effective as silver sulfadiazine for severe burns
|
||||
else
|
||||
@@ -286,7 +286,7 @@
|
||||
..()
|
||||
|
||||
|
||||
/datum/reagent/medicine/styptic_powder/on_mob_life(mob/living/M)
|
||||
/datum/reagent/medicine/styptic_powder/on_mob_life(mob/living/carbon/M)
|
||||
M.adjustBruteLoss(-2*REM, 0)
|
||||
..()
|
||||
. = 1
|
||||
@@ -303,7 +303,7 @@
|
||||
var/last_added = 0
|
||||
var/maximum_reachable = BLOOD_VOLUME_NORMAL - 10 //So that normal blood regeneration can continue with salglu active
|
||||
|
||||
/datum/reagent/medicine/salglu_solution/on_mob_life(mob/living/M)
|
||||
/datum/reagent/medicine/salglu_solution/on_mob_life(mob/living/carbon/M)
|
||||
if(last_added)
|
||||
M.blood_volume -= last_added
|
||||
last_added = 0
|
||||
@@ -315,7 +315,7 @@
|
||||
if(prob(33))
|
||||
M.adjustBruteLoss(-0.5*REM, 0)
|
||||
M.adjustFireLoss(-0.5*REM, 0)
|
||||
. = 1
|
||||
. = TRUE
|
||||
..()
|
||||
|
||||
/datum/reagent/medicine/salglu_solution/overdose_process(mob/living/M)
|
||||
@@ -330,7 +330,7 @@
|
||||
if(prob(33))
|
||||
M.adjustBruteLoss(0.5*REM, 0)
|
||||
M.adjustFireLoss(0.5*REM, 0)
|
||||
. = 1
|
||||
. = TRUE
|
||||
..()
|
||||
|
||||
/datum/reagent/medicine/mine_salve
|
||||
@@ -341,14 +341,12 @@
|
||||
color = "#6D6374"
|
||||
metabolization_rate = 0.4 * REAGENTS_METABOLISM
|
||||
|
||||
/datum/reagent/medicine/mine_salve/on_mob_life(mob/living/M)
|
||||
if(iscarbon(M))
|
||||
var/mob/living/carbon/N = M
|
||||
N.hal_screwyhud = SCREWYHUD_HEALTHY
|
||||
M.adjustBruteLoss(-0.25*REM, 0)
|
||||
M.adjustFireLoss(-0.25*REM, 0)
|
||||
/datum/reagent/medicine/mine_salve/on_mob_life(mob/living/carbon/C)
|
||||
C.hal_screwyhud = SCREWYHUD_HEALTHY
|
||||
C.adjustBruteLoss(-0.25*REM, 0)
|
||||
C.adjustFireLoss(-0.25*REM, 0)
|
||||
..()
|
||||
. = 1
|
||||
return TRUE
|
||||
|
||||
/datum/reagent/medicine/mine_salve/reaction_mob(mob/living/M, method=TOUCH, reac_volume, show_message = 1)
|
||||
if(iscarbon(M) && M.stat != DEAD)
|
||||
@@ -400,7 +398,7 @@
|
||||
metabolization_rate = 0.5 * REAGENTS_METABOLISM
|
||||
taste_description = "ash"
|
||||
|
||||
/datum/reagent/medicine/charcoal/on_mob_life(mob/living/M)
|
||||
/datum/reagent/medicine/charcoal/on_mob_life(mob/living/carbon/M)
|
||||
M.adjustToxLoss(-2*REM, 0)
|
||||
. = 1
|
||||
for(var/datum/reagent/R in M.reagents.reagent_list)
|
||||
@@ -417,7 +415,7 @@
|
||||
metabolization_rate = 0.25 * REAGENTS_METABOLISM
|
||||
overdose_threshold = 30
|
||||
|
||||
/datum/reagent/medicine/omnizine/on_mob_life(mob/living/M)
|
||||
/datum/reagent/medicine/omnizine/on_mob_life(mob/living/carbon/M)
|
||||
M.adjustToxLoss(-0.5*REM, 0)
|
||||
M.adjustOxyLoss(-0.5*REM, 0)
|
||||
M.adjustBruteLoss(-0.5*REM, 0)
|
||||
@@ -442,7 +440,7 @@
|
||||
metabolization_rate = 0.5 * REAGENTS_METABOLISM
|
||||
taste_description = "acid"
|
||||
|
||||
/datum/reagent/medicine/calomel/on_mob_life(mob/living/M)
|
||||
/datum/reagent/medicine/calomel/on_mob_life(mob/living/carbon/M)
|
||||
for(var/datum/reagent/R in M.reagents.reagent_list)
|
||||
if(R != src)
|
||||
M.reagents.remove_reagent(R.id,2.5)
|
||||
@@ -459,7 +457,7 @@
|
||||
color = "#14FF3C"
|
||||
metabolization_rate = 2 * REAGENTS_METABOLISM
|
||||
|
||||
/datum/reagent/medicine/potass_iodide/on_mob_life(mob/living/M)
|
||||
/datum/reagent/medicine/potass_iodide/on_mob_life(mob/living/carbon/M)
|
||||
if(M.radiation > 0)
|
||||
M.radiation -= min(M.radiation, 8)
|
||||
..()
|
||||
@@ -472,7 +470,7 @@
|
||||
color = "#E6FFF0"
|
||||
metabolization_rate = 0.5 * REAGENTS_METABOLISM
|
||||
|
||||
/datum/reagent/medicine/pen_acid/on_mob_life(mob/living/M)
|
||||
/datum/reagent/medicine/pen_acid/on_mob_life(mob/living/carbon/M)
|
||||
M.radiation -= max(M.radiation-RAD_MOB_SAFE, 0)/50
|
||||
M.adjustToxLoss(-2*REM, 0)
|
||||
for(var/datum/reagent/R in M.reagents.reagent_list)
|
||||
@@ -491,7 +489,7 @@
|
||||
overdose_threshold = 25
|
||||
|
||||
|
||||
/datum/reagent/medicine/sal_acid/on_mob_life(mob/living/M)
|
||||
/datum/reagent/medicine/sal_acid/on_mob_life(mob/living/carbon/M)
|
||||
if(M.getBruteLoss() > 50)
|
||||
M.adjustBruteLoss(-4*REM, 0) //Twice as effective as styptic powder for severe bruising
|
||||
else
|
||||
@@ -513,7 +511,7 @@
|
||||
color = "#00FFFF"
|
||||
metabolization_rate = 0.25 * REAGENTS_METABOLISM
|
||||
|
||||
/datum/reagent/medicine/salbutamol/on_mob_life(mob/living/M)
|
||||
/datum/reagent/medicine/salbutamol/on_mob_life(mob/living/carbon/M)
|
||||
M.adjustOxyLoss(-3*REM, 0)
|
||||
if(M.losebreath >= 4)
|
||||
M.losebreath -= 2
|
||||
@@ -535,7 +533,7 @@
|
||||
M.adjustBruteLoss(-0.5*REM, 0)
|
||||
M.adjustFireLoss(-0.5*REM, 0)
|
||||
..()
|
||||
. = 1
|
||||
return TRUE
|
||||
|
||||
/datum/reagent/medicine/ephedrine
|
||||
name = "Ephedrine"
|
||||
@@ -547,32 +545,28 @@
|
||||
overdose_threshold = 45
|
||||
addiction_threshold = 30
|
||||
|
||||
/datum/reagent/medicine/ephedrine/on_mob_add(mob/M)
|
||||
/datum/reagent/medicine/ephedrine/on_mob_add(mob/living/L)
|
||||
..()
|
||||
if(isliving(M))
|
||||
var/mob/living/L = M
|
||||
L.add_trait(TRAIT_GOTTAGOFAST, id)
|
||||
L.add_trait(TRAIT_GOTTAGOFAST, id)
|
||||
|
||||
/datum/reagent/medicine/ephedrine/on_mob_delete(mob/M)
|
||||
if(isliving(M))
|
||||
var/mob/living/L = M
|
||||
L.remove_trait(TRAIT_GOTTAGOFAST, id)
|
||||
/datum/reagent/medicine/ephedrine/on_mob_delete(mob/living/L)
|
||||
L.remove_trait(TRAIT_GOTTAGOFAST, id)
|
||||
..()
|
||||
|
||||
/datum/reagent/medicine/ephedrine/on_mob_life(mob/living/M)
|
||||
/datum/reagent/medicine/ephedrine/on_mob_life(mob/living/carbon/M)
|
||||
M.AdjustStun(-20, 0)
|
||||
M.AdjustKnockdown(-20, 0)
|
||||
M.AdjustUnconscious(-20, 0)
|
||||
M.adjustStaminaLoss(-1*REM, 0)
|
||||
..()
|
||||
. = 1
|
||||
return TRUE
|
||||
|
||||
/datum/reagent/medicine/ephedrine/overdose_process(mob/living/M)
|
||||
if(prob(33))
|
||||
M.adjustToxLoss(0.5*REM, 0)
|
||||
M.losebreath++
|
||||
. = 1
|
||||
..()
|
||||
return TRUE
|
||||
|
||||
/datum/reagent/medicine/ephedrine/addiction_act_stage1(mob/living/M)
|
||||
if(prob(33))
|
||||
@@ -610,7 +604,7 @@
|
||||
color = "#64FFE6"
|
||||
metabolization_rate = 0.5 * REAGENTS_METABOLISM
|
||||
|
||||
/datum/reagent/medicine/diphenhydramine/on_mob_life(mob/living/M)
|
||||
/datum/reagent/medicine/diphenhydramine/on_mob_life(mob/living/carbon/M)
|
||||
if(prob(10))
|
||||
M.drowsyness += 1
|
||||
M.jitteriness -= 1
|
||||
@@ -627,19 +621,15 @@
|
||||
overdose_threshold = 30
|
||||
addiction_threshold = 25
|
||||
|
||||
/datum/reagent/medicine/morphine/on_mob_add(mob/M)
|
||||
/datum/reagent/medicine/morphine/on_mob_add(mob/living/L)
|
||||
..()
|
||||
if(isliving(M))
|
||||
var/mob/living/L = M
|
||||
L.add_trait(TRAIT_IGNORESLOWDOWN, id)
|
||||
L.add_trait(TRAIT_IGNORESLOWDOWN, id)
|
||||
|
||||
/datum/reagent/medicine/morphine/on_mob_delete(mob/M)
|
||||
if(isliving(M))
|
||||
var/mob/living/L = M
|
||||
L.remove_trait(TRAIT_IGNORESLOWDOWN, id)
|
||||
/datum/reagent/medicine/morphine/on_mob_delete(mob/living/L)
|
||||
L.remove_trait(TRAIT_IGNORESLOWDOWN, id)
|
||||
..()
|
||||
|
||||
/datum/reagent/medicine/morphine/on_mob_life(mob/living/M)
|
||||
/datum/reagent/medicine/morphine/on_mob_life(mob/living/carbon/M)
|
||||
switch(current_cycle)
|
||||
if(11)
|
||||
to_chat(M, "<span class='warning'>You start to feel tired...</span>" )
|
||||
@@ -699,7 +689,7 @@
|
||||
metabolization_rate = 0.25 * REAGENTS_METABOLISM
|
||||
taste_description = "dull toxin"
|
||||
|
||||
/datum/reagent/medicine/oculine/on_mob_life(mob/living/M)
|
||||
/datum/reagent/medicine/oculine/on_mob_life(mob/living/carbon/M)
|
||||
var/obj/item/organ/eyes/eyes = M.getorganslot(ORGAN_SLOT_EYES)
|
||||
if (!eyes)
|
||||
return
|
||||
@@ -730,7 +720,7 @@
|
||||
metabolization_rate = 0.25 * REAGENTS_METABOLISM
|
||||
overdose_threshold = 35
|
||||
|
||||
/datum/reagent/medicine/atropine/on_mob_life(mob/living/M)
|
||||
/datum/reagent/medicine/atropine/on_mob_life(mob/living/carbon/M)
|
||||
if(M.health < 0)
|
||||
M.adjustToxLoss(-2*REM, 0)
|
||||
M.adjustBruteLoss(-2*REM, 0)
|
||||
@@ -759,7 +749,7 @@
|
||||
metabolization_rate = 0.25 * REAGENTS_METABOLISM
|
||||
overdose_threshold = 30
|
||||
|
||||
/datum/reagent/medicine/epinephrine/on_mob_life(mob/living/M)
|
||||
/datum/reagent/medicine/epinephrine/on_mob_life(mob/living/carbon/M)
|
||||
if(M.health < 0)
|
||||
M.adjustToxLoss(-0.5*REM, 0)
|
||||
M.adjustBruteLoss(-0.5*REM, 0)
|
||||
@@ -816,7 +806,7 @@
|
||||
add_logs(M, M, "revived", src)
|
||||
..()
|
||||
|
||||
/datum/reagent/medicine/strange_reagent/on_mob_life(mob/living/M)
|
||||
/datum/reagent/medicine/strange_reagent/on_mob_life(mob/living/carbon/M)
|
||||
M.adjustBruteLoss(0.5*REM, 0)
|
||||
M.adjustFireLoss(0.5*REM, 0)
|
||||
..()
|
||||
@@ -828,12 +818,10 @@
|
||||
description = "Efficiently restores brain damage."
|
||||
color = "#DCDCFF"
|
||||
|
||||
/datum/reagent/medicine/mannitol/on_mob_life(mob/living/M)
|
||||
M.adjustBrainLoss(-2*REM)
|
||||
if(iscarbon(M))
|
||||
var/mob/living/carbon/C = M
|
||||
if(prob(10))
|
||||
C.cure_trauma_type(resilience = TRAUMA_RESILIENCE_BASIC)
|
||||
/datum/reagent/medicine/mannitol/on_mob_life(mob/living/carbon/C)
|
||||
C.adjustBrainLoss(-2*REM)
|
||||
if(prob(10))
|
||||
C.cure_trauma_type(resilience = TRAUMA_RESILIENCE_BASIC)
|
||||
..()
|
||||
|
||||
/datum/reagent/medicine/mutadone
|
||||
@@ -843,7 +831,7 @@
|
||||
color = "#5096C8"
|
||||
taste_description = "acid"
|
||||
|
||||
/datum/reagent/medicine/mutadone/on_mob_life(mob/living/carbon/human/M)
|
||||
/datum/reagent/medicine/mutadone/on_mob_life(mob/living/carbon/M)
|
||||
M.jitteriness = 0
|
||||
if(M.has_dna())
|
||||
M.dna.remove_all_mutations()
|
||||
@@ -857,7 +845,7 @@
|
||||
color = "#00B4C8"
|
||||
taste_description = "raw egg"
|
||||
|
||||
/datum/reagent/medicine/antihol/on_mob_life(mob/living/M)
|
||||
/datum/reagent/medicine/antihol/on_mob_life(mob/living/carbon/M)
|
||||
M.dizziness = 0
|
||||
M.drowsyness = 0
|
||||
M.slurring = 0
|
||||
@@ -878,19 +866,15 @@
|
||||
metabolization_rate = 0.5 * REAGENTS_METABOLISM
|
||||
overdose_threshold = 60
|
||||
|
||||
/datum/reagent/medicine/stimulants/on_mob_add(mob/M)
|
||||
/datum/reagent/medicine/stimulants/on_mob_add(mob/living/L)
|
||||
..()
|
||||
if(isliving(M))
|
||||
var/mob/living/L = M
|
||||
L.add_trait(TRAIT_GOTTAGOFAST, id)
|
||||
L.add_trait(TRAIT_GOTTAGOFAST, id)
|
||||
|
||||
/datum/reagent/medicine/stimulants/on_mob_delete(mob/M)
|
||||
if(isliving(M))
|
||||
var/mob/living/L = M
|
||||
L.remove_trait(TRAIT_GOTTAGOFAST, id)
|
||||
/datum/reagent/medicine/stimulants/on_mob_delete(mob/living/L)
|
||||
L.remove_trait(TRAIT_GOTTAGOFAST, id)
|
||||
..()
|
||||
|
||||
/datum/reagent/medicine/stimulants/on_mob_life(mob/living/M)
|
||||
/datum/reagent/medicine/stimulants/on_mob_life(mob/living/carbon/M)
|
||||
if(M.health < 50 && M.health > 0)
|
||||
M.adjustOxyLoss(-1*REM, 0)
|
||||
M.adjustToxLoss(-1*REM, 0)
|
||||
@@ -919,7 +903,7 @@
|
||||
color = "#FFFFF0"
|
||||
metabolization_rate = 0.5 * REAGENTS_METABOLISM
|
||||
|
||||
/datum/reagent/medicine/insulin/on_mob_life(mob/living/M)
|
||||
/datum/reagent/medicine/insulin/on_mob_life(mob/living/carbon/M)
|
||||
if(M.AdjustSleeping(-20, FALSE))
|
||||
. = 1
|
||||
M.reagents.remove_reagent("sugar", 3)
|
||||
@@ -934,7 +918,7 @@
|
||||
color = "#C8A5DC"
|
||||
overdose_threshold = 30
|
||||
|
||||
/datum/reagent/medicine/bicaridine/on_mob_life(mob/living/M)
|
||||
/datum/reagent/medicine/bicaridine/on_mob_life(mob/living/carbon/M)
|
||||
M.adjustBruteLoss(-2*REM, 0)
|
||||
..()
|
||||
. = 1
|
||||
@@ -952,7 +936,7 @@
|
||||
color = "#C8A5DC"
|
||||
overdose_threshold = 30
|
||||
|
||||
/datum/reagent/medicine/dexalin/on_mob_life(mob/living/M)
|
||||
/datum/reagent/medicine/dexalin/on_mob_life(mob/living/carbon/M)
|
||||
M.adjustOxyLoss(-2*REM, 0)
|
||||
..()
|
||||
. = 1
|
||||
@@ -970,7 +954,7 @@
|
||||
color = "#C8A5DC"
|
||||
overdose_threshold = 30
|
||||
|
||||
/datum/reagent/medicine/kelotane/on_mob_life(mob/living/M)
|
||||
/datum/reagent/medicine/kelotane/on_mob_life(mob/living/carbon/M)
|
||||
M.adjustFireLoss(-2*REM, 0)
|
||||
..()
|
||||
. = 1
|
||||
@@ -989,7 +973,7 @@
|
||||
overdose_threshold = 30
|
||||
taste_description = "a roll of gauze"
|
||||
|
||||
/datum/reagent/medicine/antitoxin/on_mob_life(mob/living/M)
|
||||
/datum/reagent/medicine/antitoxin/on_mob_life(mob/living/carbon/M)
|
||||
M.adjustToxLoss(-2*REM, 0)
|
||||
for(var/datum/reagent/toxin/R in M.reagents.reagent_list)
|
||||
M.reagents.remove_reagent(R.id,1)
|
||||
@@ -1008,7 +992,7 @@
|
||||
reagent_state = LIQUID
|
||||
color = "#C8A5DC"
|
||||
|
||||
/datum/reagent/medicine/inaprovaline/on_mob_life(mob/living/M)
|
||||
/datum/reagent/medicine/inaprovaline/on_mob_life(mob/living/carbon/M)
|
||||
if(M.losebreath >= 5)
|
||||
M.losebreath -= 5
|
||||
..()
|
||||
@@ -1022,7 +1006,7 @@
|
||||
overdose_threshold = 30
|
||||
taste_description = "grossness"
|
||||
|
||||
/datum/reagent/medicine/tricordrazine/on_mob_life(mob/living/M)
|
||||
/datum/reagent/medicine/tricordrazine/on_mob_life(mob/living/carbon/M)
|
||||
if(prob(80))
|
||||
M.adjustBruteLoss(-1*REM, 0)
|
||||
M.adjustFireLoss(-1*REM, 0)
|
||||
@@ -1047,7 +1031,7 @@
|
||||
color = "#91D865"
|
||||
taste_description = "jelly"
|
||||
|
||||
/datum/reagent/medicine/regen_jelly/on_mob_life(mob/living/M)
|
||||
/datum/reagent/medicine/regen_jelly/on_mob_life(mob/living/carbon/M)
|
||||
M.adjustBruteLoss(-1.5*REM, 0)
|
||||
M.adjustFireLoss(-1.5*REM, 0)
|
||||
M.adjustOxyLoss(-1.5*REM, 0)
|
||||
@@ -1062,7 +1046,7 @@
|
||||
reagent_state = SOLID
|
||||
color = "#555555"
|
||||
|
||||
/datum/reagent/medicine/syndicate_nanites/on_mob_life(mob/living/M)
|
||||
/datum/reagent/medicine/syndicate_nanites/on_mob_life(mob/living/carbon/M)
|
||||
M.adjustBruteLoss(-5*REM, 0) //A ton of healing - this is a 50 telecrystal investment.
|
||||
M.adjustFireLoss(-5*REM, 0)
|
||||
M.adjustOxyLoss(-15, 0)
|
||||
@@ -1079,7 +1063,7 @@
|
||||
color = rgb(255, 175, 0)
|
||||
overdose_threshold = 25
|
||||
|
||||
/datum/reagent/medicine/earthsblood/on_mob_life(mob/living/M)
|
||||
/datum/reagent/medicine/earthsblood/on_mob_life(mob/living/carbon/M)
|
||||
M.adjustBruteLoss(-3 * REM, 0)
|
||||
M.adjustFireLoss(-3 * REM, 0)
|
||||
M.adjustOxyLoss(-15 * REM, 0)
|
||||
@@ -1106,7 +1090,7 @@
|
||||
color = "#27870a"
|
||||
metabolization_rate = 0.4 * REAGENTS_METABOLISM
|
||||
|
||||
/datum/reagent/medicine/haloperidol/on_mob_life(mob/living/M)
|
||||
/datum/reagent/medicine/haloperidol/on_mob_life(mob/living/carbon/M)
|
||||
for(var/datum/reagent/drug/R in M.reagents.reagent_list)
|
||||
M.reagents.remove_reagent(R.id,5)
|
||||
M.drowsyness += 2
|
||||
@@ -1118,7 +1102,7 @@
|
||||
M.adjustBrainLoss(1*REM, 50)
|
||||
M.adjustStaminaLoss(2.5*REM, 0)
|
||||
..()
|
||||
. = 1
|
||||
return TRUE
|
||||
|
||||
/datum/reagent/medicine/miningnanites
|
||||
name = "Nanites"
|
||||
@@ -1128,17 +1112,17 @@
|
||||
overdose_threshold = 3 //To prevent people stacking massive amounts of a very strong healing reagent
|
||||
can_synth = FALSE
|
||||
|
||||
/datum/reagent/medicine/miningnanites/on_mob_life(mob/living/M)
|
||||
/datum/reagent/medicine/miningnanites/on_mob_life(mob/living/carbon/M)
|
||||
M.heal_bodypart_damage(5,5)
|
||||
..()
|
||||
. = 1
|
||||
return TRUE
|
||||
|
||||
/datum/reagent/medicine/miningnanites/overdose_process(mob/living/M)
|
||||
M.adjustBruteLoss(3*REM, 0)
|
||||
M.adjustFireLoss(3*REM, 0)
|
||||
M.adjustToxLoss(3*REM, 0)
|
||||
..()
|
||||
. = 1
|
||||
return TRUE
|
||||
|
||||
//used for changeling's adrenaline power
|
||||
/datum/reagent/medicine/changelingadrenaline
|
||||
@@ -1148,18 +1132,18 @@
|
||||
color = "#C8A5DC"
|
||||
overdose_threshold = 30
|
||||
|
||||
/datum/reagent/medicine/changelingadrenaline/on_mob_life(mob/living/M as mob)
|
||||
/datum/reagent/medicine/changelingadrenaline/on_mob_life(mob/living/carbon/M as mob)
|
||||
M.AdjustUnconscious(-20, 0)
|
||||
M.AdjustStun(-20, 0)
|
||||
M.AdjustKnockdown(-20, 0)
|
||||
M.adjustStaminaLoss(-1, 0)
|
||||
. = 1
|
||||
..()
|
||||
return TRUE
|
||||
|
||||
/datum/reagent/medicine/changelingadrenaline/overdose_process(mob/living/M as mob)
|
||||
M.adjustToxLoss(1, 0)
|
||||
. = 1
|
||||
..()
|
||||
return TRUE
|
||||
|
||||
/datum/reagent/medicine/changelinghaste
|
||||
name = "Changeling Haste"
|
||||
@@ -1168,22 +1152,18 @@
|
||||
color = "#C8A5DC"
|
||||
metabolization_rate = 1
|
||||
|
||||
/datum/reagent/medicine/changelinghaste/on_mob_add(mob/M)
|
||||
/datum/reagent/medicine/changelinghaste/on_mob_add(mob/living/L)
|
||||
..()
|
||||
if(isliving(M))
|
||||
var/mob/living/L = M
|
||||
L.add_trait(TRAIT_GOTTAGOREALLYFAST, id)
|
||||
L.add_trait(TRAIT_GOTTAGOREALLYFAST, id)
|
||||
|
||||
/datum/reagent/medicine/changelinghaste/on_mob_delete(mob/M)
|
||||
if(isliving(M))
|
||||
var/mob/living/L = M
|
||||
L.remove_trait(TRAIT_GOTTAGOREALLYFAST, id)
|
||||
/datum/reagent/medicine/changelinghaste/on_mob_delete(mob/living/L)
|
||||
L.remove_trait(TRAIT_GOTTAGOREALLYFAST, id)
|
||||
..()
|
||||
|
||||
/datum/reagent/medicine/changelinghaste/on_mob_life(mob/living/M as mob)
|
||||
/datum/reagent/medicine/changelinghaste/on_mob_life(mob/living/carbon/M)
|
||||
M.adjustToxLoss(2, 0)
|
||||
. = 1
|
||||
..()
|
||||
return TRUE
|
||||
|
||||
/datum/reagent/medicine/corazone
|
||||
// Heart attack code will not do damage if corazone is present
|
||||
@@ -1226,7 +1206,7 @@
|
||||
M.remove_trait(TRAIT_SLEEPIMMUNE, id)
|
||||
..()
|
||||
|
||||
/datum/reagent/medicine/modafinil/on_mob_life(mob/living/M)
|
||||
/datum/reagent/medicine/modafinil/on_mob_life(mob/living/carbon/M)
|
||||
if(!overdosed) // We do not want any effects on OD
|
||||
overdose_threshold = overdose_threshold + rand(-10,10)/10 // for extra fun
|
||||
M.AdjustStun(-5, 0)
|
||||
@@ -1235,7 +1215,7 @@
|
||||
M.adjustStaminaLoss(-0.5*REM, 0)
|
||||
M.Jitter(1)
|
||||
metabolization_rate = 0.01 * REAGENTS_METABOLISM * rand(5,20) // randomizes metabolism between 0.02 and 0.08 per tick
|
||||
. = 1
|
||||
. = TRUE
|
||||
..()
|
||||
|
||||
/datum/reagent/medicine/modafinil/overdose_start(mob/living/M)
|
||||
@@ -1272,5 +1252,4 @@
|
||||
M.adjustOxyLoss(1.5*REM, 0)
|
||||
M.adjustStaminaLoss(1.5*REM, 0)
|
||||
..()
|
||||
. = 1
|
||||
|
||||
return TRUE
|
||||
|
||||
@@ -11,7 +11,7 @@
|
||||
glass_desc = "Are you sure this is tomato juice?"
|
||||
shot_glass_icon_state = "shotglassred"
|
||||
|
||||
/datum/reagent/blood/reaction_mob(mob/M, method=TOUCH, reac_volume)
|
||||
/datum/reagent/blood/reaction_mob(mob/living/L, method=TOUCH, reac_volume)
|
||||
if(data && data["viruses"])
|
||||
for(var/thing in data["viruses"])
|
||||
var/datum/disease/D = thing
|
||||
@@ -19,15 +19,13 @@
|
||||
if((D.spread_flags & DISEASE_SPREAD_SPECIAL) || (D.spread_flags & DISEASE_SPREAD_NON_CONTAGIOUS))
|
||||
continue
|
||||
|
||||
if(isliving(M))
|
||||
var/mob/living/L = M
|
||||
if((method == TOUCH || method == VAPOR) && (D.spread_flags & DISEASE_SPREAD_CONTACT_FLUIDS))
|
||||
L.ContactContractDisease(D)
|
||||
else //ingest, patch or inject
|
||||
L.ForceContractDisease(D)
|
||||
if((method == TOUCH || method == VAPOR) && (D.spread_flags & DISEASE_SPREAD_CONTACT_FLUIDS))
|
||||
L.ContactContractDisease(D)
|
||||
else //ingest, patch or inject
|
||||
L.ForceContractDisease(D)
|
||||
|
||||
if(iscarbon(M))
|
||||
var/mob/living/carbon/C = M
|
||||
if(iscarbon(L))
|
||||
var/mob/living/carbon/C = L
|
||||
if(C.get_blood_id() == "blood" && (method == INJECT || (method == INGEST && C.dna && C.dna.species && (DRINKSBLOOD in C.dna.species.species_traits))))
|
||||
if(!data || !(data["blood_type"] in get_safe_blood(C.dna.blood_type)))
|
||||
C.reagents.add_reagent("toxin", reac_volume * 0.5)
|
||||
@@ -99,10 +97,7 @@
|
||||
color = "#C81040" // rgb: 200, 16, 64
|
||||
taste_description = "slime"
|
||||
|
||||
/datum/reagent/vaccine/reaction_mob(mob/M, method=TOUCH, reac_volume)
|
||||
if(!isliving(M))
|
||||
return
|
||||
var/mob/living/L = M
|
||||
/datum/reagent/vaccine/reaction_mob(mob/living/L, method=TOUCH, reac_volume)
|
||||
if(islist(data) && (method == INGEST || method == INJECT))
|
||||
for(var/thing in L.diseases)
|
||||
var/datum/disease/D = thing
|
||||
@@ -195,16 +190,12 @@
|
||||
glass_name = "glass of holy water"
|
||||
glass_desc = "A glass of holy water."
|
||||
|
||||
/datum/reagent/water/holywater/on_mob_add(mob/M)
|
||||
/datum/reagent/water/holywater/on_mob_add(mob/living/L)
|
||||
..()
|
||||
if(isliving(M))
|
||||
var/mob/living/L = M
|
||||
L.add_trait(TRAIT_HOLY, id)
|
||||
L.add_trait(TRAIT_HOLY, id)
|
||||
|
||||
/datum/reagent/water/holywater/on_mob_delete(mob/M)
|
||||
if(isliving(M))
|
||||
var/mob/living/L = M
|
||||
L.remove_trait(TRAIT_HOLY, id)
|
||||
/datum/reagent/water/holywater/on_mob_delete(mob/living/L)
|
||||
L.remove_trait(TRAIT_HOLY, id)
|
||||
..()
|
||||
|
||||
/datum/reagent/water/holywater/reaction_mob(mob/living/M, method=TOUCH, reac_volume)
|
||||
@@ -212,7 +203,7 @@
|
||||
to_chat(M, "<span class='userdanger'>A darkness begins to spread its unholy tendrils through your mind, purging the Justiciar's influence!</span>")
|
||||
..()
|
||||
|
||||
/datum/reagent/water/holywater/on_mob_life(mob/living/M)
|
||||
/datum/reagent/water/holywater/on_mob_life(mob/living/carbon/M)
|
||||
if(!data)
|
||||
data = 1
|
||||
data++
|
||||
@@ -276,7 +267,7 @@
|
||||
return
|
||||
return ..()
|
||||
|
||||
/datum/reagent/fuel/unholywater/on_mob_life(mob/living/M)
|
||||
/datum/reagent/fuel/unholywater/on_mob_life(mob/living/carbon/M)
|
||||
if(iscultist(M))
|
||||
M.drowsyness = max(M.drowsyness-5, 0)
|
||||
M.AdjustUnconscious(-20, 0)
|
||||
@@ -296,7 +287,7 @@
|
||||
M.adjustOxyLoss(2, 0)
|
||||
M.adjustBruteLoss(2, 0)
|
||||
holder.remove_reagent(id, 1)
|
||||
. = 1
|
||||
return TRUE
|
||||
|
||||
/datum/reagent/hellwater //if someone has this in their system they've really pissed off an eldrich god
|
||||
name = "Hell Water"
|
||||
@@ -304,13 +295,13 @@
|
||||
description = "YOUR FLESH! IT BURNS!"
|
||||
taste_description = "burning"
|
||||
|
||||
/datum/reagent/hellwater/on_mob_life(mob/living/M)
|
||||
/datum/reagent/hellwater/on_mob_life(mob/living/carbon/M)
|
||||
M.fire_stacks = min(5,M.fire_stacks + 3)
|
||||
M.IgniteMob() //Only problem with igniting people is currently the commonly availible fire suits make you immune to being on fire
|
||||
M.adjustToxLoss(1, 0)
|
||||
M.adjustFireLoss(1, 0) //Hence the other damages... ain't I a bastard?
|
||||
M.adjustBrainLoss(5, 150)
|
||||
holder.remove_reagent(src.id, 1)
|
||||
holder.remove_reagent(id, 1)
|
||||
|
||||
/datum/reagent/medicine/omnizine/godblood
|
||||
name = "Godblood"
|
||||
@@ -620,10 +611,12 @@
|
||||
taste_description = "slime"
|
||||
|
||||
/datum/reagent/mulligan/on_mob_life(mob/living/carbon/human/H)
|
||||
..()
|
||||
if (!istype(H))
|
||||
return
|
||||
to_chat(H, "<span class='warning'><b>You grit your teeth in pain as your body rapidly mutates!</b></span>")
|
||||
H.visible_message("<b>[H]</b> suddenly transforms!")
|
||||
randomize_human(H)
|
||||
..()
|
||||
|
||||
/datum/reagent/aslimetoxin
|
||||
name = "Advanced Mutation Toxin"
|
||||
@@ -632,10 +625,7 @@
|
||||
color = "#13BC5E" // rgb: 19, 188, 94
|
||||
taste_description = "slime"
|
||||
|
||||
/datum/reagent/aslimetoxin/reaction_mob(mob/M, method=TOUCH, reac_volume)
|
||||
if(!isliving(M))
|
||||
return
|
||||
var/mob/living/L = M
|
||||
/datum/reagent/aslimetoxin/reaction_mob(mob/living/L, method=TOUCH, reac_volume)
|
||||
if(method != TOUCH)
|
||||
L.ForceContractDisease(new /datum/disease/transformation/slime(), FALSE, TRUE)
|
||||
|
||||
@@ -647,10 +637,7 @@
|
||||
can_synth = FALSE
|
||||
taste_description = "decay"
|
||||
|
||||
/datum/reagent/gluttonytoxin/reaction_mob(mob/M, method=TOUCH, reac_volume)
|
||||
if(!isliving(M))
|
||||
return
|
||||
var/mob/living/L = M
|
||||
/datum/reagent/gluttonytoxin/reaction_mob(mob/living/L, method=TOUCH, reac_volume)
|
||||
L.ForceContractDisease(new /datum/disease/transformation/morph(), FALSE, TRUE)
|
||||
|
||||
/datum/reagent/serotrotium
|
||||
@@ -661,7 +648,7 @@
|
||||
metabolization_rate = 0.25 * REAGENTS_METABOLISM
|
||||
taste_description = "bitterness"
|
||||
|
||||
/datum/reagent/serotrotium/on_mob_life(mob/living/M)
|
||||
/datum/reagent/serotrotium/on_mob_life(mob/living/carbon/M)
|
||||
if(ishuman(M))
|
||||
if(prob(7))
|
||||
M.emote(pick("twitch","drool","moan","gasp"))
|
||||
@@ -745,7 +732,7 @@
|
||||
color = "#484848" // rgb: 72, 72, 72A
|
||||
taste_mult = 0 // apparently tasteless.
|
||||
|
||||
/datum/reagent/mercury/on_mob_life(mob/living/M)
|
||||
/datum/reagent/mercury/on_mob_life(mob/living/carbon/M)
|
||||
if(M.canmove && !isspaceturf(M.loc))
|
||||
step(M, pick(GLOB.cardinals))
|
||||
if(prob(5))
|
||||
@@ -783,7 +770,7 @@
|
||||
color = "#808080" // rgb: 128, 128, 128
|
||||
taste_description = "chlorine"
|
||||
|
||||
/datum/reagent/chlorine/on_mob_life(mob/living/M)
|
||||
/datum/reagent/chlorine/on_mob_life(mob/living/carbon/M)
|
||||
M.take_bodypart_damage(1*REM, 0, 0, 0)
|
||||
. = 1
|
||||
..()
|
||||
@@ -796,7 +783,7 @@
|
||||
color = "#808080" // rgb: 128, 128, 128
|
||||
taste_description = "acid"
|
||||
|
||||
/datum/reagent/fluorine/on_mob_life(mob/living/M)
|
||||
/datum/reagent/fluorine/on_mob_life(mob/living/carbon/M)
|
||||
M.adjustToxLoss(1*REM, 0)
|
||||
. = 1
|
||||
..()
|
||||
@@ -825,7 +812,7 @@
|
||||
color = "#808080" // rgb: 128, 128, 128
|
||||
taste_description = "metal"
|
||||
|
||||
/datum/reagent/lithium/on_mob_life(mob/living/M)
|
||||
/datum/reagent/lithium/on_mob_life(mob/living/carbon/M)
|
||||
if(M.canmove && !isspaceturf(M.loc))
|
||||
step(M, pick(GLOB.cardinals))
|
||||
if(prob(5))
|
||||
@@ -847,7 +834,7 @@
|
||||
color = "#C7C7C7" // rgb: 199,199,199
|
||||
taste_description = "the colour blue and regret"
|
||||
|
||||
/datum/reagent/radium/on_mob_life(mob/living/M)
|
||||
/datum/reagent/radium/on_mob_life(mob/living/carbon/M)
|
||||
M.apply_effect(2*REM/M.metabolism_efficiency,EFFECT_IRRADIATE,0)
|
||||
..()
|
||||
|
||||
@@ -866,9 +853,8 @@
|
||||
color = "#C8A5DC" // rgb: 200, 165, 220
|
||||
taste_description = "bitterness"
|
||||
|
||||
/datum/reagent/space_cleaner/sterilizine/reaction_mob(mob/living/M, method=TOUCH, reac_volume)
|
||||
if(iscarbon(M) && (method in list(TOUCH, VAPOR, PATCH)))
|
||||
var/mob/living/carbon/C = M
|
||||
/datum/reagent/space_cleaner/sterilizine/reaction_mob(mob/living/carbon/C, method=TOUCH, reac_volume)
|
||||
if(method in list(TOUCH, VAPOR, PATCH))
|
||||
for(var/s in C.surgeries)
|
||||
var/datum/surgery/S = s
|
||||
S.success_multiplier = max(0.2, S.success_multiplier)
|
||||
@@ -884,16 +870,12 @@
|
||||
|
||||
color = "#C8A5DC" // rgb: 200, 165, 220
|
||||
|
||||
/datum/reagent/iron/on_mob_life(mob/living/M)
|
||||
if(iscarbon(M))
|
||||
var/mob/living/carbon/C = M
|
||||
if(C.blood_volume < BLOOD_VOLUME_NORMAL)
|
||||
C.blood_volume += 0.5
|
||||
/datum/reagent/iron/on_mob_life(mob/living/carbon/C)
|
||||
if(C.blood_volume < BLOOD_VOLUME_NORMAL)
|
||||
C.blood_volume += 0.5
|
||||
..()
|
||||
|
||||
/datum/reagent/iron/reaction_mob(mob/living/M, method=TOUCH, reac_volume)
|
||||
if(!isliving(M))
|
||||
return
|
||||
if(M.has_bane(BANE_IRON)) //If the target is weak to cold iron, then poison them.
|
||||
if(holder && holder.chem_temp < 100) // COLD iron.
|
||||
M.reagents.add_reagent("toxin", reac_volume)
|
||||
@@ -916,8 +898,6 @@
|
||||
taste_description = "expensive yet reasonable metal"
|
||||
|
||||
/datum/reagent/silver/reaction_mob(mob/living/M, method=TOUCH, reac_volume)
|
||||
if(!isliving(M))
|
||||
return
|
||||
if(M.has_bane(BANE_SILVER))
|
||||
M.reagents.add_reagent("toxin", reac_volume)
|
||||
..()
|
||||
@@ -930,7 +910,7 @@
|
||||
color = "#B8B8C0" // rgb: 184, 184, 192
|
||||
taste_description = "the inside of a reactor"
|
||||
|
||||
/datum/reagent/uranium/on_mob_life(mob/living/M)
|
||||
/datum/reagent/uranium/on_mob_life(mob/living/carbon/M)
|
||||
M.apply_effect(1/M.metabolism_efficiency,EFFECT_IRRADIATE,0)
|
||||
..()
|
||||
|
||||
@@ -955,7 +935,7 @@
|
||||
do_teleport(M, get_turf(M), (reac_volume / 5), asoundin = 'sound/effects/phasein.ogg') //4 tiles per crystal
|
||||
..()
|
||||
|
||||
/datum/reagent/bluespace/on_mob_life(mob/living/M)
|
||||
/datum/reagent/bluespace/on_mob_life(mob/living/carbon/M)
|
||||
if(current_cycle > 10 && prob(15))
|
||||
to_chat(M, "<span class='warning'>You feel unstable...</span>")
|
||||
M.Jitter(2)
|
||||
@@ -993,17 +973,15 @@
|
||||
glass_desc = "Unless you're an industrial tool, this is probably not safe for consumption."
|
||||
|
||||
/datum/reagent/fuel/reaction_mob(mob/living/M, method=TOUCH, reac_volume)//Splashing people with welding fuel to make them easy to ignite!
|
||||
if(!isliving(M))
|
||||
return
|
||||
if(method == TOUCH || method == VAPOR)
|
||||
M.adjust_fire_stacks(reac_volume / 10)
|
||||
return
|
||||
..()
|
||||
|
||||
/datum/reagent/fuel/on_mob_life(mob/living/M)
|
||||
/datum/reagent/fuel/on_mob_life(mob/living/carbon/M)
|
||||
M.adjustToxLoss(1, 0)
|
||||
. = 1
|
||||
..()
|
||||
return TRUE
|
||||
|
||||
/datum/reagent/space_cleaner
|
||||
name = "Space cleaner"
|
||||
@@ -1030,7 +1008,7 @@
|
||||
for(var/mob/living/simple_animal/slime/M in T)
|
||||
M.adjustToxLoss(rand(5,10))
|
||||
|
||||
/datum/reagent/space_cleaner/reaction_mob(mob/M, method=TOUCH, reac_volume)
|
||||
/datum/reagent/space_cleaner/reaction_mob(mob/living/M, method=TOUCH, reac_volume)
|
||||
if(method == TOUCH || method == VAPOR)
|
||||
M.remove_atom_colour(WASHABLE_COLOUR_PRIORITY)
|
||||
if(iscarbon(M))
|
||||
@@ -1069,7 +1047,7 @@
|
||||
metabolization_rate = 1.5 * REAGENTS_METABOLISM
|
||||
taste_description = "acid"
|
||||
|
||||
/datum/reagent/space_cleaner/ez_clean/on_mob_life(mob/living/M)
|
||||
/datum/reagent/space_cleaner/ez_clean/on_mob_life(mob/living/carbon/M)
|
||||
M.adjustBruteLoss(3.33)
|
||||
M.adjustFireLoss(3.33)
|
||||
M.adjustToxLoss(3.33)
|
||||
@@ -1089,7 +1067,7 @@
|
||||
metabolization_rate = 1.5 * REAGENTS_METABOLISM
|
||||
taste_description = "sourness"
|
||||
|
||||
/datum/reagent/cryptobiolin/on_mob_life(mob/living/M)
|
||||
/datum/reagent/cryptobiolin/on_mob_life(mob/living/carbon/M)
|
||||
M.Dizzy(1)
|
||||
if(!M.confused)
|
||||
M.confused = 1
|
||||
@@ -1103,7 +1081,7 @@
|
||||
color = "#C8A5DC" // rgb: 200, 165, 220A
|
||||
taste_description = "numbness"
|
||||
|
||||
/datum/reagent/impedrezene/on_mob_life(mob/living/M)
|
||||
/datum/reagent/impedrezene/on_mob_life(mob/living/carbon/M)
|
||||
M.jitteriness = max(M.jitteriness-5,0)
|
||||
if(prob(80))
|
||||
M.adjustBrainLoss(2*REM)
|
||||
@@ -1121,10 +1099,7 @@
|
||||
can_synth = FALSE
|
||||
taste_description = "sludge"
|
||||
|
||||
/datum/reagent/nanites/reaction_mob(mob/M, method=TOUCH, reac_volume, show_message = 1, touch_protection = 0)
|
||||
if(!isliving(M))
|
||||
return
|
||||
var/mob/living/L = M
|
||||
/datum/reagent/nanites/reaction_mob(mob/living/L, method=TOUCH, reac_volume, show_message = 1, touch_protection = 0)
|
||||
if(method==PATCH || method==INGEST || method==INJECT || (method == VAPOR && prob(min(reac_volume,100)*(1 - touch_protection))))
|
||||
L.ForceContractDisease(new /datum/disease/transformation/robot(), FALSE, TRUE)
|
||||
|
||||
@@ -1136,10 +1111,7 @@
|
||||
can_synth = FALSE
|
||||
taste_description = "sludge"
|
||||
|
||||
/datum/reagent/xenomicrobes/reaction_mob(mob/M, method=TOUCH, reac_volume, show_message = 1, touch_protection = 0)
|
||||
if(!isliving(M))
|
||||
return
|
||||
var/mob/living/L = M
|
||||
/datum/reagent/xenomicrobes/reaction_mob(mob/living/L, method=TOUCH, reac_volume, show_message = 1, touch_protection = 0)
|
||||
if(method==PATCH || method==INGEST || method==INJECT || (method == VAPOR && prob(min(reac_volume,100)*(1 - touch_protection))))
|
||||
L.ForceContractDisease(new /datum/disease/transformation/xeno(), FALSE, TRUE)
|
||||
|
||||
@@ -1151,10 +1123,7 @@
|
||||
can_synth = FALSE
|
||||
taste_description = "slime"
|
||||
|
||||
/datum/reagent/fungalspores/reaction_mob(mob/M, method=TOUCH, reac_volume, show_message = 1, touch_protection = 0)
|
||||
if(!isliving(M))
|
||||
return
|
||||
var/mob/living/L = M
|
||||
/datum/reagent/fungalspores/reaction_mob(mob/living/L, method=TOUCH, reac_volume, show_message = 1, touch_protection = 0)
|
||||
if(method==PATCH || method==INGEST || method==INJECT || (method == VAPOR && prob(min(reac_volume,100)*(1 - touch_protection))))
|
||||
L.ForceContractDisease(new /datum/disease/tuberculosis(), FALSE, TRUE)
|
||||
|
||||
@@ -1236,11 +1205,11 @@
|
||||
var/temp = holder ? holder.chem_temp : T20C
|
||||
T.atmos_spawn_air("n2o=[reac_volume/5];TEMP=[temp]")
|
||||
|
||||
/datum/reagent/nitrous_oxide/reaction_mob(mob/M, method=TOUCH, reac_volume)
|
||||
/datum/reagent/nitrous_oxide/reaction_mob(mob/living/M, method=TOUCH, reac_volume)
|
||||
if(method == VAPOR)
|
||||
M.drowsyness += max(round(reac_volume, 1), 2)
|
||||
|
||||
/datum/reagent/nitrous_oxide/on_mob_life(mob/living/M)
|
||||
/datum/reagent/nitrous_oxide/on_mob_life(mob/living/carbon/M)
|
||||
M.drowsyness += 2
|
||||
if(ishuman(M))
|
||||
var/mob/living/carbon/human/H = M
|
||||
@@ -1259,19 +1228,15 @@
|
||||
color = "E1A116"
|
||||
taste_description = "sourness"
|
||||
|
||||
/datum/reagent/stimulum/on_mob_add(mob/M)
|
||||
/datum/reagent/stimulum/on_mob_add(mob/living/L)
|
||||
..()
|
||||
if(isliving(M))
|
||||
var/mob/living/L = M
|
||||
L.add_trait(TRAIT_GOTTAGOFAST, id)
|
||||
L.add_trait(TRAIT_GOTTAGOFAST, id)
|
||||
|
||||
/datum/reagent/stimulum/on_mob_delete(mob/M)
|
||||
if(isliving(M))
|
||||
var/mob/living/L = M
|
||||
L.remove_trait(TRAIT_GOTTAGOFAST, id)
|
||||
/datum/reagent/stimulum/on_mob_delete(mob/living/L)
|
||||
L.remove_trait(TRAIT_GOTTAGOFAST, id)
|
||||
..()
|
||||
|
||||
/datum/reagent/stimulum/on_mob_life(mob/living/M) // Has a speedup, and the anti-stun effects of nicotine.
|
||||
/datum/reagent/stimulum/on_mob_life(mob/living/carbon/M) // Has a speedup, and the anti-stun effects of nicotine.
|
||||
M.AdjustStun(-20, 0)
|
||||
M.AdjustKnockdown(-20, 0)
|
||||
M.AdjustUnconscious(-20, 0)
|
||||
@@ -1289,16 +1254,12 @@
|
||||
color = "90560B"
|
||||
taste_description = "burning"
|
||||
|
||||
/datum/reagent/nitryl/on_mob_add(mob/M)
|
||||
/datum/reagent/nitryl/on_mob_add(mob/living/L)
|
||||
..()
|
||||
if(isliving(M))
|
||||
var/mob/living/L = M
|
||||
L.add_trait(TRAIT_GOTTAGOFAST, id)
|
||||
L.add_trait(TRAIT_GOTTAGOFAST, id)
|
||||
|
||||
/datum/reagent/nitryl/on_mob_delete(mob/M)
|
||||
if(isliving(M))
|
||||
var/mob/living/L = M
|
||||
L.remove_trait(TRAIT_GOTTAGOFAST, id)
|
||||
/datum/reagent/nitryl/on_mob_delete(mob/living/L)
|
||||
L.remove_trait(TRAIT_GOTTAGOFAST, id)
|
||||
..()
|
||||
|
||||
/////////////////////////Coloured Crayon Powder////////////////////////////
|
||||
@@ -1394,7 +1355,7 @@
|
||||
var/tox_prob = 0
|
||||
taste_description = "plant food"
|
||||
|
||||
/datum/reagent/plantnutriment/on_mob_life(mob/living/M)
|
||||
/datum/reagent/plantnutriment/on_mob_life(mob/living/carbon/M)
|
||||
if(prob(tox_prob))
|
||||
M.adjustToxLoss(1*REM, 0)
|
||||
. = 1
|
||||
@@ -1448,12 +1409,9 @@
|
||||
taste_description = "bitterness"
|
||||
taste_mult = 1.5
|
||||
|
||||
/datum/reagent/stable_plasma/on_mob_life(mob/living/M)
|
||||
if(iscarbon(M))
|
||||
var/mob/living/carbon/C = M
|
||||
C.adjustPlasma(10)
|
||||
/datum/reagent/stable_plasma/on_mob_life(mob/living/carbon/C)
|
||||
C.adjustPlasma(10)
|
||||
..()
|
||||
return
|
||||
|
||||
/datum/reagent/iodine
|
||||
name = "Iodine"
|
||||
@@ -1476,7 +1434,6 @@
|
||||
var/turf/open/floor/F = T
|
||||
F.PlaceOnTop(/turf/open/floor/carpet)
|
||||
..()
|
||||
return
|
||||
|
||||
/datum/reagent/bromine
|
||||
name = "Bromine"
|
||||
@@ -1520,14 +1477,12 @@
|
||||
taste_description = "rainbows"
|
||||
|
||||
|
||||
/datum/reagent/colorful_reagent/on_mob_life(mob/living/M)
|
||||
if(M && isliving(M))
|
||||
M.add_atom_colour(pick(random_color_list), WASHABLE_COLOUR_PRIORITY)
|
||||
/datum/reagent/colorful_reagent/on_mob_life(mob/living/carbon/M)
|
||||
M.add_atom_colour(pick(random_color_list), WASHABLE_COLOUR_PRIORITY)
|
||||
..()
|
||||
|
||||
/datum/reagent/colorful_reagent/reaction_mob(mob/living/M, reac_volume)
|
||||
if(M && isliving(M))
|
||||
M.add_atom_colour(pick(random_color_list), WASHABLE_COLOUR_PRIORITY)
|
||||
M.add_atom_colour(pick(random_color_list), WASHABLE_COLOUR_PRIORITY)
|
||||
..()
|
||||
|
||||
/datum/reagent/colorful_reagent/reaction_obj(obj/O, reac_volume)
|
||||
@@ -1686,7 +1641,7 @@
|
||||
color = "#00ff80"
|
||||
taste_description = "strange honey"
|
||||
|
||||
/datum/reagent/royal_bee_jelly/on_mob_life(mob/living/M)
|
||||
/datum/reagent/royal_bee_jelly/on_mob_life(mob/living/carbon/M)
|
||||
if(prob(2))
|
||||
M.say(pick("Bzzz...","BZZ BZZ","Bzzzzzzzzzzz..."))
|
||||
..()
|
||||
@@ -1807,16 +1762,12 @@
|
||||
taste_description = "water"
|
||||
metabolization_rate = 0.25 * REAGENTS_METABOLISM
|
||||
|
||||
/datum/reagent/pax/on_mob_add(mob/M)
|
||||
/datum/reagent/pax/on_mob_add(mob/living/L)
|
||||
..()
|
||||
if(isliving(M))
|
||||
var/mob/living/L = M
|
||||
L.add_trait(TRAIT_PACIFISM, id)
|
||||
L.add_trait(TRAIT_PACIFISM, id)
|
||||
|
||||
/datum/reagent/pax/on_mob_delete(mob/M)
|
||||
if(isliving(M))
|
||||
var/mob/living/L = M
|
||||
L.remove_trait(TRAIT_PACIFISM, id)
|
||||
/datum/reagent/pax/on_mob_delete(mob/living/L)
|
||||
L.remove_trait(TRAIT_PACIFISM, id)
|
||||
..()
|
||||
|
||||
/datum/reagent/bz_metabolites
|
||||
@@ -1855,7 +1806,7 @@
|
||||
metabolization_rate = 1.5 * REAGENTS_METABOLISM
|
||||
taste_description = "dizziness"
|
||||
|
||||
/datum/reagent/peaceborg/confuse/on_mob_life(mob/living/M)
|
||||
/datum/reagent/peaceborg/confuse/on_mob_life(mob/living/carbon/M)
|
||||
if(M.confused < 6)
|
||||
M.confused = CLAMP(M.confused + 3, 0, 5)
|
||||
if(M.dizziness < 6)
|
||||
@@ -1871,7 +1822,7 @@
|
||||
metabolization_rate = 1.5 * REAGENTS_METABOLISM
|
||||
taste_description = "tiredness"
|
||||
|
||||
/datum/reagent/peaceborg/tire/on_mob_life(mob/living/M)
|
||||
/datum/reagent/peaceborg/tire/on_mob_life(mob/living/carbon/M)
|
||||
var/healthcomp = (100 - M.health) //DOES NOT ACCOUNT FOR ADMINBUS THINGS THAT MAKE YOU HAVE MORE THAN 200/210 HEALTH, OR SOMETHING OTHER THAN A HUMAN PROCESSING THIS.
|
||||
if(M.getStaminaLoss() < (45 - healthcomp)) //At 50 health you would have 200 - 150 health meaning 50 compensation. 60 - 50 = 10, so would only do 10-19 stamina.)
|
||||
M.adjustStaminaLoss(10)
|
||||
|
||||
@@ -11,10 +11,10 @@
|
||||
if(reac_volume >= 1)
|
||||
T.AddComponent(/datum/component/thermite, reac_volume)
|
||||
|
||||
/datum/reagent/thermite/on_mob_life(mob/living/M)
|
||||
/datum/reagent/thermite/on_mob_life(mob/living/carbon/M)
|
||||
M.adjustFireLoss(1, 0)
|
||||
..()
|
||||
. = 1
|
||||
return TRUE
|
||||
|
||||
/datum/reagent/nitroglycerin
|
||||
name = "Nitroglycerin"
|
||||
@@ -40,12 +40,12 @@
|
||||
metabolization_rate = 4
|
||||
taste_description = "burning"
|
||||
|
||||
/datum/reagent/clf3/on_mob_life(mob/living/M)
|
||||
/datum/reagent/clf3/on_mob_life(mob/living/carbon/M)
|
||||
M.adjust_fire_stacks(2)
|
||||
var/burndmg = max(0.3*M.fire_stacks, 0.3)
|
||||
M.adjustFireLoss(burndmg, 0)
|
||||
..()
|
||||
. = 1
|
||||
return TRUE
|
||||
|
||||
/datum/reagent/clf3/reaction_turf(turf/T, reac_volume)
|
||||
if(isplatingturf(T))
|
||||
@@ -100,7 +100,7 @@
|
||||
metabolization_rate = 0.05
|
||||
taste_description = "salt"
|
||||
|
||||
/datum/reagent/blackpowder/on_mob_life(mob/living/M)
|
||||
/datum/reagent/blackpowder/on_mob_life(mob/living/carbon/M)
|
||||
..()
|
||||
if(isplasmaman(M))
|
||||
M.hallucination += 5
|
||||
@@ -151,12 +151,12 @@
|
||||
M.IgniteMob()
|
||||
..()
|
||||
|
||||
/datum/reagent/phlogiston/on_mob_life(mob/living/M)
|
||||
/datum/reagent/phlogiston/on_mob_life(mob/living/carbon/M)
|
||||
M.adjust_fire_stacks(1)
|
||||
var/burndmg = max(0.3*M.fire_stacks, 0.3)
|
||||
M.adjustFireLoss(burndmg, 0)
|
||||
..()
|
||||
. = 1
|
||||
return TRUE
|
||||
|
||||
/datum/reagent/napalm
|
||||
name = "Napalm"
|
||||
@@ -166,7 +166,7 @@
|
||||
color = "#FA00AF"
|
||||
taste_description = "burning"
|
||||
|
||||
/datum/reagent/napalm/on_mob_life(mob/living/M)
|
||||
/datum/reagent/napalm/on_mob_life(mob/living/carbon/M)
|
||||
M.adjust_fire_stacks(1)
|
||||
..()
|
||||
|
||||
@@ -184,7 +184,7 @@
|
||||
taste_description = "bitterness"
|
||||
|
||||
|
||||
/datum/reagent/cryostylane/on_mob_life(mob/living/M) //TODO: code freezing into an ice cube
|
||||
/datum/reagent/cryostylane/on_mob_life(mob/living/carbon/M) //TODO: code freezing into an ice cube
|
||||
if(M.reagents.has_reagent("oxygen"))
|
||||
M.reagents.remove_reagent("oxygen", 0.5)
|
||||
M.adjust_bodytemperature(-15)
|
||||
@@ -203,7 +203,7 @@
|
||||
metabolization_rate = 0.5 * REAGENTS_METABOLISM
|
||||
taste_description = "bitterness"
|
||||
|
||||
/datum/reagent/pyrosium/on_mob_life(mob/living/M)
|
||||
/datum/reagent/pyrosium/on_mob_life(mob/living/carbon/M)
|
||||
if(M.reagents.has_reagent("oxygen"))
|
||||
M.reagents.remove_reagent("oxygen", 0.5)
|
||||
M.adjust_bodytemperature(15)
|
||||
@@ -219,7 +219,7 @@
|
||||
taste_description = "charged metal"
|
||||
var/shock_timer = 0
|
||||
|
||||
/datum/reagent/teslium/on_mob_life(mob/living/M)
|
||||
/datum/reagent/teslium/on_mob_life(mob/living/carbon/M)
|
||||
shock_timer++
|
||||
if(shock_timer >= rand(5,30)) //Random shocks are wildly unpredictable
|
||||
shock_timer = 0
|
||||
@@ -235,7 +235,7 @@
|
||||
color = "#CAFF43"
|
||||
taste_description = "jelly"
|
||||
|
||||
/datum/reagent/teslium/energized_jelly/on_mob_life(mob/living/M)
|
||||
/datum/reagent/teslium/energized_jelly/on_mob_life(mob/living/carbon/M)
|
||||
if(isjellyperson(M))
|
||||
shock_timer = 0 //immune to shocks
|
||||
M.AdjustStun(-40, 0)
|
||||
@@ -280,9 +280,7 @@
|
||||
O.extinguish()
|
||||
|
||||
/datum/reagent/firefighting_foam/reaction_mob(mob/living/M, method=TOUCH, reac_volume)
|
||||
if(!istype(M))
|
||||
return
|
||||
if(method in list(VAPOR, TOUCH))
|
||||
M.adjust_fire_stacks(-reac_volume)
|
||||
M.ExtinguishMob()
|
||||
..()
|
||||
..()
|
||||
|
||||
@@ -10,10 +10,10 @@
|
||||
taste_mult = 1.2
|
||||
var/toxpwr = 1.5
|
||||
|
||||
/datum/reagent/toxin/on_mob_life(mob/living/M)
|
||||
/datum/reagent/toxin/on_mob_life(mob/living/carbon/M)
|
||||
if(toxpwr)
|
||||
M.adjustToxLoss(toxpwr*REM, 0)
|
||||
. = 1
|
||||
. = TRUE
|
||||
..()
|
||||
|
||||
/datum/reagent/toxin/amatoxin
|
||||
@@ -48,9 +48,8 @@
|
||||
M.domutcheck()
|
||||
..()
|
||||
|
||||
/datum/reagent/toxin/mutagen/on_mob_life(mob/living/carbon/M)
|
||||
if(istype(M))
|
||||
M.apply_effect(5,EFFECT_IRRADIATE,0)
|
||||
/datum/reagent/toxin/mutagen/on_mob_life(mob/living/carbon/C)
|
||||
C.apply_effect(5,EFFECT_IRRADIATE,0)
|
||||
return ..()
|
||||
|
||||
/datum/reagent/toxin/plasma
|
||||
@@ -63,12 +62,10 @@
|
||||
color = "#8228A0"
|
||||
toxpwr = 3
|
||||
|
||||
/datum/reagent/toxin/plasma/on_mob_life(mob/living/M)
|
||||
/datum/reagent/toxin/plasma/on_mob_life(mob/living/carbon/C)
|
||||
if(holder.has_reagent("epinephrine"))
|
||||
holder.remove_reagent("epinephrine", 2*REM)
|
||||
if(iscarbon(M))
|
||||
var/mob/living/carbon/C = M
|
||||
C.adjustPlasma(20)
|
||||
C.adjustPlasma(20)
|
||||
return ..()
|
||||
|
||||
/datum/reagent/toxin/plasma/reaction_obj(obj/O, reac_volume)
|
||||
@@ -84,8 +81,6 @@
|
||||
return
|
||||
|
||||
/datum/reagent/toxin/plasma/reaction_mob(mob/living/M, method=TOUCH, reac_volume)//Splashing people with plasma is stronger than fuel!
|
||||
if(!isliving(M))
|
||||
return
|
||||
if(method == TOUCH || method == VAPOR)
|
||||
M.adjust_fire_stacks(reac_volume / 5)
|
||||
return
|
||||
@@ -99,19 +94,17 @@
|
||||
toxpwr = 0
|
||||
taste_description = "acid"
|
||||
|
||||
/datum/reagent/toxin/lexorin/on_mob_life(mob/living/M)
|
||||
/datum/reagent/toxin/lexorin/on_mob_life(mob/living/carbon/C)
|
||||
. = TRUE
|
||||
|
||||
if(M.has_trait(TRAIT_NOBREATH))
|
||||
if(C.has_trait(TRAIT_NOBREATH))
|
||||
. = FALSE
|
||||
|
||||
if(.)
|
||||
M.adjustOxyLoss(5, 0)
|
||||
if(iscarbon(M))
|
||||
var/mob/living/carbon/C = M
|
||||
C.losebreath += 2
|
||||
C.adjustOxyLoss(5, 0)
|
||||
C.losebreath += 2
|
||||
if(prob(20))
|
||||
M.emote("gasp")
|
||||
C.emote("gasp")
|
||||
..()
|
||||
|
||||
/datum/reagent/toxin/slimejelly
|
||||
@@ -123,7 +116,7 @@
|
||||
taste_description = "slime"
|
||||
taste_mult = 1.3
|
||||
|
||||
/datum/reagent/toxin/slimejelly/on_mob_life(mob/living/M)
|
||||
/datum/reagent/toxin/slimejelly/on_mob_life(mob/living/carbon/M)
|
||||
if(prob(10))
|
||||
to_chat(M, "<span class='danger'>Your insides are burning!</span>")
|
||||
M.adjustToxLoss(rand(20,60)*REM, 0)
|
||||
@@ -141,7 +134,7 @@
|
||||
toxpwr = 0
|
||||
taste_description = "mint"
|
||||
|
||||
/datum/reagent/toxin/minttoxin/on_mob_life(mob/living/M)
|
||||
/datum/reagent/toxin/minttoxin/on_mob_life(mob/living/carbon/M)
|
||||
if(M.has_trait(TRAIT_FAT))
|
||||
M.gib()
|
||||
return ..()
|
||||
@@ -163,16 +156,12 @@
|
||||
toxpwr = 0.5
|
||||
taste_description = "death"
|
||||
|
||||
/datum/reagent/toxin/zombiepowder/on_mob_add(mob/M)
|
||||
/datum/reagent/toxin/zombiepowder/on_mob_add(mob/living/L)
|
||||
..()
|
||||
if(isliving(M))
|
||||
var/mob/living/L = M
|
||||
L.fakedeath(id)
|
||||
L.fakedeath(id)
|
||||
|
||||
/datum/reagent/toxin/zombiepowder/on_mob_delete(mob/M)
|
||||
if(isliving(M))
|
||||
var/mob/living/L = M
|
||||
L.cure_fakedeath(id)
|
||||
/datum/reagent/toxin/zombiepowder/on_mob_delete(mob/living/L)
|
||||
L.cure_fakedeath(id)
|
||||
..()
|
||||
|
||||
/datum/reagent/toxin/zombiepowder/on_mob_life(mob/living/carbon/M)
|
||||
@@ -188,7 +177,7 @@
|
||||
toxpwr = 0
|
||||
taste_description = "sourness"
|
||||
|
||||
/datum/reagent/toxin/mindbreaker/on_mob_life(mob/living/M)
|
||||
/datum/reagent/toxin/mindbreaker/on_mob_life(mob/living/carbon/M)
|
||||
M.hallucination += 5
|
||||
return ..()
|
||||
|
||||
@@ -244,12 +233,10 @@
|
||||
color = "#9ACD32"
|
||||
toxpwr = 1
|
||||
|
||||
/datum/reagent/toxin/spore/on_mob_life(mob/living/M)
|
||||
if(iscarbon(M))
|
||||
var/mob/living/carbon/C = M
|
||||
C.damageoverlaytemp = 60
|
||||
C.update_damage_hud()
|
||||
M.blur_eyes(3)
|
||||
/datum/reagent/toxin/spore/on_mob_life(mob/living/carbon/C)
|
||||
C.damageoverlaytemp = 60
|
||||
C.update_damage_hud()
|
||||
C.blur_eyes(3)
|
||||
return ..()
|
||||
|
||||
/datum/reagent/toxin/spore_burning
|
||||
@@ -260,7 +247,7 @@
|
||||
toxpwr = 0.5
|
||||
taste_description = "burning"
|
||||
|
||||
/datum/reagent/toxin/spore_burning/on_mob_life(mob/living/M)
|
||||
/datum/reagent/toxin/spore_burning/on_mob_life(mob/living/carbon/M)
|
||||
M.adjust_fire_stacks(2)
|
||||
M.IgniteMob()
|
||||
return ..()
|
||||
@@ -274,7 +261,7 @@
|
||||
toxpwr = 0
|
||||
metabolization_rate = 1.5 * REAGENTS_METABOLISM
|
||||
|
||||
/datum/reagent/toxin/chloralhydrate/on_mob_life(mob/living/M)
|
||||
/datum/reagent/toxin/chloralhydrate/on_mob_life(mob/living/carbon/M)
|
||||
switch(current_cycle)
|
||||
if(1 to 10)
|
||||
M.confused += 2
|
||||
@@ -297,7 +284,7 @@
|
||||
toxpwr = 0
|
||||
metabolization_rate = 1.5 * REAGENTS_METABOLISM
|
||||
|
||||
/datum/reagent/toxin/chloralhydratedelayed/on_mob_life(mob/living/M)
|
||||
/datum/reagent/toxin/chloralhydratedelayed/on_mob_life(mob/living/carbon/M)
|
||||
switch(current_cycle)
|
||||
if(10 to 20)
|
||||
M.confused += 1
|
||||
@@ -317,7 +304,7 @@
|
||||
glass_name = "glass of beer"
|
||||
glass_desc = "A freezing pint of beer."
|
||||
|
||||
/datum/reagent/toxin/fakebeer/on_mob_life(mob/living/M)
|
||||
/datum/reagent/toxin/fakebeer/on_mob_life(mob/living/carbon/M)
|
||||
switch(current_cycle)
|
||||
if(1 to 50)
|
||||
M.Sleeping(40, 0)
|
||||
@@ -377,7 +364,7 @@
|
||||
metabolization_rate = 0.125 * REAGENTS_METABOLISM
|
||||
toxpwr = 0
|
||||
|
||||
/datum/reagent/toxin/polonium/on_mob_life(mob/living/M)
|
||||
/datum/reagent/toxin/polonium/on_mob_life(mob/living/carbon/M)
|
||||
M.radiation += 4
|
||||
..()
|
||||
|
||||
@@ -391,7 +378,7 @@
|
||||
overdose_threshold = 30
|
||||
toxpwr = 0
|
||||
|
||||
/datum/reagent/toxin/histamine/on_mob_life(mob/living/M)
|
||||
/datum/reagent/toxin/histamine/on_mob_life(mob/living/carbon/M)
|
||||
if(prob(50))
|
||||
switch(pick(1, 2, 3, 4))
|
||||
if(1)
|
||||
@@ -424,7 +411,7 @@
|
||||
metabolization_rate = 0.5 * REAGENTS_METABOLISM
|
||||
toxpwr = 1
|
||||
|
||||
/datum/reagent/toxin/formaldehyde/on_mob_life(mob/living/M)
|
||||
/datum/reagent/toxin/formaldehyde/on_mob_life(mob/living/carbon/M)
|
||||
if(prob(5))
|
||||
holder.add_reagent("histamine", pick(5,15))
|
||||
holder.remove_reagent("formaldehyde", 1.2)
|
||||
@@ -440,7 +427,7 @@
|
||||
metabolization_rate = 0.25 * REAGENTS_METABOLISM
|
||||
toxpwr = 0
|
||||
|
||||
/datum/reagent/toxin/venom/on_mob_life(mob/living/M)
|
||||
/datum/reagent/toxin/venom/on_mob_life(mob/living/carbon/M)
|
||||
toxpwr = 0.2*volume
|
||||
M.adjustBruteLoss((0.3*volume)*REM, 0)
|
||||
. = 1
|
||||
@@ -459,14 +446,14 @@
|
||||
metabolization_rate = 0.5 * REAGENTS_METABOLISM
|
||||
toxpwr = 0
|
||||
|
||||
/datum/reagent/toxin/fentanyl/on_mob_life(mob/living/M)
|
||||
/datum/reagent/toxin/fentanyl/on_mob_life(mob/living/carbon/M)
|
||||
M.adjustBrainLoss(3*REM, 150)
|
||||
. = 1
|
||||
if(M.toxloss <= 60)
|
||||
M.adjustToxLoss(1*REM, 0)
|
||||
if(current_cycle >= 18)
|
||||
M.Sleeping(40, 0)
|
||||
..()
|
||||
return TRUE
|
||||
|
||||
/datum/reagent/toxin/cyanide
|
||||
name = "Cyanide"
|
||||
@@ -477,7 +464,7 @@
|
||||
metabolization_rate = 0.125 * REAGENTS_METABOLISM
|
||||
toxpwr = 1.25
|
||||
|
||||
/datum/reagent/toxin/cyanide/on_mob_life(mob/living/M)
|
||||
/datum/reagent/toxin/cyanide/on_mob_life(mob/living/carbon/M)
|
||||
if(prob(5))
|
||||
M.losebreath += 1
|
||||
if(prob(8))
|
||||
@@ -509,7 +496,7 @@
|
||||
if(method == TOUCH || method == VAPOR)
|
||||
M.reagents.add_reagent("itching_powder", reac_volume)
|
||||
|
||||
/datum/reagent/toxin/itching_powder/on_mob_life(mob/living/M)
|
||||
/datum/reagent/toxin/itching_powder/on_mob_life(mob/living/carbon/M)
|
||||
if(prob(15))
|
||||
to_chat(M, "You scratch at your head.")
|
||||
M.adjustBruteLoss(0.2*REM, 0)
|
||||
@@ -537,28 +524,26 @@
|
||||
metabolization_rate = 0.5 * REAGENTS_METABOLISM
|
||||
toxpwr = 2.5
|
||||
|
||||
/datum/reagent/toxin/initropidril/on_mob_life(mob/living/M)
|
||||
/datum/reagent/toxin/initropidril/on_mob_life(mob/living/carbon/C)
|
||||
if(prob(25))
|
||||
var/picked_option = rand(1,3)
|
||||
switch(picked_option)
|
||||
if(1)
|
||||
M.Knockdown(60, 0)
|
||||
. = 1
|
||||
C.Knockdown(60, 0)
|
||||
. = TRUE
|
||||
if(2)
|
||||
M.losebreath += 10
|
||||
M.adjustOxyLoss(rand(5,25), 0)
|
||||
. = 1
|
||||
C.losebreath += 10
|
||||
C.adjustOxyLoss(rand(5,25), 0)
|
||||
. = TRUE
|
||||
if(3)
|
||||
if(ishuman(M))
|
||||
var/mob/living/carbon/human/H = M
|
||||
if(!H.undergoing_cardiac_arrest() && H.can_heartattack())
|
||||
H.set_heartattack(TRUE)
|
||||
if(H.stat == CONSCIOUS)
|
||||
H.visible_message("<span class='userdanger'>[H] clutches at [H.p_their()] chest as if [H.p_their()] heart stopped!</span>")
|
||||
else
|
||||
H.losebreath += 10
|
||||
H.adjustOxyLoss(rand(5,25), 0)
|
||||
. = 1
|
||||
if(!C.undergoing_cardiac_arrest() && C.can_heartattack())
|
||||
C.set_heartattack(TRUE)
|
||||
if(C.stat == CONSCIOUS)
|
||||
C.visible_message("<span class='userdanger'>[C] clutches at [C.p_their()] chest as if [C.p_their()] heart stopped!</span>")
|
||||
else
|
||||
C.losebreath += 10
|
||||
C.adjustOxyLoss(rand(5,25), 0)
|
||||
. = TRUE
|
||||
return ..() || .
|
||||
|
||||
/datum/reagent/toxin/pancuronium
|
||||
@@ -571,10 +556,10 @@
|
||||
toxpwr = 0
|
||||
taste_mult = 0 // undetectable, I guess?
|
||||
|
||||
/datum/reagent/toxin/pancuronium/on_mob_life(mob/living/M)
|
||||
/datum/reagent/toxin/pancuronium/on_mob_life(mob/living/carbon/M)
|
||||
if(current_cycle >= 10)
|
||||
M.Stun(40, 0)
|
||||
. = 1
|
||||
. = TRUE
|
||||
if(prob(20))
|
||||
M.losebreath += 4
|
||||
..()
|
||||
@@ -588,12 +573,12 @@
|
||||
metabolization_rate = 0.75 * REAGENTS_METABOLISM
|
||||
toxpwr = 0
|
||||
|
||||
/datum/reagent/toxin/sodium_thiopental/on_mob_life(mob/living/M)
|
||||
/datum/reagent/toxin/sodium_thiopental/on_mob_life(mob/living/carbon/M)
|
||||
if(current_cycle >= 10)
|
||||
M.Sleeping(40, 0)
|
||||
M.adjustStaminaLoss(10*REM, 0)
|
||||
..()
|
||||
. = 1
|
||||
return TRUE
|
||||
|
||||
/datum/reagent/toxin/sulfonal
|
||||
name = "Sulfonal"
|
||||
@@ -604,7 +589,7 @@
|
||||
metabolization_rate = 0.125 * REAGENTS_METABOLISM
|
||||
toxpwr = 0.5
|
||||
|
||||
/datum/reagent/toxin/sulfonal/on_mob_life(mob/living/M)
|
||||
/datum/reagent/toxin/sulfonal/on_mob_life(mob/living/carbon/M)
|
||||
if(current_cycle >= 22)
|
||||
M.Sleeping(40, 0)
|
||||
return ..()
|
||||
@@ -634,7 +619,7 @@
|
||||
metabolization_rate = 0.5 * REAGENTS_METABOLISM
|
||||
toxpwr = 0
|
||||
|
||||
/datum/reagent/toxin/lipolicide/on_mob_life(mob/living/M)
|
||||
/datum/reagent/toxin/lipolicide/on_mob_life(mob/living/carbon/M)
|
||||
if(M.nutrition <= NUTRITION_LEVEL_STARVING)
|
||||
M.adjustToxLoss(1*REM, 0)
|
||||
M.nutrition = max(M.nutrition - 3, 0) // making the chef more valuable, one meme trap at a time
|
||||
@@ -650,7 +635,7 @@
|
||||
metabolization_rate = 0.06 * REAGENTS_METABOLISM
|
||||
toxpwr = 1.75
|
||||
|
||||
/datum/reagent/toxin/coniine/on_mob_life(mob/living/M)
|
||||
/datum/reagent/toxin/coniine/on_mob_life(mob/living/carbon/M)
|
||||
M.losebreath += 5
|
||||
return ..()
|
||||
|
||||
@@ -665,22 +650,20 @@
|
||||
toxpwr = 0
|
||||
taste_description = "vomit"
|
||||
|
||||
/datum/reagent/toxin/spewium/on_mob_life(mob/living/M)
|
||||
/datum/reagent/toxin/spewium/on_mob_life(mob/living/carbon/C)
|
||||
.=..()
|
||||
if(current_cycle >=11 && prob(min(50,current_cycle)) && ishuman(M))
|
||||
var/mob/living/carbon/human/H = M
|
||||
H.vomit(10, prob(10), prob(50), rand(0,4), TRUE, prob(30))
|
||||
for(var/datum/reagent/toxin/R in M.reagents.reagent_list)
|
||||
if(current_cycle >=11 && prob(min(50,current_cycle)))
|
||||
C.vomit(10, prob(10), prob(50), rand(0,4), TRUE, prob(30))
|
||||
for(var/datum/reagent/toxin/R in C.reagents.reagent_list)
|
||||
if(R != src)
|
||||
H.reagents.remove_reagent(R.id,1)
|
||||
C.reagents.remove_reagent(R.id,1)
|
||||
|
||||
/datum/reagent/toxin/spewium/overdose_process(mob/living/M)
|
||||
/datum/reagent/toxin/spewium/overdose_process(mob/living/carbon/C)
|
||||
. = ..()
|
||||
if(current_cycle >=33 && prob(15) && ishuman(M))
|
||||
var/mob/living/carbon/human/H = M
|
||||
H.spew_organ()
|
||||
H.vomit(0, TRUE, TRUE, 4)
|
||||
to_chat(H, "<span class='userdanger'>You feel something lumpy come up as you vomit.</span>")
|
||||
if(current_cycle >=33 && prob(15))
|
||||
C.spew_organ()
|
||||
C.vomit(0, TRUE, TRUE, 4)
|
||||
to_chat(C, "<span class='userdanger'>You feel something lumpy come up as you vomit.</span>")
|
||||
|
||||
/datum/reagent/toxin/curare
|
||||
name = "Curare"
|
||||
@@ -691,7 +674,7 @@
|
||||
metabolization_rate = 0.125 * REAGENTS_METABOLISM
|
||||
toxpwr = 1
|
||||
|
||||
/datum/reagent/toxin/curare/on_mob_life(mob/living/M)
|
||||
/datum/reagent/toxin/curare/on_mob_life(mob/living/carbon/M)
|
||||
if(current_cycle >= 11)
|
||||
M.Knockdown(60, 0)
|
||||
M.adjustOxyLoss(1*REM, 0)
|
||||
@@ -707,7 +690,7 @@
|
||||
metabolization_rate = 0.2 * REAGENTS_METABOLISM
|
||||
toxpwr = 0
|
||||
|
||||
/datum/reagent/toxin/heparin/on_mob_life(mob/living/M)
|
||||
/datum/reagent/toxin/heparin/on_mob_life(mob/living/carbon/M)
|
||||
if(ishuman(M))
|
||||
var/mob/living/carbon/human/H = M
|
||||
H.bleed_rate = min(H.bleed_rate + 2, 8)
|
||||
@@ -726,7 +709,7 @@
|
||||
toxpwr = 0.5
|
||||
taste_description = "spinning"
|
||||
|
||||
/datum/reagent/toxin/rotatium/on_mob_life(mob/living/M)
|
||||
/datum/reagent/toxin/rotatium/on_mob_life(mob/living/carbon/M)
|
||||
if(M.hud_used)
|
||||
if(current_cycle >= 20 && current_cycle%20 == 0)
|
||||
var/list/screens = list(M.hud_used.plane_masters["[FLOOR_PLANE]"], M.hud_used.plane_masters["[GAME_PLANE]"], M.hud_used.plane_masters["[LIGHTING_PLANE]"])
|
||||
@@ -753,7 +736,7 @@
|
||||
toxpwr = 0.25
|
||||
taste_description = "skewing"
|
||||
|
||||
/datum/reagent/toxin/skewium/on_mob_life(mob/living/M)
|
||||
/datum/reagent/toxin/skewium/on_mob_life(mob/living/carbon/M)
|
||||
if(M.hud_used)
|
||||
if(current_cycle >= 5 && current_cycle % 3 == 0)
|
||||
var/list/screens = list(M.hud_used.plane_masters["[FLOOR_PLANE]"], M.hud_used.plane_masters["[GAME_PLANE]"], M.hud_used.plane_masters["[LIGHTING_PLANE]"])
|
||||
@@ -788,7 +771,7 @@
|
||||
metabolization_rate = 0.08 * REAGENTS_METABOLISM
|
||||
toxpwr = 0.15
|
||||
|
||||
/datum/reagent/toxin/anacea/on_mob_life(mob/living/M)
|
||||
/datum/reagent/toxin/anacea/on_mob_life(mob/living/carbon/M)
|
||||
var/remove_amt = 5
|
||||
if(holder.has_reagent("calomel") || holder.has_reagent("pen_acid"))
|
||||
remove_amt = 0.5
|
||||
@@ -841,7 +824,7 @@
|
||||
toxpwr = 2
|
||||
acidpwr = 42.0
|
||||
|
||||
/datum/reagent/toxin/acid/fluacid/on_mob_life(mob/living/M)
|
||||
/datum/reagent/toxin/acid/fluacid/on_mob_life(mob/living/carbon/M)
|
||||
M.adjustFireLoss(current_cycle/10, 0)
|
||||
. = 1
|
||||
..()
|
||||
@@ -857,7 +840,7 @@
|
||||
var/actual_toxpwr = 5
|
||||
var/delay = 30
|
||||
|
||||
/datum/reagent/toxin/delayed/on_mob_life(mob/living/M)
|
||||
/datum/reagent/toxin/delayed/on_mob_life(mob/living/carbon/M)
|
||||
if(current_cycle > delay)
|
||||
holder.remove_reagent(id, actual_metaboliztion_rate * M.metabolism_efficiency)
|
||||
M.adjustToxLoss(actual_toxpwr*REM, 0)
|
||||
|
||||
@@ -113,7 +113,15 @@
|
||||
build_type = BIOGENERATOR
|
||||
materials = list(MAT_BIOMASS = 50)
|
||||
build_path = /obj/item/stack/sheet/cloth
|
||||
category = list("initial","Leather and Cloth")
|
||||
category = list("initial","Organic Materials")
|
||||
|
||||
/datum/design/cardboard
|
||||
name = "Sheet of Cardboard"
|
||||
id = "cardboard"
|
||||
build_type = BIOGENERATOR
|
||||
materials = list(MAT_BIOMASS = 25)
|
||||
build_path = /obj/item/stack/sheet/cardboard
|
||||
category = list("initial","Organic Materials")
|
||||
|
||||
/datum/design/leather
|
||||
name = "Sheet of Leather"
|
||||
@@ -121,7 +129,7 @@
|
||||
build_type = BIOGENERATOR
|
||||
materials = list(MAT_BIOMASS = 150)
|
||||
build_path = /obj/item/stack/sheet/leather
|
||||
category = list("initial","Leather and Cloth")
|
||||
category = list("initial","Organic Materials")
|
||||
|
||||
/datum/design/secbelt
|
||||
name = "Security Belt"
|
||||
|
||||
@@ -99,13 +99,7 @@
|
||||
|
||||
return DOCKING_SUCCESS
|
||||
|
||||
/obj/docking_port/mobile/proc/preflight_check(
|
||||
list/old_turfs,
|
||||
list/new_turfs,
|
||||
list/areas_to_move,
|
||||
rotation,
|
||||
)
|
||||
|
||||
/obj/docking_port/mobile/proc/preflight_check(list/old_turfs, list/new_turfs, list/areas_to_move, rotation)
|
||||
for(var/i in 1 to old_turfs.len)
|
||||
CHECK_TICK
|
||||
var/turf/oldT = old_turfs[i]
|
||||
@@ -134,16 +128,7 @@
|
||||
|
||||
old_turfs[oldT] = move_mode
|
||||
|
||||
/obj/docking_port/mobile/proc/takeoff(
|
||||
list/old_turfs,
|
||||
list/new_turfs,
|
||||
list/moved_atoms,
|
||||
rotation,
|
||||
movement_direction,
|
||||
old_dock,
|
||||
area/underlying_old_area,
|
||||
)
|
||||
|
||||
/obj/docking_port/mobile/proc/takeoff(list/old_turfs, list/new_turfs, list/moved_atoms, rotation, movement_direction, old_dock, area/underlying_old_area)
|
||||
for(var/i in 1 to old_turfs.len)
|
||||
var/turf/oldT = old_turfs[i]
|
||||
var/turf/newT = new_turfs[i]
|
||||
@@ -163,17 +148,7 @@
|
||||
var/area/shuttle_area = oldT.loc
|
||||
shuttle_area.onShuttleMove(oldT, newT, underlying_old_area) //areas
|
||||
|
||||
/obj/docking_port/mobile/proc/cleanup_runway(
|
||||
obj/docking_port/stationary/new_dock,
|
||||
list/old_turfs,
|
||||
list/new_turfs,
|
||||
list/areas_to_move,
|
||||
list/moved_atoms,
|
||||
rotation,
|
||||
movement_direction,
|
||||
area/underlying_old_area,
|
||||
)
|
||||
|
||||
/obj/docking_port/mobile/proc/cleanup_runway(obj/docking_port/stationary/new_dock, list/old_turfs, list/new_turfs, list/areas_to_move, list/moved_atoms, rotation, movement_direction, area/underlying_old_area)
|
||||
underlying_old_area.afterShuttleMove()
|
||||
|
||||
// Parallax handling
|
||||
@@ -202,14 +177,28 @@
|
||||
var/turf/oldT = moved_atoms[moved_object]
|
||||
moved_object.afterShuttleMove(oldT, movement_force, dir, preferred_direction, movement_direction, rotation)//atoms
|
||||
|
||||
// lateShuttleMove (There had better be a really good reason for additional stages beyond this)
|
||||
|
||||
underlying_old_area.lateShuttleMove()
|
||||
|
||||
for(var/i in 1 to areas_to_move.len)
|
||||
CHECK_TICK
|
||||
var/area/internal_area = areas_to_move[i]
|
||||
internal_area.lateShuttleMove()
|
||||
|
||||
for(var/i in 1 to old_turfs.len)
|
||||
CHECK_TICK
|
||||
// Objects can block air so either turf or content changes means an air update is needed
|
||||
if(!(old_turfs[old_turfs[i]] & MOVE_CONTENTS | MOVE_TURF))
|
||||
continue
|
||||
var/turf/oldT = old_turfs[i]
|
||||
var/turf/newT = new_turfs[i]
|
||||
oldT.blocks_air = initial(oldT.blocks_air)
|
||||
oldT.air_update_turf(TRUE)
|
||||
newT.blocks_air = initial(newT.blocks_air)
|
||||
newT.air_update_turf(TRUE)
|
||||
newT.lateShuttleMove(oldT)
|
||||
|
||||
for(var/i in 1 to moved_atoms.len)
|
||||
CHECK_TICK
|
||||
var/atom/movable/moved_object = moved_atoms[i]
|
||||
if(QDELETED(moved_object))
|
||||
continue
|
||||
var/turf/oldT = moved_atoms[moved_object]
|
||||
moved_object.lateShuttleMove(oldT, movement_force, movement_direction)
|
||||
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user