Merge remote-tracking branch 'origin/master' into TGUI-4

This commit is contained in:
Letter N
2020-07-30 14:43:52 +08:00
662 changed files with 13844 additions and 6845 deletions
@@ -1962,12 +1962,12 @@ All effects don't start immediately, but rather get worse over time; the rate is
/datum/reagent/consumable/ethanol/bug_spray/on_mob_life(mob/living/carbon/M)
//Bugs should not drink Bug spray.
if(ismoth(M) || isflyperson(M))
if(isinsect(M) || isflyperson(M))
M.adjustToxLoss(1,0)
return ..()
/datum/reagent/consumable/ethanol/bug_spray/on_mob_add(mob/living/carbon/M)
if(ismoth(M) || isflyperson(M))
if(isinsect(M) || isflyperson(M))
M.emote("scream")
return ..()
@@ -2270,25 +2270,29 @@ All effects don't start immediately, but rather get worse over time; the rate is
////////////////////
//Race-Base-Drinks//
////////////////////
/datum/reagent/consumable/ethanol/species_drink
var/species_required
var/disgust = 25
boozepwr = 50
/datum/reagent/consumable/ethanol/coldscales
/datum/reagent/consumable/ethanol/species_drink/on_mob_life(mob/living/carbon/C)
if(C.dna.species && C.dna.species.species_type == species_required) //species have a species_type variable that refers to one of the drinks
quality = RACE_DRINK
else
C.adjust_disgust(disgust)
/datum/reagent/consumable/ethanol/species_drink/coldscales
name = "Coldscales"
color = "#5AEB52" //(90, 235, 82)
description = "A cold looking drink made for people with scales."
boozepwr = 50 //strong!
taste_description = "dead flies"
glass_icon_state = "coldscales"
glass_name = "glass of Coldscales"
glass_desc = "A soft green drink that looks inviting!"
/datum/reagent/consumable/ethanol/coldscales/on_mob_life(mob/living/carbon/M)
if(islizard(M))
quality = RACE_DRINK
else
M.adjust_disgust(25)
return ..()
species_required = "lizard"
/datum/reagent/consumable/ethanol/oil_drum
/datum/reagent/consumable/ethanol/species_drink/oil_drum
name = "Oil Drum"
color = "#000000" //(0, 0, 0)
description = "Industrial grade oil mixed with some ethanol to make it a drink. Somehow not known to be toxic."
@@ -2298,31 +2302,20 @@ All effects don't start immediately, but rather get worse over time; the rate is
glass_name = "Drum of oil"
glass_desc = "A gray can of booze and oil..."
/datum/reagent/consumable/ethanol/oil_drum/on_mob_life(mob/living/carbon/M)
if(isipcperson(M) || issynthliz(M))
quality = RACE_DRINK
else
M.adjust_disgust(25)
return ..()
species_required = "robot"
/datum/reagent/consumable/ethanol/nord_king
/datum/reagent/consumable/ethanol/species_drink/nord_king
name = "Nord King"
color = "#EB1010" //(235, 16, 16)
description = "Strong mead mixed with more honey and ethanol. Beloved by its human patrons."
boozepwr = 50 //strong!
taste_description = "honey and red wine"
glass_icon_state = "nord_king"
glass_name = "Keg of Nord King"
glass_desc = "A dripping keg of red mead."
/datum/reagent/consumable/ethanol/nord_king/on_mob_life(mob/living/carbon/M)
if(ishumanbasic(M) || isdwarf(M) || isangel(M)) //Humans and angel races are rare
quality = RACE_DRINK
else
M.adjust_disgust(25)
return ..()
species_required = "basic"
/datum/reagent/consumable/ethanol/velvet_kiss
/datum/reagent/consumable/ethanol/species_drink/velvet_kiss
name = "Velvet Kiss"
color = "#EB1010" //(235, 16, 16)
description = "A bloody drink mixed with wine."
@@ -2332,14 +2325,9 @@ All effects don't start immediately, but rather get worse over time; the rate is
glass_name = "glass of Velvet Kiss"
glass_desc = "Red and white drink for the upper classes or undead."
/datum/reagent/consumable/ethanol/velvet_kiss/on_mob_life(mob/living/carbon/M)
if(iszombie(M) || isvampire(M) || isdullahan(M)) //Rare races!
quality = RACE_DRINK
else
M.adjust_disgust(25)
return ..()
species_required = "undead"
/datum/reagent/consumable/ethanol/abduction_fruit
/datum/reagent/consumable/ethanol/species_drink/abduction_fruit
name = "Abduction Fruit"
color = "#DEFACD" //(222, 250, 205)
description = "Mixing of juices to make an alien taste."
@@ -2349,14 +2337,9 @@ All effects don't start immediately, but rather get worse over time; the rate is
glass_name = "glass of Abduction Fruit"
glass_desc = "Mixed fruits that were never meant to be mixed..."
/datum/reagent/consumable/ethanol/abduction_fruit/on_mob_life(mob/living/carbon/M)
if(isabductor(M) || isxenoperson(M))
quality = RACE_DRINK
else
M.adjust_disgust(25)
return ..()
species_required = "alien"
/datum/reagent/consumable/ethanol/bug_zapper
/datum/reagent/consumable/ethanol/species_drink/bug_zapper
name = "Bug Zapper"
color = "#F5882A" //(222, 250, 205)
description = "Copper and lemon juice. Hardly even a drink."
@@ -2366,14 +2349,9 @@ All effects don't start immediately, but rather get worse over time; the rate is
glass_name = "glass of Bug Zapper"
glass_desc = "An odd mix of copper, lemon juice and power meant for non-human consumption."
/datum/reagent/consumable/ethanol/bug_zapper/on_mob_life(mob/living/carbon/M)
if(isinsect(M) || isflyperson(M) || ismoth(M))
quality = RACE_DRINK
else
M.adjust_disgust(25)
return ..()
species_required = "bug"
/datum/reagent/consumable/ethanol/mush_crush
/datum/reagent/consumable/ethanol/species_drink/mush_crush
name = "Mush Crush"
color = "#F5882A" //(222, 250, 205)
description = "Soil in a glass."
@@ -2383,14 +2361,9 @@ All effects don't start immediately, but rather get worse over time; the rate is
glass_name = "glass of Mush Crush"
glass_desc = "Popular among people that want to grow their own food rather than drink the soil."
/datum/reagent/consumable/ethanol/mush_crush/on_mob_life(mob/living/carbon/M)
if(ispodperson(M) || ismush(M))
quality = RACE_DRINK
else
M.adjust_disgust(25)
return ..()
species_required = "plant"
/datum/reagent/consumable/ethanol/darkbrew
/datum/reagent/consumable/ethanol/species_drink/darkbrew
name = "Darkbrew"
color = "#000000" //(0, 0, 0)
description = "Contained dark matter mixed with coffee."
@@ -2400,31 +2373,21 @@ All effects don't start immediately, but rather get worse over time; the rate is
glass_name = "glass of Darkbrew"
glass_desc = "A pitch black drink that's commonly confused with a type of coffee."
/datum/reagent/consumable/ethanol/darkbrew/on_mob_life(mob/living/carbon/M)
if(isshadow(M))
quality = RACE_DRINK
else
M.adjust_disgust(25)
return ..()
species_required = "shadow"
/datum/reagent/consumable/ethanol/hollow_bone
/datum/reagent/consumable/ethanol/species_drink/hollow_bone
name = "Hollow Bone"
color = "#FCF7D4" //(252, 247, 212)
description = "Shockingly none-harmful mix of toxins and milk."
description = "Shockingly non-harmful mix of toxins and milk."
boozepwr = 15
taste_description = "Milk and salt"
glass_icon_state = "hollow_bone"
glass_name = "skull of Hollow Bone"
glass_desc = "Mixing of milk and bone hurting juice for enjoyment for rather skinny people."
glass_desc = "Mixing of milk and bone hurting juice for the enjoyment of rather skinny people."
/datum/reagent/consumable/ethanol/hollow_bone/on_mob_life(mob/living/carbon/M)
if(isplasmaman(M) || isskeleton(M))
quality = RACE_DRINK
else
M.adjust_disgust(25)
return ..()
species_required = "skeleton"
/datum/reagent/consumable/ethanol/frisky_kitty
/datum/reagent/consumable/ethanol/species_drink/frisky_kitty
name = "Frisky Kitty"
color = "#FCF7D4" //(252, 247, 212)
description = "Warm milk mixed with a catnip."
@@ -2434,14 +2397,9 @@ All effects don't start immediately, but rather get worse over time; the rate is
glass_name = "cup of Drisky Kitty"
glass_desc = "Warm milk and some catnip."
/datum/reagent/consumable/ethanol/frisky_kitty/on_mob_life(mob/living/carbon/M)
if(ismammal(M) || iscatperson(M)) //well its not to bad for mammals
quality = RACE_DRINK
else
M.adjust_disgust(25)
return ..()
species_required = "furry"
/datum/reagent/consumable/ethanol/jell_wyrm
/datum/reagent/consumable/ethanol/species_drink/jell_wyrm
name = "Jell Wyrm"
color = "#FF6200" //(255, 98, 0)
description = "Horrible mix of Co2, toxins and heat. Meant for slime based life."
@@ -2451,15 +2409,9 @@ All effects don't start immediately, but rather get worse over time; the rate is
glass_name = "glass of Jell Wyrm"
glass_desc = "A bubbly drink that is rather inviting to those that don't know who it's meant for."
/datum/reagent/consumable/ethanol/jell_wyrm/on_mob_life(mob/living/carbon/M)
if(isjellyperson(M) || isstartjelly(M) || isslimeperson(M) || isluminescent(M))
quality = RACE_DRINK
else
M.adjust_disgust(25)
M.adjustToxLoss(1, 0) //Low tox due to being carp + jell toxins.
return ..()
species_required = "jelly"
/datum/reagent/consumable/ethanol/laval_spit //Yes Laval
/datum/reagent/consumable/ethanol/species_drink/laval_spit //Yes Laval
name = "Laval Spit"
color = "#DE3009" //(222, 48, 9)
description = "Heat minerals and some mauna loa. Meant for rock based life."
@@ -2469,15 +2421,10 @@ All effects don't start immediately, but rather get worse over time; the rate is
glass_name = "glass of Laval Spit"
glass_desc = "Piping hot drink for those who can stomach the heat of lava."
/datum/reagent/consumable/ethanol/laval_spit/on_mob_life(mob/living/carbon/M)
if(isgolem(M))
quality = RACE_DRINK
else
M.adjust_disgust(25)
return ..()
species_required = "golem"
///////////////
//Barrle Wine//
//Barrel Wine//
///////////////
/datum/reagent/consumable/ethanol/fruit_wine
@@ -467,7 +467,7 @@
/datum/reagent/drug/skooma/on_mob_metabolize(mob/living/L)
. = ..()
L.add_movespeed_modifier(/datum/movespeed_modifier/reagent/skooma)
L.next_move_modifier *= 2
L.action_cooldown_mod *= 2
if(ishuman(L))
var/mob/living/carbon/human/H = L
if(H.physiology)
@@ -480,7 +480,7 @@
/datum/reagent/drug/skooma/on_mob_end_metabolize(mob/living/L)
. = ..()
L.remove_movespeed_modifier(/datum/movespeed_modifier/reagent/skooma)
L.next_move_modifier *= 0.5
L.action_cooldown_mod *= 0.5
if(ishuman(L))
var/mob/living/carbon/human/H = L
if(H.physiology)
@@ -542,13 +542,13 @@
/datum/reagent/syndicateadrenals/on_mob_metabolize(mob/living/M)
. = ..()
if(istype(M))
M.next_move_modifier *= 0.5
M.action_cooldown_mod *= 0.5
to_chat(M, "<span class='notice'>You feel an intense surge of energy rushing through your veins.</span>")
/datum/reagent/syndicateadrenals/on_mob_end_metabolize(mob/living/M)
. = ..()
if(istype(M))
M.next_move_modifier *= 2
M.action_cooldown_mod *= 2
to_chat(M, "<span class='notice'>You feel as though the world around you is going faster.</span>")
/datum/reagent/syndicateadrenals/overdose_start(mob/living/M)
@@ -144,6 +144,9 @@
M.adjustFireLoss(-power, 0)
M.adjustToxLoss(-power, 0, TRUE) //heals TOXINLOVERs
M.adjustCloneLoss(-power, 0)
for(var/i in M.all_wounds)
var/datum/wound/W = i
W.on_xadone(power)
REMOVE_TRAIT(M, TRAIT_DISFIGURED, TRAIT_GENERIC) //fixes common causes for disfiguration
. = 1
metabolization_rate = REAGENTS_METABOLISM * (0.00001 * (M.bodytemperature ** 2) + 0.5)
@@ -192,6 +195,9 @@
M.adjustFireLoss(-1.5 * power, 0)
M.adjustToxLoss(-power, 0, TRUE)
M.adjustCloneLoss(-power, 0)
for(var/i in M.all_wounds)
var/datum/wound/W = i
W.on_xadone(power)
REMOVE_TRAIT(M, TRAIT_DISFIGURED, TRAIT_GENERIC)
. = 1
..()
@@ -231,7 +237,7 @@
/datum/reagent/medicine/spaceacillin
name = "Spaceacillin"
description = "Spaceacillin will prevent a patient from conventionally spreading any diseases they are currently infected with."
description = "Spaceacillin will prevent a patient from conventionally spreading any diseases they are currently infected with. Also reduces infection in serious burns."
color = "#f2f2f2"
metabolization_rate = 0.1 * REAGENTS_METABOLISM
pH = 8.1
@@ -403,7 +409,7 @@
/datum/reagent/medicine/mine_salve
name = "Miner's Salve"
description = "A powerful painkiller. Restores bruising and burns in addition to making the patient believe they are fully healed."
description = "A powerful painkiller. Restores bruising and burns in addition to making the patient believe they are fully healed. Also great for treating severe burn wounds in a pinch."
reagent_state = LIQUID
color = "#6D6374"
metabolization_rate = 0.4 * REAGENTS_METABOLISM
@@ -432,7 +438,7 @@
// +10% success propability on each step, useful while operating in less-than-perfect conditions
if(show_message)
to_chat(M, "<span class='danger'>You feel your wounds fade away to nothing!</span>" )
to_chat(M, "<span class='danger'>You feel your injuries fade away to nothing!</span>" )
..()
/datum/reagent/medicine/mine_salve/on_mob_end_metabolize(mob/living/M)
@@ -453,10 +459,10 @@
/datum/reagent/medicine/synthflesh/reaction_mob(mob/living/M, method=TOUCH, reac_volume, show_message = 1)
if(iscarbon(M))
if (M.stat == DEAD)
var/mob/living/carbon/C = M
if(M.stat == DEAD)
show_message = 0
if(method in list(INGEST, VAPOR))
var/mob/living/carbon/C = M
C.losebreath++
C.emote("cough")
to_chat(M, "<span class='danger'>You feel your throat closing up!</span>")
@@ -465,6 +471,8 @@
else if(method in list(PATCH, TOUCH))
M.adjustBruteLoss(-1 * reac_volume)
M.adjustFireLoss(-1 * reac_volume)
for(var/datum/wound/burn/burn_wound in C.all_wounds)
burn_wound.regenerate_flesh(reac_volume)
if(show_message)
to_chat(M, "<span class='danger'>You feel your burns and bruises healing! It stings like hell!</span>")
SEND_SIGNAL(M, COMSIG_ADD_MOOD_EVENT, "painful_medicine", /datum/mood_event/painful_medicine)
@@ -1552,10 +1560,6 @@
/datum/reagent/medicine/polypyr/on_mob_life(mob/living/carbon/M) //I wanted a collection of small positive effects, this is as hard to obtain as coniine after all.
M.adjustOrganLoss(ORGAN_SLOT_LUNGS, -0.25)
M.adjustBruteLoss(-0.35, 0)
if(prob(50))
if(ishuman(M))
var/mob/living/carbon/human/H = M
H.bleed_rate = max(H.bleed_rate - 1, 0)
..()
. = 1
@@ -1588,3 +1592,10 @@
to_chat(C, "[pick(GLOB.wisdoms)]") //give them a random wisdom
..()
// handled in cut wounds process
/datum/reagent/medicine/coagulant
name = "Sanguirite"
description = "A coagulant used to help open cuts clot faster."
reagent_state = LIQUID
color = "#bb2424"
metabolization_rate = 0.25 * REAGENTS_METABOLISM
@@ -2296,9 +2296,93 @@
if(data["blood_DNA"])
S.add_blood_DNA(list(data["blood_DNA"] = data["blood_type"]))
/datum/reagent/determination
name = "Determination"
description = "For when you need to push on a little more. Do NOT allow near plants."
reagent_state = LIQUID
color = "#D2FFFA"
metabolization_rate = 0.75 * REAGENTS_METABOLISM // 5u (WOUND_DETERMINATION_CRITICAL) will last for ~17 ticks
/// Whether we've had at least WOUND_DETERMINATION_SEVERE (2.5u) of determination at any given time. No damage slowdown immunity or indication we're having a second wind if it's just a single moderate wound
var/significant = FALSE
/datum/reagent/determination/on_mob_end_metabolize(mob/living/carbon/M)
if(significant)
var/stam_crash = 0
for(var/thing in M.all_wounds)
var/datum/wound/W = thing
stam_crash += (W.severity + 1) * 3 // spike of 3 stam damage per wound severity (moderate = 6, severe = 9, critical = 12) when the determination wears off if it was a combat rush
M.adjustStaminaLoss(stam_crash)
M.remove_status_effect(STATUS_EFFECT_DETERMINED)
..()
/datum/reagent/determination/on_mob_life(mob/living/carbon/M)
if(!significant && volume >= WOUND_DETERMINATION_SEVERE)
significant = TRUE
M.apply_status_effect(STATUS_EFFECT_DETERMINED) // in addition to the slight healing, limping cooldowns are divided by 4 during the combat high
volume = min(volume, WOUND_DETERMINATION_MAX)
for(var/thing in M.all_wounds)
var/datum/wound/W = thing
var/obj/item/bodypart/wounded_part = W.limb
if(wounded_part)
wounded_part.heal_damage(0.25, 0.25)
M.adjustStaminaLoss(-0.25*REM) // the more wounds, the more stamina regen
..()
/datum/reagent/cellulose
name = "Cellulose Fibers"
description = "A crystaline polydextrose polymer, plants swear by this stuff."
reagent_state = SOLID
color = "#E6E6DA"
taste_mult = 0
taste_mult = 0
/datum/reagent/hairball
name = "Hairball"
description = "A bundle of keratinous bits and fibers, not easily digestible."
reagent_state = SOLID
can_synth = FALSE
metabolization_rate = 0.05 * REAGENTS_METABOLISM
taste_description = "wet hair"
var/amount = 0
var/knotted = FALSE
/datum/reagent/hairball/on_mob_life(mob/living/carbon/M)
amount = M.reagents.get_reagent_amount(/datum/reagent/hairball)
if(amount < 10)
if(prob(10))
M.losebreath += 1
M.emote("cough")
to_chat(M, "<span class='notice'>You clear your throat.</span>")
else
if(!knotted)
to_chat(M, "<span class='notice'>You feel a knot in your stomach.</span>")
knotted = TRUE
if(prob(5 + amount * 0.5)) // don't want this to cause too much damage
M.losebreath += 2
to_chat(M, "<span class='notice'>You feel a knot in your throat.</span>")
M.emote("cough")
else if(prob(amount - 4))
to_chat(M, "<span class='warning'>Your stomach feels awfully bloated.</span>")
playsound(M,'sound/voice/catpeople/distressed.ogg', 50, FALSE)
M.visible_message("<span class='warning'>[M] seems distressed!.</span>", ignored_mobs=M)
else if(prob(amount - 8))
knotted = FALSE
playsound(M,'sound/voice/catpeople/puking.ogg', 110, FALSE)
M.Immobilize(30)
sleep(30) //snowflake but it works, don't wanna proc this
if(QDELETED(M) || QDELETED(src)) //this handles race conditions about m or src not existing.
return
M.visible_message("<span class='warning'>[M] throws up a hairball! Disgusting!</span>", ignored_mobs=M)
new /obj/item/toy/plush/hairball(get_turf(M))
to_chat(M, "<span class='notice'>Aaaah that's better!</span>")
SEND_SIGNAL(M, COMSIG_ADD_MOOD_EVENT, "cleared_stomach", /datum/mood_event/cleared_stomach, name)
M.reagents.del_reagent(/datum/reagent/hairball)
return
..()
@@ -154,6 +154,11 @@
pH = 12
value = REAGENT_VALUE_RARE
/datum/reagent/toxin/carpotoxin/on_mob_life(mob/living/carbon/M)
. = ..()
for(var/i in M.all_scars)
qdel(i)
/datum/reagent/toxin/zombiepowder
name = "Zombie Powder"
description = "A strong neurotoxin that puts the subject into a death-like state."
@@ -717,22 +722,13 @@
/datum/reagent/toxin/heparin //Based on a real-life anticoagulant. I'm not a doctor, so this won't be realistic.
name = "Heparin"
description = "A powerful anticoagulant. Victims will bleed uncontrollably and suffer scaling bruising."
description = "A powerful anticoagulant. All open cut wounds on the victim will open up and bleed much faster"
reagent_state = LIQUID
color = "#C8C8C8" //RGB: 200, 200, 200
metabolization_rate = 0.2 * REAGENTS_METABOLISM
toxpwr = 0
value = REAGENT_VALUE_VERY_RARE
/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)
H.adjustBruteLoss(1, 0) //Brute damage increases with the amount they're bleeding
. = 1
return ..() || .
/datum/reagent/toxin/rotatium //Rotatium. Fucks up your rotation and is hilarious
name = "Rotatium"
description = "A constantly swirling, oddly colourful fluid. Causes the consumer's sense of direction and hand-eye coordination to become wild."
+2 -1
View File
@@ -69,7 +69,8 @@
to_chat(user, "<span class='notice'>[src]'s transfer amount is now [amount_per_transfer_from_this] units.</span>")
return
/obj/item/reagent_containers/attack(mob/M, mob/user, def_zone)
/obj/item/reagent_containers/attack(mob/living/M, mob/living/user, attackchain_flags = NONE, damage_multiplier = 1)
. = ..()
if(user.a_intent == INTENT_HARM)
return ..()
@@ -9,6 +9,11 @@
container_HP = 2
/obj/item/reagent_containers/glass/attack(mob/M, mob/user, obj/target)
// WARNING: This entire section is shitcode and prone to breaking at any time.
INVOKE_ASYNC(src, .proc/attempt_feed, M, user, target) // for example, the arguments in this proc are wrong
// but i don't have time to properly fix it right now.
/obj/item/reagent_containers/glass/proc/attempt_feed(mob/M, mob/user, obj/target)
if(!canconsume(M, user))
return
@@ -90,12 +90,12 @@
item_state = "medipen"
lefthand_file = 'icons/mob/inhands/equipment/medical_lefthand.dmi'
righthand_file = 'icons/mob/inhands/equipment/medical_righthand.dmi'
amount_per_transfer_from_this = 13
volume = 13
amount_per_transfer_from_this = 15
volume = 15
ignore_flags = 1 //so you can medipen through hardsuits
reagent_flags = DRAWABLE
flags_1 = null
list_reagents = list(/datum/reagent/medicine/epinephrine = 10, /datum/reagent/preservahyde = 3)
list_reagents = list(/datum/reagent/medicine/epinephrine = 10, /datum/reagent/preservahyde = 3, /datum/reagent/medicine/coagulant = 2)
custom_premium_price = PRICE_ALMOST_EXPENSIVE
/obj/item/reagent_containers/hypospray/medipen/suicide_act(mob/living/carbon/user)
@@ -133,6 +133,13 @@
else
. += "<span class='notice'>It is spent.</span>"
/obj/item/reagent_containers/hypospray/medipen/ekit
name = "emergency first-aid autoinjector"
desc = "An epinephrine medipen with trace amounts of coagulants and antibiotics to help stabilize bad cuts and burns."
volume = 15
amount_per_transfer_from_this = 15
list_reagents = list(/datum/reagent/medicine/epinephrine = 12, /datum/reagent/medicine/coagulant = 2.5, /datum/reagent/medicine/spaceacillin = 0.5)
/obj/item/reagent_containers/hypospray/medipen/stimulants
name = "illegal stimpack medipen"
desc = "A highly illegal medipen due to its load and small injections, allow for five uses before being drained"
@@ -354,13 +361,17 @@
obj_flags |= EMAGGED
return TRUE
/obj/item/hypospray/mkii/attack_hand(mob/user, act_intent = user.a_intent, unarmed_attack_flags)
/obj/item/hypospray/mkii/on_attack_hand(mob/user, act_intent = user.a_intent, unarmed_attack_flags)
. = ..() //Don't bother changing this or removing it from containers will break.
/obj/item/hypospray/mkii/attack(obj/item/I, mob/user, params)
return
/obj/item/hypospray/mkii/afterattack(atom/target, mob/user, proximity)
. = ..()
INVOKE_ASYNC(src, .proc/attempt_inject, target, user, proximity)
/obj/item/hypospray/mkii/proc/attempt_inject(atom/target, mob/user, proximity)
if(!vial || !proximity || !isliving(target))
return
var/mob/living/L = target
@@ -88,7 +88,7 @@
user.visible_message("<span class='notice'>[user] inserts a power cell into [src].</span>", "<span class='notice'>You insert the power cell into [src].</span>")
update_icon()
/obj/item/reagent_containers/glass/maunamug/attack_hand(mob/living/user, act_intent = user.a_intent, unarmed_attack_flags)
/obj/item/reagent_containers/glass/maunamug/on_attack_hand(mob/living/user, act_intent = user.a_intent, unarmed_attack_flags)
if(cell && open)
cell.update_icon()
user.put_in_hands(cell)
@@ -28,22 +28,24 @@
/obj/item/reagent_containers/pill/get_w_volume() // DEFAULT_VOLUME_TINY at 25u, DEFAULT_VOLUME_SMALL at 50u
return DEFAULT_VOLUME_TINY/2 + reagents.total_volume / reagents.maximum_volume * DEFAULT_VOLUME_TINY
/obj/item/reagent_containers/pill/attack(mob/M, mob/user, def_zone)
/obj/item/reagent_containers/pill/attack(mob/living/M, mob/living/user, attackchain_flags = NONE, damage_multiplier = 1)
INVOKE_ASYNC(src, .proc/attempt_feed, M, user)
/obj/item/reagent_containers/pill/proc/attempt_feed(mob/living/M, mob/living/user)
if(!canconsume(M, user))
return 0
return FALSE
if(M == user)
M.visible_message("<span class='notice'>[user] attempts to [apply_method] [src].</span>")
if(self_delay)
if(!do_mob(user, M, self_delay))
return 0
return FALSE
to_chat(M, "<span class='notice'>You [apply_method] [src].</span>")
else
M.visible_message("<span class='danger'>[user] attempts to force [M] to [apply_method] [src].</span>", \
"<span class='userdanger'>[user] attempts to force [M] to [apply_method] [src].</span>")
if(!do_mob(user, M))
return 0
return FALSE
M.visible_message("<span class='danger'>[user] forces [M] to [apply_method] [src].</span>", \
"<span class='userdanger'>[user] forces [M] to [apply_method] [src].</span>")
@@ -56,8 +58,7 @@
reagents.reaction(M, apply_type)
reagents.trans_to(M, reagents.total_volume)
qdel(src)
return 1
return TRUE
/obj/item/reagent_containers/pill/afterattack(obj/target, mob/user , proximity)
. = ..()
@@ -77,6 +78,7 @@
"<span class='notice'>You dissolve [src] in [target].</span>", vision_distance = 2)
reagents.trans_to(target, reagents.total_volume)
qdel(src)
return STOP_ATTACK_PROC_CHAIN
/obj/item/reagent_containers/pill/tox
name = "toxins pill"
@@ -55,11 +55,10 @@
if(do_after(user, action_speed, target = A))
user.visible_message("[user] finishes wiping off [A]!", "<span class='notice'>You finish wiping off [A].</span>")
SEND_SIGNAL(A, COMSIG_COMPONENT_CLEAN_ACT, CLEAN_MEDIUM)
return
/obj/item/reagent_containers/rag/alt_pre_attack(mob/living/M, mob/living/user, params)
if(istype(M) && user.a_intent == INTENT_HELP)
user.changeNext_move(CLICK_CD_MELEE)
user.DelayNextAction(CLICK_CD_MELEE)
if(M.on_fire)
user.visible_message("<span class='warning'>\The [user] uses \the [src] to pat out [M == user ? "[user.p_their()]" : "\the [M]'s"] flames!</span>")
if(hitsound)
@@ -193,4 +192,4 @@
extinguish_efficiency = 5
action_speed = 15
damp_threshold = 0.8
armor = list("melee" = 0, "bullet" = 0, "laser" = 0, "energy" = 0, "bomb" = 20, "bio" = 20, "rad" = 20, "fire" = 50, "acid" = 50) //items don't provide armor to wearers unlike clothing yet.
armor = list("melee" = 0, "bullet" = 0, "laser" = 0, "energy" = 0, "bomb" = 20, "bio" = 20, "rad" = 20, "fire" = 50, "acid" = 50) //items don't provide armor to wearers unlike clothing yet.
@@ -27,6 +27,8 @@
/obj/item/reagent_containers/spray/afterattack(atom/A, mob/user)
. = ..()
if(!user.CheckActionCooldown(CLICK_CD_MELEE))
return
if(istype(A, /obj/structure/sink) || istype(A, /obj/structure/janitorialcart) || istype(A, /obj/machinery/hydroponics))
return
@@ -50,7 +52,7 @@
spray(A)
playsound(src.loc, 'sound/effects/spray2.ogg', 50, 1, -6)
user.changeNext_move(CLICK_CD_RANGE*2)
user.last_action = world.time
user.newtonian_move(get_dir(A, user))
var/turf/T = get_turf(src)
if(reagents.has_reagent(/datum/reagent/toxin/acid))
@@ -42,8 +42,7 @@
mode = !mode
update_icon()
//ATTACK HAND IGNORING PARENT RETURN VALUE
/obj/item/reagent_containers/syringe/attack_hand()
/obj/item/reagent_containers/syringe/on_attack_hand()
. = ..()
update_icon()
@@ -53,8 +52,11 @@
/obj/item/reagent_containers/syringe/attackby(obj/item/I, mob/user, params)
return
/obj/item/reagent_containers/syringe/afterattack(atom/target, mob/user , proximity)
/obj/item/reagent_containers/syringe/afterattack(atom/target, mob/user, proximity)
. = ..()
INVOKE_ASYNC(src, .proc/attempt_inject, target, user, proximity)
/obj/item/reagent_containers/syringe/proc/attempt_inject(atom/target, mob/user, proximity)
if(busy)
return
if(!proximity)
+1 -1
View File
@@ -79,7 +79,7 @@
else
. += "There are no paper cups left."
/obj/structure/reagent_dispensers/water_cooler/attack_hand(mob/living/user, act_intent = user.a_intent, unarmed_attack_flags)
/obj/structure/reagent_dispensers/water_cooler/on_attack_hand(mob/living/user, act_intent = user.a_intent, unarmed_attack_flags)
. = ..()
if(.)
return