diff options
author | draknyte1 <draknyte1@hotmail.com> | 2017-02-07 14:16:52 +1000 |
---|---|---|
committer | draknyte1 <draknyte1@hotmail.com> | 2017-02-07 14:16:52 +1000 |
commit | 018fc6e51683545fbdb4c0d76d80d6db3a982fbb (patch) | |
tree | 9bb8d88435b6ec689c743eaba15123ee3b3e4598 /src/Java/gtPlusPlus/core/util/math | |
parent | 2a688e006c07c1240966c2829906a1752031153c (diff) | |
download | GT5-Unofficial-018fc6e51683545fbdb4c0d76d80d6db3a982fbb.tar.gz GT5-Unofficial-018fc6e51683545fbdb4c0d76d80d6db3a982fbb.tar.bz2 GT5-Unofficial-018fc6e51683545fbdb4c0d76d80d6db3a982fbb.zip |
+ Added a returnLargestNumber function to MathUtils.java
+ Wrote up some really bad version parsing code, will replace with a Regex function later.
% Changed Growthcraft FishTrap handling to support newer versions.
Diffstat (limited to 'src/Java/gtPlusPlus/core/util/math')
-rw-r--r-- | src/Java/gtPlusPlus/core/util/math/MathUtils.java | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/src/Java/gtPlusPlus/core/util/math/MathUtils.java b/src/Java/gtPlusPlus/core/util/math/MathUtils.java index c864df491c..a7cb916d0d 100644 --- a/src/Java/gtPlusPlus/core/util/math/MathUtils.java +++ b/src/Java/gtPlusPlus/core/util/math/MathUtils.java @@ -266,5 +266,18 @@ public class MathUtils { } return Utils.rgbtoHexValue(RGBA[0], RGBA[1], RGBA[2]); } + + + public final static int returnLargestNumber(int a, int b){ + if (a > b){ + return a; + } + else if (a == b){ + return a; + } + else { + return b; + } + } } |