From 6bc86d2bd45f88f31b90f6e6e4dbe7a123f3ffb2 Mon Sep 17 00:00:00 2001 From: SyncIt21 <110812394+SyncIt21@users.noreply.github.com> Date: Fri, 1 Aug 2025 13:54:14 +0530 Subject: [PATCH] [NO GBP] Fixes multiplier applied incorrectly in `trans_to()` (#92404) ## About The Pull Request - Fixes #92401 And many other reagent transfer operations who's multiplier is not 1 ## Changelog :cl: fix: reagent transfer amounts with multiplier applied(e.g. cryotubes) have been corrected /:cl: --- code/modules/reagents/chemistry/holder/holder.dm | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/code/modules/reagents/chemistry/holder/holder.dm b/code/modules/reagents/chemistry/holder/holder.dm index 02eb45ad3fb..9d77804bcd9 100644 --- a/code/modules/reagents/chemistry/holder/holder.dm +++ b/code/modules/reagents/chemistry/holder/holder.dm @@ -485,7 +485,6 @@ continue else transfer_amount = reagent.volume * part - transfer_amount *= multiplier if(preserve_data) trans_data = copy_data(reagent) @@ -493,12 +492,12 @@ update_total() target_holder.update_total() continue - transfered_amount = target_holder.add_reagent(reagent.type, transfer_amount, trans_data, chem_temp, reagent.purity, reagent.ph, no_react = TRUE, reagent_added = r_to_send, creation_callback = CALLBACK(src, PROC_REF(_on_transfer_creation), reagent, target_holder)) //we only handle reaction after every reagent has been transferred. + transfered_amount = target_holder.add_reagent(reagent.type, transfer_amount * multiplier, trans_data, chem_temp, reagent.purity, reagent.ph, no_react = TRUE, reagent_added = r_to_send, creation_callback = CALLBACK(src, PROC_REF(_on_transfer_creation), reagent, target_holder)) //we only handle reaction after every reagent has been transferred. if(!transfered_amount) continue total_transfered_amount += transfered_amount - reagent.volume -= transfered_amount + reagent.volume -= transfer_amount transfer_log += "[reagent.type] ([transfered_amount]u, [reagent.purity] purity)" if(!isnull(target_id))