LeviLamina
Loading...
Searching...
No Matches
Biome.h
1#pragma once
2
3#include "mc/_HeaderOutputPredefine.h"
4
5// auto generated inclusion list
6#include "mc/common/BiomeIdType.h"
7#include "mc/deps/core/string/HashedString.h"
8#include "mc/util/WeightedRandomList.h"
9#include "mc/world/level/biome/OceanRuinConfiguration.h"
10#include "mc/world/level/biome/components/BiomeComponentStorage.h"
11#include "mc/world/level/biome/components/vanilla/VanillaBiomeTypes.h"
12
13// auto generated forward declare list
14// clang-format off
15class BlockPos;
16class BlockSource;
17class LevelChunk;
18class MobSpawnerData;
19namespace br::worldgen { struct SpawnerData; }
20namespace mce { class Color; }
21// clang-format on
22
23class Biome {
24public:
25 // Biome inner types define
26 enum class BiomeTempCategory : int {
27 Ocean = 0,
28 Cold = 1,
29 Medium = 2,
30 Warm = 3,
31 };
32
33public:
34 // member variables
35 // NOLINTBEGIN
36 ::ll::TypedStorage<4, 4, float> mTemperature;
37 ::ll::TypedStorage<4, 4, float> mDownfall;
38 ::ll::TypedStorage<4, 4, float> mRedSporeDensity;
39 ::ll::TypedStorage<4, 4, float> mBlueSporeDensity;
40 ::ll::TypedStorage<4, 4, float> mAshDensity;
41 ::ll::TypedStorage<4, 4, float> mWhiteAshDensity;
42 ::ll::TypedStorage<4, 4, float> mSnowAccumulation;
43 ::ll::TypedStorage<4, 4, float> mFoliageSnow;
44 ::ll::TypedStorage<4, 4, float> mMinSnowLevel;
45 ::ll::TypedStorage<4, 4, float> mMaxSnowLevel;
46 ::ll::TypedStorage<4, 4, float> mDepth;
47 ::ll::TypedStorage<4, 4, float> mScale;
48 ::ll::TypedStorage<4, 4, int> mMapWaterColor;
49 ::ll::TypedStorage<4, 4, float const> mMapWaterTransparency;
50 ::ll::TypedStorage<1, 1, bool> mRain;
51 ::ll::TypedStorage<4, 12, ::OceanRuinConfiguration> mOceanRuinConfig;
52 ::ll::TypedStorage<8, 24, ::std::vector<::std::shared_ptr<::MobSpawnerData>>> mMobs;
53 ::ll::TypedStorage<8, 256, ::std::array<::WeightedRandomList<::br::worldgen::SpawnerData>, 8>> mMobsMap;
54 ::ll::TypedStorage<2, 2, ::BiomeIdType const> mId;
55 ::ll::TypedStorage<8, 32, ::BiomeComponentStorage> mBiomeComponentStorage;
56 ::ll::TypedStorage<8, 48, ::HashedString const> mHash;
57 // NOLINTEND
58
59public:
60 // prevent constructor by default
61 Biome();
62
63public:
64 // virtual functions
65 // NOLINTBEGIN
66 // vIndex: 0
67 virtual ~Biome() = default;
68 // NOLINTEND
69
70public:
71 // member functions
72 // NOLINTBEGIN
73 MCAPI Biome(::BiomeIdType id, ::std::string_view name);
74
75 MCAPI ::VanillaBiomeTypes getBiomeType() const;
76
77 MCAPI int getMapFoliageColor() const;
78
79 MCAPI int getMapGrassColor(::BlockPos const& pos) const;
80
81 MCAPI float getTemperature(::BlockSource const& region, ::BlockPos const& pos) const;
82
83 MCAPI ::Biome::BiomeTempCategory getTemperatureCategory() const;
84
85 MCAPI bool isHumid() const;
86
87 MCAPI ::Biome& setMapWaterColor(int color);
88 // NOLINTEND
89
90public:
91 // static functions
92 // NOLINTBEGIN
93 MCAPI static void buildCachedTemperatureNoise(::LevelChunk& chunk);
94
95 MCAPI static ::mce::Color getColorBySamplingSurroundings(
96 ::BlockSource& region,
97 ::BlockPos const& pos,
98 ::std::vector<::BlockPos> const& pattern,
99 ::gsl::not_null<int (*)(::Biome const&, ::BlockPos const&)> const& sampler
100 );
101 // NOLINTEND
102
103public:
104 // static variables
105 // NOLINTBEGIN
106 MCAPI static ::mce::Color const& BIRCH_FOLIAGE_TINT();
107
108 MCAPI static ::mce::Color const& DEFAULT_FOLIAGE_TINT();
109
110 MCAPI static ::mce::Color const& DEFAULT_GRASS_TINT();
111
112 MCAPI static ::mce::Color const& DEFAULT_UNDERWATER_COLOR();
113
114 MCAPI static ::mce::Color const& DEFAULT_WATER_COLOR();
115
116 MCAPI static ::mce::Color const& DEFAULT_WATER_TINT();
117
118 MCAPI static ::mce::Color const& DRY_FOLIAGE_TINT();
119
120 MCAPI static ::mce::Color const& EVERGREEN_FOLIAGE_TINT();
121
122 MCAPI static float const& RAIN_TEMP_THRESHOLD();
123 // NOLINTEND
124
125public:
126 // constructor thunks
127 // NOLINTBEGIN
128 MCAPI void* $ctor(::BiomeIdType id, ::std::string_view name);
129 // NOLINTEND
130
131public:
132 // vftables
133 // NOLINTBEGIN
134 MCNAPI static void** $vftable();
135 // NOLINTEND
136};
Definition Biome.h:23
static MCAPI void ** $vftable()
Definition BlockPos.h:17
Definition BlockSource.h:66
Definition LevelChunk.h:78
Definition MobSpawnerData.h:17
Definition BiomeIdType.h:8