49 ::ll::TypedStorage<4, 4, int> mWidth;
50 ::ll::TypedStorage<4, 4, int> mHeight;
51 ::ll::TypedStorage<8, 32, ::std::string> mNormalizedResult;
52 ::ll::TypedStorage<8, 32, ::std::string> mWarning;
72 ::ll::TypedStorage<8, 8, ::Item*> mItem;
73 ::ll::TypedStorage<8, 8, ::Block const*> mBlock;
74 ::ll::TypedStorage<8, 24, ::RecipeIngredient> mIngredient;
75 ::ll::TypedStorage<1, 1, char> mC;
79 using TypeList = ::std::vector<::Recipes::Type>;
84 ::ll::TypedStorage<8, 8, ::ResourcePackManager*> mResourcePackManager;
85 ::ll::TypedStorage<8, 8, ::ExternalRecipeStore> mExternalRecipeStore;
86 ::ll::TypedStorage<8, 16, ::std::map<::HashedString, ::std::map<::std::string, ::std::shared_ptr<::Recipe>>>>
88 ::ll::TypedStorage<1, 1, bool> mInitializing;
94 ::ll::TypedStorage<8, 64, ::std::unordered_map<::RecipeNetId, ::Recipe*>> mRecipesByNetId;
98 ::std::unordered_map<uint64, ::std::unordered_map<uint64, ::std::shared_ptr<::std::vector<::ItemInstance>>>>>
100 ::ll::TypedStorage<8, 24, ::std::vector<::gsl::not_null<::Recipe*>>> mUnlockableRecipes;
101 ::ll::TypedStorage<8, 64, ::std::unordered_set<::std::string>> mUniqueUnlockableRecipeIds;
102 ::ll::TypedStorage<8, 64, ::std::unordered_map<int, ::std::unordered_map<int, ::ItemInstance>>> mFurnaceResults;
103 ::ll::TypedStorage<8, 24, ::std::vector<::std::pair<::std::weak_ptr<bool>, ::std::function<void()>>>> mListeners;
104 ::ll::TypedStorage<8, 8, ::Level*> mLevel;
114 MCAPI
explicit Recipes(
::Level* level);
116 MCAPI
void _addFurnaceRecipeResults(
::Recipe const& recipe);
118 MCAPI
void _addItemRecipe(::std::unique_ptr<::Recipe> recipe);
120 MCAPI
void _addMapRecipes();
122 MCAPI
bool _isRecipeValidToAdd(
::Recipe const& recipe);
126 MCAPI
void _loadDataDrivenRecipes(::std::vector<::PackInstance>
const& resourcePacksNewestToOldest);
130 MCAPI ::RecipeIngredient
const _loadIngredientFromJson(
132 ::MolangVersion molangVersion,
137 MCAPI ::RecipeIngredient
const
140 MCAPI
bool _loadSmithingTransform(
142 ::MolangVersion molangVersion,
143 ::std::string
const& recipeId,
144 ::std::vector<::HashedString>
const& tags
147 MCAPI
bool _loadSmithingTrim(
149 ::MolangVersion molangVersion,
150 ::std::string
const& recipeId,
151 ::std::vector<::HashedString>
const& tags
154 MCAPI ::std::optional<::RecipeUnlockingRequirement> _loadUnlockingRequirementFromJson(
156 ::MolangVersion molangVersion,
157 ::std::string
const& recipeId
160 MCAPI
void addDyedItemRecipe(
161 ::std::string recipeId,
171 MCAPI
void addNetMappedRecipe(::RecipeNetId
const& recipeNetId, ::std::unique_ptr<::Recipe> recipe);
173 MCAPI
void addRecipeListener(::std::weak_ptr<bool> lifePtr, ::std::function<
void()> callback);
176 MCAPI
void addShapedRecipe(
177 ::std::string recipeId,
179 ::std::string
const& r0,
180 ::std::vector<::Recipes::Type>
const& types,
181 ::std::vector<::HashedString>
const& tags,
183 ::std::function<::std::unique_ptr<::ShapedRecipe>(
187 ::std::vector<::RecipeIngredient>
const&,
188 ::std::vector<::ItemInstance>
const&,
201 MCAPI
void addShapedRecipe(
202 ::std::string recipeId,
203 ::std::vector<::ItemInstance>
const& result,
204 ::std::vector<::std::string>
const& rows,
205 ::std::vector<::Recipes::Type>
const& types,
206 ::std::vector<::HashedString>
const& tags,
208 ::std::function<::std::unique_ptr<::ShapedRecipe>(
212 ::std::vector<::RecipeIngredient>
const&,
213 ::std::vector<::ItemInstance>
const&,
226 MCAPI
void addShapedRecipe(
227 ::std::string recipeId,
229 ::std::vector<::std::string>
const& rows,
230 ::std::vector<::Recipes::Type>
const& types,
231 ::std::vector<::HashedString>
const& tags,
233 ::std::function<::std::unique_ptr<::ShapedRecipe>(
237 ::std::vector<::RecipeIngredient>
const&,
238 ::std::vector<::ItemInstance>
const&,
251 MCAPI
void addShapedRecipe(
252 ::std::string recipeId,
254 ::std::string
const& r0,
255 ::std::string
const& r1,
256 ::std::vector<::Recipes::Type>
const& types,
257 ::std::vector<::HashedString>
const& tags,
259 ::std::function<::std::unique_ptr<::ShapedRecipe>(
263 ::std::vector<::RecipeIngredient>
const&,
264 ::std::vector<::ItemInstance>
const&,
277 MCAPI
void addShapedRecipe(
278 ::std::string recipeId,
280 ::std::string
const& r0,
281 ::std::string
const& r1,
282 ::std::string
const& r2,
283 ::std::vector<::Recipes::Type>
const& types,
284 ::std::vector<::HashedString>
const& tags,
286 ::std::function<::std::unique_ptr<::ShapedRecipe>(
290 ::std::vector<::RecipeIngredient>
const&,
291 ::std::vector<::ItemInstance>
const&,
304 MCAPI
void addShapelessRecipe(
305 ::std::string recipeId,
307 ::std::vector<::Recipes::Type>
const& types,
308 ::std::vector<::HashedString>
const& tags,
310 ::std::function<::std::unique_ptr<::ShapelessRecipe>(
312 ::std::vector<::RecipeIngredient>
const&,
313 ::std::vector<::ItemInstance>
const&,
324 MCAPI
void addShulkerBoxRecipe(
325 ::std::string& recipeId,
327 ::std::vector<::Recipes::Type>
const& types,
328 ::std::vector<::HashedString>
const& tags,
333 MCAPI
void clearRecipes();
335 MCAPI ::SemVersion extractRecipeFormatVersion(
::Json::Value const& obj);
337 MCAPI ::std::pair<::std::string, ::Json::Value> extractRecipeObjInfo(
::Json::Value const& obj);
342 MCAPI
void forEachRecipeFor(
343 ::std::vector<::std::string>
const& tags,
347 MCAPI
void forEachRecipeFor(
353 MCAPI
void forEachRecipeFor(
355 ::std::vector<::std::string>
const& tags,
362 MCAPI
void forEachRecipeUntil(
368 MCAPI
void forEachRecipeUntil(
370 ::std::vector<::std::string>
const& tags,
379 MCFOLD uint getNumberOfUnlockableRecipes()
const;
381 MCAPI ::Recipe
const* getRecipeByNetId(::RecipeNetId
const& netId)
const;
385 MCFOLD ::std::map<::HashedString, ::std::map<::std::string, ::std::shared_ptr<::Recipe>>>
const&
386 getRecipesAllTags()
const;
395 MCAPI
bool loadRecipe(
396 ::std::pair<::std::string, ::Json::Value>
const& recipeObjInfo,
403 MCAPI
void notifyRecipeListeners();
405 MCAPI
void removeRecipeListener(::std::weak_ptr<bool> lifePtr);
407 MCAPI
void sortRecipesByPriority(::std::vector<::std::reference_wrapper<::Recipe const>>& recipes)
const;
416 MCAPI static ::Recipes::NormalizedRectangularRecipeResults
417 _normalizeRectangularRecipe(::std::vector<::std::string>
const& rows);
423 MCAPI
void* $ctor(
::Level* level);