Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Prevent creation of 0 gold Letters of Credit
Forums: https://forums.dfworkshop.net/viewtopic.php?t=6299 This can be verified to be correct by first splitting the amount <= loc.value case in two ``` } else if (amount < loc.value) { loc.value -= amount; amount = 0; } else if (amount == loc.value) { loc.value -= amount; amount = 0; items.RemoveItem(loc); } else { amount -= loc.value; items.RemoveItem(loc); } ``` then with some refactos to verify than the "equal" case can be merged into the default one
- Loading branch information