mirror of
https://github.com/CHOMPStation2/CHOMPStation2.git
synced 2026-08-27 23:29:10 +01:00
[MIRROR] Begin clickcode attack_self fix (#12173)
Co-authored-by: Cameron Lennox <killer65311@gmail.com>
This commit is contained in:
co-authored by
Cameron Lennox
parent
063cf6cf48
commit
3cac28f9ad
@@ -34,9 +34,6 @@
|
||||
WARNING("[src]([src.type]) starts with more reagents than it has total volume")
|
||||
starts_with = null // it should gc, since it's just strings and numbers
|
||||
|
||||
/obj/item/reagent_containers/attack_self(mob/user as mob)
|
||||
return
|
||||
|
||||
/obj/item/reagent_containers/afterattack(obj/target, mob/user, flag)
|
||||
return
|
||||
|
||||
|
||||
@@ -1,4 +1,7 @@
|
||||
/obj/item/reagent_containers/blood/attack_self(mob/living/user as mob)
|
||||
/obj/item/reagent_containers/blood/attack_self(mob/living/user)
|
||||
. = ..(user)
|
||||
if(.)
|
||||
return TRUE
|
||||
if(user.a_intent == I_HURT)
|
||||
if(reagents.total_volume && volume)
|
||||
var/remove_volume = volume* 0.1 //10% of what the bloodpack can hold.
|
||||
|
||||
@@ -180,7 +180,10 @@
|
||||
balloon_alert(M, "you feel a tiny prick!")
|
||||
return
|
||||
|
||||
/obj/item/reagent_containers/borghypo/attack_self(mob/user as mob) //Change the mode
|
||||
/obj/item/reagent_containers/borghypo/attack_self(mob/user) //Change the mode
|
||||
. = ..(user)
|
||||
if(.)
|
||||
return TRUE
|
||||
tgui_interact(user)
|
||||
return
|
||||
|
||||
|
||||
@@ -56,6 +56,9 @@
|
||||
)
|
||||
//CHOMP Addition for feeder in the above list. I am paranoid about comments within lists so this is outside.
|
||||
|
||||
///Var for attack_self chain
|
||||
var/special_handling = FALSE
|
||||
|
||||
/obj/item/reagent_containers/glass/Initialize(mapload)
|
||||
. = ..()
|
||||
if(LAZYLEN(prefill))
|
||||
@@ -77,7 +80,11 @@
|
||||
. += span_notice("Airtight lid seals it completely.")
|
||||
|
||||
/obj/item/reagent_containers/glass/attack_self(mob/user)
|
||||
..()
|
||||
. = ..(user)
|
||||
if(.)
|
||||
return TRUE
|
||||
if(special_handling)
|
||||
return FALSE
|
||||
if(is_open_container())
|
||||
balloon_alert(user, "lid put on \the [src]")
|
||||
flags ^= OPENCONTAINER
|
||||
|
||||
@@ -69,7 +69,7 @@
|
||||
return
|
||||
|
||||
/*
|
||||
/obj/item/reagent_containers/spray/attack_self(var/mob/user) //Now done via alt-click instead
|
||||
/obj/item/reagent_containers/spray/attack_self(mob/user) //Now done via alt-click instead
|
||||
if(!max_transfer_amount)
|
||||
return
|
||||
amount_per_transfer_from_this = next_in_list(amount_per_transfer_from_this, possible_transfer_amounts)
|
||||
@@ -137,7 +137,10 @@
|
||||
if(Adjacent(user))
|
||||
. += "The safety is [safety ? "on" : "off"]."
|
||||
|
||||
/obj/item/reagent_containers/spray/pepper/attack_self(var/mob/user)
|
||||
/obj/item/reagent_containers/spray/pepper/attack_self(mob/user)
|
||||
. = ..(user)
|
||||
if(.)
|
||||
return TRUE
|
||||
safety = !safety
|
||||
balloon_alert(user, "safety [safety ? "on" : "off"].")
|
||||
|
||||
|
||||
@@ -64,7 +64,10 @@
|
||||
..()
|
||||
update_icon()
|
||||
|
||||
/obj/item/reagent_containers/syringe/attack_self(mob/user as mob)
|
||||
/obj/item/reagent_containers/syringe/attack_self(mob/user)
|
||||
. = ..(user)
|
||||
if(.)
|
||||
return TRUE
|
||||
switch(mode)
|
||||
if(SYRINGE_CAPPED)
|
||||
mode = SYRINGE_DRAW
|
||||
|
||||
Reference in New Issue
Block a user