Cuberite
A lightweight, fast and extensible game server for Minecraft
|
Go to the source code of this file.
Classes | |
struct | BiomeHasher |
Hash for EMCSBiome, so that it can be used in std::unordered_map etc. More... | |
Functions | |
AString | BiomeToString (int a_Biome) |
Translates biome enum into biome string. More... | |
int | GetSnowStartHeight (EMCSBiome a_Biome) |
Returns the height when a biome when a biome starts snowing. More... | |
bool | IsBiomeCold (EMCSBiome a_Biome) |
Returns true if the biome is cold (has snow and snowfall at higher elevations but not at regular heights). More... | |
bool | IsBiomeNoDownfall (EMCSBiome a_Biome) |
Returns true if the biome has no downfall - deserts and savannas. More... | |
bool | IsBiomeOcean (int a_Biome) |
Returns true if the biome is an ocean biome. More... | |
bool | IsBiomeVeryCold (EMCSBiome a_Biome) |
Returns true if the biome is very cold (has snow on ground everywhere, turns top water to ice, has snowfall instead of rain everywhere). More... | |
EMCSBiome | StringToBiome (const AString &a_BiomeString) |
Translates a biome string to biome enum. More... | |
enum EMCSBiome |
Biome IDs The first batch corresponds to the clientside biomes, used by MineCraft.
BiomeIDs over 255 are used by Cuberite internally and are translated to MC biomes before sending them to client
Definition at line 21 of file BiomeDef.h.
AString BiomeToString | ( | int | a_Biome | ) |
Translates biome enum into biome string.
Returns empty string on failure (unknown biome).
Definition at line 124 of file BiomeDef.cpp.
int GetSnowStartHeight | ( | EMCSBiome | a_Biome | ) |
Returns the height when a biome when a biome starts snowing.
Definition at line 226 of file BiomeDef.cpp.
bool IsBiomeCold | ( | EMCSBiome | a_Biome | ) |
Returns true if the biome is cold (has snow and snowfall at higher elevations but not at regular heights).
Doesn't report Very Cold biomes, use IsBiomeVeryCold() for those.
Definition at line 194 of file BiomeDef.cpp.
bool IsBiomeNoDownfall | ( | EMCSBiome | a_Biome | ) |
Returns true if the biome has no downfall - deserts and savannas.
Definition at line 140 of file BiomeDef.cpp.
|
inline |
Returns true if the biome is an ocean biome.
Definition at line 139 of file BiomeDef.h.
bool IsBiomeVeryCold | ( | EMCSBiome | a_Biome | ) |
Returns true if the biome is very cold (has snow on ground everywhere, turns top water to ice, has snowfall instead of rain everywhere).
Doesn't report mildly cold biomes (where it snows above certain elevation), use IsBiomeCold() for those.
Definition at line 167 of file BiomeDef.cpp.
Translates a biome string to biome enum.
Takes either a number or a biome alias (built-in). Returns biInvalidBiome on failure.
Definition at line 92 of file BiomeDef.cpp.