From 26712fbfb08fbad59d48fed7d7e60a6236383a17 Mon Sep 17 00:00:00 2001 From: Gidgit <63561162+AysheDaArtist@users.noreply.github.com> Date: Sun, 28 Jan 2024 05:22:47 -0700 Subject: [PATCH] Landen ABK fix (#4979) Do not credit me, credit Landen. This completely fixes Advanced brute kits. They function as intended, you get the bonus if you have high Bio, if you have no charges, or not enough charges for a surgery step, you cannot complete it Co-authored-by: CDB <87905328+cdb-is-not-good@users.noreply.github.com> --- .../organs/internal/internal_wounds/_internal_wound.dm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/code/modules/organs/internal/internal_wounds/_internal_wound.dm b/code/modules/organs/internal/internal_wounds/_internal_wound.dm index 4c0c0122f28..8c25c0be0f2 100644 --- a/code/modules/organs/internal/internal_wounds/_internal_wound.dm +++ b/code/modules/organs/internal/internal_wounds/_internal_wound.dm @@ -176,12 +176,12 @@ if(istype(I, /obj/item/stack)) var/obj/item/stack/S = I if(do_after(user, WORKTIME_NORMAL - user_stat_level, parent)) - if(prob(10 + user_stat_level)) + if(prob(10 + user_stat_level)&& S.amount > 0) free_use = TRUE is_treated = TRUE - else + else if(S.amount >= charges_needed) is_treated = S.use(charges_needed) - else if(istype(I)) // check for using items without stacks + else if(istype(I) && !istype(I, /obj/item/stack)) is_treated = TRUE qdel(I) if(is_treated)