mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-08-22 19:47:22 +01:00
fix pill and patch activate in-hand (#28767)
This commit is contained in:
@@ -16,6 +16,12 @@
|
||||
apply(target, user)
|
||||
return ITEM_INTERACT_COMPLETE
|
||||
|
||||
/obj/item/reagent_containers/patch/activate_self(mob/user)
|
||||
if(..())
|
||||
return FINISH_ATTACK
|
||||
|
||||
apply(user, user)
|
||||
|
||||
/obj/item/reagent_containers/patch/proc/apply(mob/living/carbon/C, mob/user)
|
||||
if(!istype(C))
|
||||
return
|
||||
|
||||
@@ -18,6 +18,12 @@
|
||||
if(!icon_state)
|
||||
icon_state = "pill[rand(1, 20)]"
|
||||
|
||||
/obj/item/reagent_containers/pill/activate_self(mob/user)
|
||||
if(..())
|
||||
return FINISH_ATTACK
|
||||
|
||||
apply(user, user)
|
||||
|
||||
/obj/item/reagent_containers/pill/proc/apply(mob/living/carbon/C, mob/user)
|
||||
if(!istype(C))
|
||||
return FALSE
|
||||
|
||||
@@ -204,6 +204,9 @@
|
||||
pill = player.spawn_obj_in_hand(/obj/item/reagent_containers/pill/salicylic)
|
||||
player.click_on(beaker)
|
||||
TEST_ASSERT_LAST_CHATLOG(player, "You dissolve [pill] in [beaker].")
|
||||
pill = player.spawn_obj_in_hand(/obj/item/reagent_containers/pill/salicylic)
|
||||
player.use_item_in_hand()
|
||||
TEST_ASSERT_LAST_CHATLOG(player, "You swallow [pill].")
|
||||
|
||||
// Patches
|
||||
var/obj/item/reagent_containers/patch/patch = player.spawn_obj_in_hand(/obj/item/reagent_containers/patch/silver_sulf)
|
||||
|
||||
Reference in New Issue
Block a user