@Deadshot
Your solution needs to be modified to handle the situation where the resulting $silver & $gold values contain a decimal point number.
eg. 1234 copper => 12.34 silver
You can't have 0.34 of a silver piece so you need remove everything after the decimal point so that 12.34 silver becomes 12 silver.
You have two main methods you can use to do this trunctation action:
1. The JavaScript Math.trunc() function.
(set: $copper to 123456)
(set: $silver to Math.trunc($copper / 100))
(set: $gold to Math.trunc($silver / 100))
$copper copper => $silver silver.
$silver silver => $gold gold.
2. The Harlowe (floor:) macro (if the result of the divide is a positive number)
(set: $copper to 123456)
(set: $silver to (floor: $copper / 100))
(set: $gold to (floor: $silver / 100))
$copper copper => $silver silver.
$silver silver => $gold gold.
note: Neither of the above examples handles the need to reduce:
a. the original $copper amount after some of it has been converted to silver pieces.
b. the calculated $silver amount after some of it has been converted to gold pieces.
eg. 123456 copper pieces after conversion should equal 12 gold 34 silver 56 copper.