LeviLamina
Loading...
Searching...
No Matches
Potion.h
1#pragma once
2
3#include "mc/_HeaderOutputPredefine.h"
4
5// auto generated forward declare list
6// clang-format off
8class Experiments;
10class Player;
11namespace Bedrock::Safety { class RedactableString; }
12// clang-format on
13
14class Potion {
15public:
16 // Potion inner types define
17 enum class PotionType : int {
18 Undefined = -1,
19 Regular = 0,
20 Splash = 1,
21 Lingering = 2,
22 };
23
24 enum class PotionVariant : int {
25 Moveslow = 0,
26 Movespeed = 1,
27 Digslow = 2,
28 Digspeed = 3,
29 Damageboost = 4,
30 Heal = 5,
31 Harm = 6,
32 Jump = 7,
33 Confusion = 8,
34 Regen = 9,
35 Resistance = 10,
36 Fireresistance = 11,
37 Waterbreath = 12,
38 Invisibility = 13,
39 Blindness = 14,
40 Nightvision = 15,
41 Hunger = 16,
42 Weakness = 17,
43 Poison = 18,
44 Wither = 19,
45 Healthboost = 20,
46 Absorption = 21,
47 Saturation = 22,
48 Levitation = 23,
49 Turtlemaster = 24,
50 Slowfall = 25,
51 Windcharged = 26,
52 Weaving = 27,
53 Oozing = 28,
54 Infested = 29,
55 Base = 30,
56 };
57
58public:
59 // member variables
60 // NOLINTBEGIN
61 ::ll::TypedStorage<4, 4, int> mId;
62 ::ll::TypedStorage<8, 32, ::std::string> mNameId;
63 ::ll::TypedStorage<8, 32, ::std::string> mPrefix;
64 ::ll::TypedStorage<8, 24, ::std::vector<::MobEffectInstance>> mEffects;
65 ::ll::TypedStorage<8, 24, ::std::vector<::std::string>> mDescriptionIds;
66 ::ll::TypedStorage<4, 4, ::Potion::PotionVariant> mVar;
67 // NOLINTEND
68
69public:
70 // prevent constructor by default
71 Potion();
72
73public:
74 // member functions
75 // NOLINTBEGIN
76 MCNAPI explicit Potion(::std::string_view nameId);
77
78 MCNAPI Potion(
79 ::std::string_view nameId,
80 ::std::string_view descriptionID,
81 ::MobEffectInstance const& mobEffect,
82 ::Potion::PotionVariant var
83 );
84
85 MCNAPI Potion(
86 ::std::string_view nameId,
87 ::std::vector<::std::string> descriptionIDs,
88 ::std::vector<::MobEffectInstance> mobEffects,
89 ::Potion::PotionVariant var
90 );
91
92 MCNAPI ::std::string _getDescriptionIdCombiningStrings(::Potion::PotionType potiontype) const;
93
94 MCNAPI ::std::string _getDescriptionIdSingleString(::Potion::PotionType potionType) const;
95
98 ::Potion::PotionType potionType,
99 ::Potion::PotionVariant potionVariant,
100 ::Player const& player,
101 float timeMod
102 ) const;
103
104 MCNAPI ::std::string getDescriptionId(::Potion::PotionType potionType) const;
105
106 MCNAPI ::std::string getPotencyDescription(::Potion::PotionType potionType, float timeMod) const;
107
108 MCNAPI ~Potion();
109 // NOLINTEND
110
111public:
112 // static functions
113 // NOLINTBEGIN
114 MCNAPI static void addPotion(::std::shared_ptr<::Potion const> potion);
115
116 MCNAPI static void appendMobEffectText(
118 ::Potion::PotionVariant potionVariant,
119 uint mobEffectId,
120 int amplifier,
121 ::Player const& player
122 );
123
124 MCNAPI static ::std::string
125 effectDurationToString(::Potion::PotionType potionType, float timeMod, ::MobEffectInstance const& effect);
126
127 MCNAPI static ::std::string effectPotencyToString(::MobEffectInstance const& effect);
128
129 MCNAPI static ::std::string getBasePotion(::Potion::PotionType type);
130
131 MCNAPI static ::std::string getPotencyDescription(
132 ::Potion::PotionType potionType,
133 float timeMod,
134 ::std::string_view descID,
135 ::MobEffectInstance const& effect
136 );
137
138 MCNAPI static ::std::shared_ptr<::Potion const> getPotion(::std::string_view potionNameId);
139
140 MCNAPI static void initPotions(::BaseGameVersion const& baseGameVersion, ::Experiments const& experiments);
141 // NOLINTEND
142
143public:
144 // static variables
145 // NOLINTBEGIN
146 MCNAPI static ::std::shared_ptr<::Potion const> const& Awkward();
147
148 MCNAPI static ::std::shared_ptr<::Potion const> const& FireResistance();
149
150 MCNAPI static ::std::shared_ptr<::Potion const> const& Harming();
151
152 MCNAPI static ::std::shared_ptr<::Potion const> const& Healing();
153
154 MCNAPI static ::std::shared_ptr<::Potion const> const& Infested();
155
156 MCNAPI static ::std::shared_ptr<::Potion const> const& Invisibility();
157
158 MCNAPI static ::std::shared_ptr<::Potion const> const& Leaping();
159
160 MCNAPI static ::std::shared_ptr<::Potion const> const& LongFireResistance();
161
162 MCNAPI static ::std::shared_ptr<::Potion const> const& LongInvisibility();
163
164 MCNAPI static ::std::shared_ptr<::Potion const> const& LongLeaping();
165
166 MCNAPI static ::std::shared_ptr<::Potion const> const& LongMundane();
167
168 MCNAPI static ::std::shared_ptr<::Potion const> const& LongNightvision();
169
170 MCNAPI static ::std::shared_ptr<::Potion const> const& LongPoison();
171
172 MCNAPI static ::std::shared_ptr<::Potion const> const& LongRegeneration();
173
174 MCNAPI static ::std::shared_ptr<::Potion const> const& LongSlowFalling();
175
176 MCNAPI static ::std::shared_ptr<::Potion const> const& LongSlowness();
177
178 MCNAPI static ::std::shared_ptr<::Potion const> const& LongStrength();
179
180 MCNAPI static ::std::shared_ptr<::Potion const> const& LongSwiftness();
181
182 MCNAPI static ::std::shared_ptr<::Potion const> const& LongTurtleMaster();
183
184 MCNAPI static ::std::shared_ptr<::Potion const> const& LongWaterBreathing();
185
186 MCNAPI static ::std::shared_ptr<::Potion const> const& LongWeakness();
187
188 MCNAPI static ::std::shared_ptr<::Potion const> const& Mundane();
189
190 MCNAPI static ::std::shared_ptr<::Potion const> const& Nightvision();
191
192 MCNAPI static ::std::shared_ptr<::Potion const> const& Oozing();
193
194 MCNAPI static ::std::shared_ptr<::Potion const> const& Poison();
195
196 MCNAPI static ::std::shared_ptr<::Potion const> const& Regeneration();
197
198 MCNAPI static ::std::shared_ptr<::Potion const> const& SlowFalling();
199
200 MCNAPI static ::std::shared_ptr<::Potion const> const& Slowness();
201
202 MCNAPI static ::std::shared_ptr<::Potion const> const& Strength();
203
204 MCNAPI static ::std::shared_ptr<::Potion const> const& StrongHarming();
205
206 MCNAPI static ::std::shared_ptr<::Potion const> const& StrongHealing();
207
208 MCNAPI static ::std::shared_ptr<::Potion const> const& StrongLeaping();
209
210 MCNAPI static ::std::shared_ptr<::Potion const> const& StrongPoison();
211
212 MCNAPI static ::std::shared_ptr<::Potion const> const& StrongRegeneration();
213
214 MCNAPI static ::std::shared_ptr<::Potion const> const& StrongSlowness();
215
216 MCNAPI static ::std::shared_ptr<::Potion const> const& StrongStrength();
217
218 MCNAPI static ::std::shared_ptr<::Potion const> const& StrongSwiftness();
219
220 MCNAPI static ::std::shared_ptr<::Potion const> const& StrongTurtleMaster();
221
222 MCNAPI static ::std::shared_ptr<::Potion const> const& Swiftness();
223
224 MCNAPI static ::std::shared_ptr<::Potion const> const& Thick();
225
226 MCNAPI static ::std::shared_ptr<::Potion const> const& TurtleMaster();
227
228 MCNAPI static ::std::shared_ptr<::Potion const> const& Water();
229
230 MCNAPI static ::std::shared_ptr<::Potion const> const& WaterBreathing();
231
232 MCNAPI static ::std::shared_ptr<::Potion const> const& Weakness();
233
234 MCNAPI static ::std::shared_ptr<::Potion const> const& Weaving();
235
236 MCNAPI static ::std::shared_ptr<::Potion const> const& WindCharged();
237
238 MCNAPI static ::std::shared_ptr<::Potion const> const& Wither();
239
240 MCNAPI static int& mLastId();
241
242 MCNAPI static ::std::add_lvalue_reference_t<::std::shared_ptr<::Potion const>[]> mPotionsById();
243
244 MCNAPI static ::std::unordered_map<::std::string, int>& mPotionsByName();
245 // NOLINTEND
246
247public:
248 // constructor thunks
249 // NOLINTBEGIN
250 MCNAPI void* $ctor(::std::string_view nameId);
251
252 MCNAPI void* $ctor(
253 ::std::string_view nameId,
254 ::std::string_view descriptionID,
255 ::MobEffectInstance const& mobEffect,
256 ::Potion::PotionVariant var
257 );
258
259 MCNAPI void* $ctor(
260 ::std::string_view nameId,
261 ::std::vector<::std::string> descriptionIDs,
262 ::std::vector<::MobEffectInstance> mobEffects,
263 ::Potion::PotionVariant var
264 );
265 // NOLINTEND
266
267public:
268 // destructor thunk
269 // NOLINTBEGIN
270 MCNAPI void $dtor();
271 // NOLINTEND
272};
Definition BaseGameVersion.h:8
Definition RedactableString.h:10
Definition Experiments.h:14
Definition MobEffectInstance.h:15
Definition Player.h:119
Definition Potion.h:14
static MCAPI ::std::shared_ptr<::Potion const > const & Leaping()
static MCAPI ::std::shared_ptr<::Potion const > const & StrongPoison()
MCAPI void * $ctor(::std::string_view nameId)
static MCAPI ::std::unordered_map<::std::string, int > & mPotionsByName()
static MCAPI ::std::shared_ptr<::Potion const > const & LongInvisibility()
static MCAPI ::std::shared_ptr<::Potion const > const & LongPoison()
static MCAPI void appendMobEffectText(::Bedrock::Safety::RedactableString &inOutHovertext, ::Potion::PotionVariant potionVariant, uint mobEffectId, int amplifier, ::Player const &player)
static MCAPI ::std::shared_ptr<::Potion const > const & Mundane()
static MCAPI ::std::shared_ptr<::Potion const > const & Oozing()
MCAPI void * $ctor(::std::string_view nameId, ::std::string_view descriptionID, ::MobEffectInstance const &mobEffect, ::Potion::PotionVariant var)
MCAPI::std::string _getDescriptionIdSingleString(::Potion::PotionType potionType) const
static MCAPI ::std::shared_ptr<::Potion const > const & Infested()
static MCAPI ::std::shared_ptr<::Potion const > const & LongMundane()
static MCAPI ::std::add_lvalue_reference_t<::std::shared_ptr<::Potion const >[]> mPotionsById()
MCAPI void * $ctor(::std::string_view nameId, ::std::vector<::std::string > descriptionIDs, ::std::vector<::MobEffectInstance > mobEffects, ::Potion::PotionVariant var)
static MCAPI ::std::shared_ptr<::Potion const > const & Nightvision()
static MCAPI ::std::shared_ptr<::Potion const > const & LongSlowness()
static MCAPI int & mLastId()
static MCAPI ::std::shared_ptr<::Potion const > const & LongSlowFalling()
static MCAPI void addPotion(::std::shared_ptr<::Potion const > potion)
static MCAPI ::std::shared_ptr<::Potion const > const & Harming()
MCAPI void $dtor()
static MCAPI ::std::shared_ptr<::Potion const > const & Wither()
static MCAPI ::std::shared_ptr<::Potion const > getPotion(::std::string_view potionNameId)
static MCAPI ::std::shared_ptr<::Potion const > const & LongWeakness()
static MCAPI ::std::shared_ptr<::Potion const > const & SlowFalling()
MCAPI::std::string _getDescriptionIdCombiningStrings(::Potion::PotionType potiontype) const
MCAPI ~Potion()
static MCAPI ::std::shared_ptr<::Potion const > const & LongWaterBreathing()
MCAPI::std::string getDescriptionId(::Potion::PotionType potionType) const
MCAPI Potion(::std::string_view nameId)
static MCAPI ::std::shared_ptr<::Potion const > const & FireResistance()
static MCAPI ::std::shared_ptr<::Potion const > const & LongLeaping()
static MCAPI ::std::shared_ptr<::Potion const > const & Weaving()
static MCAPI ::std::shared_ptr<::Potion const > const & Weakness()
static MCAPI ::std::shared_ptr<::Potion const > const & LongNightvision()
static MCAPI ::std::shared_ptr<::Potion const > const & TurtleMaster()
static MCAPI ::std::shared_ptr<::Potion const > const & WindCharged()
static MCAPI ::std::shared_ptr<::Potion const > const & Swiftness()
static MCAPI ::std::shared_ptr<::Potion const > const & LongSwiftness()
static MCAPI ::std::shared_ptr<::Potion const > const & Strength()
static MCAPI ::std::shared_ptr<::Potion const > const & LongFireResistance()
static MCAPI ::std::shared_ptr<::Potion const > const & StrongSlowness()
static MCAPI ::std::shared_ptr<::Potion const > const & LongTurtleMaster()
static MCAPI ::std::shared_ptr<::Potion const > const & StrongRegeneration()
static MCAPI ::std::shared_ptr<::Potion const > const & WaterBreathing()
static MCAPI ::std::shared_ptr<::Potion const > const & LongRegeneration()
MCAPI Potion(::std::string_view nameId, ::std::string_view descriptionID, ::MobEffectInstance const &mobEffect, ::Potion::PotionVariant var)
static MCAPI ::std::shared_ptr<::Potion const > const & Regeneration()
static MCAPI ::std::string effectDurationToString(::Potion::PotionType potionType, float timeMod, ::MobEffectInstance const &effect)
static MCAPI ::std::shared_ptr<::Potion const > const & StrongHarming()
static MCAPI ::std::shared_ptr<::Potion const > const & Thick()
static MCAPI ::std::shared_ptr<::Potion const > const & Slowness()
static MCAPI ::std::string getBasePotion(::Potion::PotionType type)
static MCAPI ::std::shared_ptr<::Potion const > const & StrongHealing()
MCAPI Potion(::std::string_view nameId, ::std::vector<::std::string > descriptionIDs, ::std::vector<::MobEffectInstance > mobEffects, ::Potion::PotionVariant var)
MCAPI void appendFormattedPotionText(::Bedrock::Safety::RedactableString &inOutHovertext, ::Potion::PotionType potionType, ::Potion::PotionVariant potionVariant, ::Player const &player, float timeMod) const
static MCAPI ::std::string effectPotencyToString(::MobEffectInstance const &effect)
static MCAPI ::std::string getPotencyDescription(::Potion::PotionType potionType, float timeMod, ::std::string_view descID, ::MobEffectInstance const &effect)
static MCAPI ::std::shared_ptr<::Potion const > const & Invisibility()
static MCAPI void initPotions(::BaseGameVersion const &baseGameVersion, ::Experiments const &experiments)
static MCAPI ::std::shared_ptr<::Potion const > const & StrongSwiftness()
static MCAPI ::std::shared_ptr<::Potion const > const & Poison()
MCAPI::std::string getPotencyDescription(::Potion::PotionType potionType, float timeMod) const
static MCAPI ::std::shared_ptr<::Potion const > const & StrongLeaping()
static MCAPI ::std::shared_ptr<::Potion const > const & StrongTurtleMaster()
static MCAPI ::std::shared_ptr<::Potion const > const & LongStrength()
static MCAPI ::std::shared_ptr<::Potion const > const & Water()
static MCAPI ::std::shared_ptr<::Potion const > const & Healing()
static MCAPI ::std::shared_ptr<::Potion const > const & Awkward()
static MCAPI ::std::shared_ptr<::Potion const > const & StrongStrength()