LeviLamina
Loading...
Searching...
No Matches
CreativeItemRegistry.h
1#pragma once
2
3#include "mc/_HeaderOutputPredefine.h"
4
5// auto generated inclusion list
6#include "mc/deps/core/utility/EnableNonOwnerReferences.h"
7#include "mc/platform/brstd/flat_map.h"
8#include "mc/platform/brstd/function_ref.h"
9#include "mc/world/inventory/network/TypedServerNetId.h"
10#include "mc/world/item/CreativeItemCategory.h"
11
12// auto generated forward declare list
13// clang-format off
14class BlockPalette;
19class HashedString;
20class ItemInstance;
22// clang-format on
23
25public:
26 // member variables
27 // NOLINTBEGIN
28 ::ll::TypedStorage<8, 24, ::std::vector<::CreativeItemEntry>> mCreativeItems;
29 ::ll::TypedStorage<8, 24, ::std::vector<::CreativeGroupInfo>> mCreativeGroups;
30 ::ll::TypedStorage<8, 64, ::std::unordered_map<::CreativeItemCategory, ::CreativeItemGroupCategory>>
31 mCreativeGroupCategories;
32 ::ll::TypedStorage<8, 64, ::std::unordered_map<::CreativeItemNetId, uint64>> mCreativeNetIdIndex;
33 // NOLINTEND
34
35public:
36 // virtual functions
37 // NOLINTBEGIN
38 virtual ~CreativeItemRegistry() /*override*/ = default;
39 // NOLINTEND
40
41public:
42 // member functions
43 // NOLINTBEGIN
44 MCAPI ::brstd::flat_map<
45 ::CreativeItemCategory,
46 ::gsl::not_null<::CreativeItemGroupCategory*>,
47 ::std::less<::CreativeItemCategory>,
48 ::std::vector<::CreativeItemCategory>,
49 ::std::vector<::gsl::not_null<::CreativeItemGroupCategory*>>>
50 createCategories();
51
52 MCAPI void forEachCreativeItemInstance(::brstd::function_ref<bool(::ItemInstance const&)> func) const;
53
54 MCAPI_C ::CreativeItemGroupCategory* getCreativeCategory(::CreativeItemCategory category);
55
56 MCAPI_C void initializeFromCreativeContentPacket(
57 ::CreativeContentPacket const& creativeContentPacket,
58 ::BlockPalette const& blockPalette
59 );
60
61 MCAPI ::CreativeItemGroupCategory* newCreativeCategory(::std::string const& name, ::CreativeItemCategory category);
62
63 MCAPI ::CreativeGroupInfo*
64 newCreativeGroup(::CreativeItemCategory category, ::HashedString const& name, ::ItemInstance const& icon);
65
66 MCAPI void updateNetIdMap();
67 // NOLINTEND
68
69public:
70 // vftables
71 // NOLINTBEGIN
72 MCNAPI static void** $vftable();
73 // NOLINTEND
74};
Definition EnableNonOwnerReferences.h:7
Definition BlockPalette.h:19
Definition CreativeContentPacket.h:22
Definition CreativeGroupInfo.h:17
Definition CreativeItemEntry.h:16
Definition CreativeItemGroupCategory.h:17
Definition CreativeItemRegistry.h:24
static MCAPI void ** $vftable()
Definition HashedString.h:5
Definition ItemInstance.h:15
Definition function_ref.h:60
Definition CreativeItemNetIdTag.h:5