LeviLamina
Loading...
Searching...
No Matches
ActiveBundleData.h
1#pragma once
2
3#include "mc/_HeaderOutputPredefine.h"
4
5// auto generated inclusion list
6#include "mc/client/gui/screens/controllers/BundleTooltipLayoutData.h"
7#include "mc/world/containers/SlotData.h"
8
9// auto generated forward declare list
10// clang-format off
12class ItemStackBase;
13// clang-format on
14
15struct ActiveBundleData {
16public:
17 // ActiveBundleData inner types define
18 enum class BundleState : int {
19 Inactive = 0,
20 Active = 1,
21 Hovered = 2,
22 };
23
24 enum class TooltipDirection : int {
25 SouthEast = 0,
26 NorthEast = 1,
27 NorthWest = 2,
28 SouthWest = 3,
29 };
30
31public:
32 // member variables
33 // NOLINTBEGIN
34 ::ll::TypedStorage<1, 1, bool> mMinimizedTooltip;
35 ::ll::TypedStorage<4, 8, ::std::optional<int>> mSelectedCollectionIndex;
36 ::ll::TypedStorage<8, 40, ::SlotData> mSlotData;
37 ::ll::TypedStorage<4, 4, ::ActiveBundleData::BundleState> mBundleState;
38 ::ll::TypedStorage<8, 80, ::std::optional<::BundleTooltipLayoutData>> mCachedBundleTooltipLayoutData;
39 // NOLINTEND
40
41public:
42 // member functions
43 // NOLINTBEGIN
44 MCAPI ActiveBundleData();
45
46 MCAPI ::BundleTooltipLayoutData const& getBundleTooltipLayoutData(
47 ::ItemStackBase const& bundleItem,
48 ::ContainerManagerController& containerManagerController
49 ) const;
50
51 MCAPI ::std::pair<::std::string, int> getCollectionNameAndIndex() const;
52
53 MCAPI int
54 getContainerIndexFromCollectionIndex(::BundleTooltipLayoutData const& tooltipLayoutData, int collectionIndex) const;
55
56 MCAPI int getSelectedItemContainerIndex(::BundleTooltipLayoutData const& tooltipLayoutData) const;
57
58 MCAPI void invalidateBundleTooltipLayoutData();
59
60 MCAPI bool isActive() const;
61
62 MCAPI bool isHovered() const;
63
64 MCAPI void resetData();
65
66 MCAPI void setActive(::std::string const& collectionName, int collectionIndex);
67
68 MCAPI void setHovered(::std::string const& collectionName, int collectionIndex);
69 // NOLINTEND
70
71public:
72 // static functions
73 // NOLINTBEGIN
74 MCAPI static ::BundleTooltipLayoutData _calculateBundleTooltipLayoutData(
75 ::ItemStackBase const& bundleItem,
76 ::ContainerManagerController& containerManagerController
77 );
78 // NOLINTEND
79
80public:
81 // constructor thunks
82 // NOLINTBEGIN
83 MCAPI void* $ctor();
84 // NOLINTEND
85};
Definition ContainerManagerController.h:48
Definition ItemStackBase.h:52
Definition ActiveBundleData.h:5