Skip to content

Commit

Permalink
Merge pull request #5341 from Ldip999/double-convert
Browse files Browse the repository at this point in the history
Fixes double convert bug
  • Loading branch information
Tk420634 authored Aug 18, 2024
2 parents 7b42669 + 79d5bd9 commit 1e55bdc
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions code/modules/WVM/wmv_buyer.dm
Original file line number Diff line number Diff line change
Expand Up @@ -441,7 +441,7 @@ GLOBAL_LIST_EMPTY(wasteland_vendor_shop_list)
say("I'll give you absolutely nothing for \the [I]!", just_chat = quiet)
return FALSE
if(!silent)
say("I'll give you [SSeconomy.format_currency(final_price, TRUE, TRUE)] per [I]!", just_chat = quiet)
say("I'll give you [SSeconomy.format_currency(final_price, FALSE, TRUE)] per [I]!", just_chat = quiet) //Uses false for second argument because final_price has already been converted to copper from credits during initial assignment.
return final_price

/obj/machinery/mineral/wasteland_trader/proc/lock_belt(silent)
Expand Down Expand Up @@ -677,8 +677,8 @@ GLOBAL_LIST_EMPTY(wasteland_vendor_shop_list)

/obj/machinery/proc/announce_sale(soldfor, totalcash, obj/item/I)
var/thing = I ? "\the [I]" : "something"
var/currencie = "[SSeconomy.format_currency(soldfor, TRUE, TRUE)]"
var/currencei = "[SSeconomy.format_currency(totalcash, TRUE, TRUE)]"
var/currencie = "[SSeconomy.format_currency(soldfor, FALSE, TRUE)]" //Second argument false because we are already receiving coppers for the proc arguments
var/currencei = "[SSeconomy.format_currency(totalcash, FALSE, TRUE)]"
say("Sold [thing] for [currencie], bringing the total to [currencei]!")

/obj/item/debug_vendorsale
Expand Down

0 comments on commit 1e55bdc

Please sign in to comment.