Gripper attackby fixes (#13571)

This cannot go wrong, can it?
This commit is contained in:
mikomyazaki
2022-04-20 22:15:15 +02:00
committed by GitHub
parent d8497aa4cb
commit e59589ec8a
184 changed files with 975 additions and 894 deletions
+3 -3
View File
@@ -98,15 +98,15 @@
if(istype(W, /obj/item/reagent_containers/food/snacks))
var/obj/item/reagent_containers/food/snacks/dipped = W
dipped.attempt_apply_coating(src, user)
return
return TRUE
if(!(W.flags & NOBLUDGEON) && (user.a_intent == I_HURT) && fragile && (W.force > fragile))
if(do_after(user, 10))
if(!QDELETED(src))
visible_message(SPAN_WARNING("[user] smashes [src] with \a [W]!"))
user.do_attack_animation(src)
shatter(W, user)
return
..()
return TRUE
return ..()
/obj/item/reagent_containers/attack(mob/M, mob/user, def_zone)
if(can_operate(M) && do_surgery(M, user, src))
@@ -515,16 +515,16 @@ If you add a drink with no empty icon sprite, ensure it is flagged as NO_EMPTY_I
if(istype(W, /obj/item/reagent_containers/food/drinks/flask/flask_cup))
if(cup)
to_chat(user, SPAN_WARNING("\The [src] already has a cap."))
return
return TRUE
if(W.reagents.total_volume + reagents.total_volume > volume)
to_chat(user, SPAN_WARNING("There's too much fluid in both the cap and the flask!"))
return
return TRUE
to_chat(user, SPAN_NOTICE("You put the cap onto \the [src]."))
user.drop_from_inventory(W, src)
cup = W
cup.reagents.trans_to_holder(reagents, cup.reagents.total_volume)
update_icon()
return
return TRUE
return ..()
/obj/item/reagent_containers/food/drinks/flask/vacuumflask/update_icon()
@@ -749,12 +749,12 @@
if(!(clr in list("blue","green","mime","orange","purple","rainbow","red","yellow")))
to_chat(usr, SPAN_NOTICE("The egg refuses to take on this color!"))
return
return TRUE
to_chat(usr, SPAN_NOTICE("You color \the [src] [clr]"))
icon_state = "egg-[clr]"
else
..()
return TRUE
return ..()
/obj/item/reagent_containers/food/snacks/egg
var/amount_grown = 0
@@ -1737,7 +1737,7 @@
reagent_data = list(/decl/reagent/nutriment = list("peppermint" = 2, "salad" = 4, "hot stew" = 2))
reagents_to_add = list(/decl/reagent/nutriment = 8, /decl/reagent/water = 5, /decl/reagent/drink/dynjuice =2)
/obj/item/reagent_containers/food/snacks/soup/brudet
/obj/item/reagent_containers/food/snacks/soup/brudet
name = "morozian brudet"
desc = "The most popular dish from the Dominian Empire, this stew is a staple of Imperial cuisine."
icon_state = "brudet"
@@ -2243,7 +2243,7 @@
filling_color = "#BB6A54"
reagents_to_add = list(/decl/reagent/nutriment = 2)
reagent_data = list(/decl/reagent/nutriment = list("bread" = 2))
bitesize = 2
bitesize = 2
/obj/item/reagent_containers/food/snacks/mint
name = "mint"
@@ -5410,7 +5410,7 @@
reagents_to_add = list(/decl/reagent/nutriment = 1, /decl/reagent/nutriment/protein = 1, /decl/reagent/blood = 6, /decl/reagent/nutriment/coco = 3)
reagent_data = list(/decl/reagent/nutriment = list("iron" = 3))
bitesize = 6
/obj/item/reagent_containers/food/snacks/phoroncandy
name = "phoron rock candy"
desc = "Rock candy popular in Flagsdale. Actually contains phoron."
@@ -165,7 +165,7 @@
to_chat(user, SPAN_NOTICE("Using \the [W], you unsecure the autoinjector's lid.")) // it locks shut after being secured
flags |= OPENCONTAINER
update_icon()
return
return TRUE
. = ..()
/obj/item/reagent_containers/hypospray/autoinjector/update_icon()
@@ -104,7 +104,7 @@
if(is_open_container())
to_chat(user,"<span class='notice'>You must secure the reagents inside \the [src] before using it!</span>")
return FALSE
else
inject(M, user, M.Adjacent(user))
. = ..()
@@ -127,7 +127,7 @@
to_chat(user,"<span class='notice'>Using \the [W], you unsecure the inhaler's lid.</span>") // it locks shut after being secured
flags |= OPENCONTAINER
update_icon()
return
return TRUE
. = ..()
/obj/item/reagent_containers/inhaler/update_icon()