diff options
| author | iouter <62897714+iouter@users.noreply.github.com> | 2022-01-07 12:36:06 +0800 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2022-01-07 12:36:06 +0800 |
| commit | 0834d4b8b45a881f36ed5b295ac0fb38df49fa9a (patch) | |
| tree | 6fb4a45cf17dd22748148417bc7bb0efb850cea3 /src/main/java/gtPlusPlus/plugin/agrichem/AlgaeDefinition.java | |
| parent | ea1439a4195c8f77c45625ea2593a232bf19984e (diff) | |
| parent | 9b2e050151ad93170e84321d067d1e9d4ded4ba5 (diff) | |
| download | GT5-Unofficial-0834d4b8b45a881f36ed5b295ac0fb38df49fa9a.tar.gz GT5-Unofficial-0834d4b8b45a881f36ed5b295ac0fb38df49fa9a.tar.bz2 GT5-Unofficial-0834d4b8b45a881f36ed5b295ac0fb38df49fa9a.zip | |
Merge branch 'GTNewHorizons:master' into master
Diffstat (limited to 'src/main/java/gtPlusPlus/plugin/agrichem/AlgaeDefinition.java')
| -rw-r--r-- | src/main/java/gtPlusPlus/plugin/agrichem/AlgaeDefinition.java | 60 |
1 files changed, 60 insertions, 0 deletions
diff --git a/src/main/java/gtPlusPlus/plugin/agrichem/AlgaeDefinition.java b/src/main/java/gtPlusPlus/plugin/agrichem/AlgaeDefinition.java new file mode 100644 index 0000000000..c6e98581ff --- /dev/null +++ b/src/main/java/gtPlusPlus/plugin/agrichem/AlgaeDefinition.java @@ -0,0 +1,60 @@ +package gtPlusPlus.plugin.agrichem; + +public enum AlgaeDefinition { + + /* + * In general, the productivity of freshwater algae is primarily limited by + * the availability of the nutrient phosphate (PO4-3), while that of + * marine algae is limited by nitrate (NO3-) or ammonium (NH4+). + * Some algal species, however, may have unusual nutrient requirements, + * and their productivity may be limited by certain micronutrients, + * such as silica, in the case of diatoms. + */ + + Euglenophyta("Euglenophyta", "Euglenoids", true, false, getRGB(147, 168, 50)), + Chrysophyta("Chrysophyta", "Golden-Brown Algae", true, true, getRGB(186, 146, 0)), + Pyrrophyta("Pyrrophyta", "Fire Algae", true, true, getRGB(250, 118, 2)), + Chlorophyta("Chlorophyta", "Green Algae", true, true, getRGB(99, 181, 62)), + Rhodophyta("Rhodophyta", "Red Algae", false, true, getRGB(153, 5, 22)), + Paeophyta("Paeophyta", "Brown Algae", false, true, getRGB(94, 78, 47)), + Xanthophyta("Xanthophyta", "Yellow-Green Algae", true, false, getRGB(118, 138, 16)); + + public final String mScientificName; + public final String mSimpleName; + public final boolean mSaltWater; + public final boolean mFreshWater; + public final int mColour; + + AlgaeDefinition(String aScientificName, String aSimpleName, boolean aFresh, boolean aSalt, int aColour) { + mScientificName = aScientificName; + mSimpleName = aSimpleName; + mFreshWater = aFresh; + mSaltWater = aSalt; + mColour = aColour; + } + + public static AlgaeDefinition getByIndex(int aIndex) { + switch(aIndex) { + default: + case 0: + return Euglenophyta; + case 1: + return Chrysophyta; + case 2: + return Pyrrophyta; + case 3: + return Chlorophyta; + case 4: + return Rhodophyta; + case 5: + return Paeophyta; + case 6: + return Xanthophyta; + } + } + + private final static int getRGB(int r, int g, int b) { + return AlgaeUtils.rgbtoHexValue(r, g, b); + } + +} |
