LogoExcessive Utilities

KubeJS

KubeJS

The algorithm for how much GP is used by Speed Upgrades is:

stackSize * (122 + 4 * stackSize) / 126.0

While there's a server config option to simply multiply this by a number, you can also use KubeJS to completely rewrite the formula, if you'd ever want to do so.

const $SpeedUpgradeItem = Java.loadClass('dev.aaronhowser.mods.excessive_utilities.item.SpeedUpgradeItem')
$SpeedUpgradeItem.setGpCostCalculator(stackSize => stackSize * 10)

This example makes each Speed Upgrade in the stack simply cost 10 GP before the server config multiplier is applied.