LeviLamina
Loading...
Searching...
No Matches
EditorMinimapFacet.h
1#pragma once
2
3#include "mc/_HeaderOutputPredefine.h"
4
5// auto generated inclusion list
6#include "mc/client/gui/oreui/binding/FacetBase_DEPRECATED.h"
7#include "mc/common/editor/MinimapMarkerType.h"
8#include "mc/common/editor/MinimapTrackingMode.h"
9#include "mc/deps/core/math/Color.h"
10#include "mc/deps/core/math/Vec3.h"
11#include "mc/deps/core/utility/pub_sub/Subscription.h"
12
13// auto generated forward declare list
14// clang-format off
15namespace Editor { class ServiceProviderCollection; }
16namespace Editor::Services { class EditorMinimapServiceProvider; }
17namespace mce { class UUID; }
18// clang-format on
19
20namespace OreUI {
21
22class EditorMinimapFacet : public ::OreUI::FacetBase_DEPRECATED<::OreUI::EditorMinimapFacet> {
23public:
24 // EditorMinimapFacet inner types declare
25 // clang-format off
27 struct MapDimensions;
28 struct MinimapData;
29 struct MinimapHoverInfo;
30 // clang-format on
31
32 // EditorMinimapFacet inner types define
34 public:
35 // member variables
36 // NOLINTBEGIN
37 ::ll::TypedStorage<4, 4, ::Editor::Services::MinimapMarkerType> mType;
38 ::ll::TypedStorage<8, 32, ::std::string> mIconIdentifier;
39 ::ll::TypedStorage<4, 12, ::Vec3> mPosition;
40 ::ll::TypedStorage<4, 4, float> mRotation;
41 ::ll::TypedStorage<4, 16, ::mce::Color> mColor;
42 ::ll::TypedStorage<8, 32, ::std::string> mLabel;
43 ::ll::TypedStorage<8, 32, ::std::string> mTooltip;
44 ::ll::TypedStorage<1, 1, bool> mClickable;
45 // NOLINTEND
46
47 public:
48 // static variables
49 // NOLINTBEGIN
50 MCAPI static ::std::add_lvalue_reference_t<char const[24]> NAME();
51 // NOLINTEND
52 };
53
54 struct MapDimensions {
55 public:
56 // member variables
57 // NOLINTBEGIN
58 ::ll::TypedStorage<4, 4, int> mWidth;
59 ::ll::TypedStorage<4, 4, int> mHeight;
60 // NOLINTEND
61
62 public:
63 // static variables
64 // NOLINTBEGIN
65 MCAPI static ::std::add_lvalue_reference_t<char const[20]> NAME();
66 // NOLINTEND
67 };
68
69 struct MinimapData {
70 public:
71 // member variables
72 // NOLINTBEGIN
73 ::ll::TypedStorage<8, 32, ::std::string> mMapImage;
74 ::ll::TypedStorage<4, 8, ::OreUI::EditorMinimapFacet::MapDimensions> mDimensions;
75 ::ll::TypedStorage<4, 4, ::Editor::Services::MinimapTrackingMode> mTrackingMode;
76 ::ll::TypedStorage<4, 4, float> mViewCenterX;
77 ::ll::TypedStorage<4, 4, float> mViewCenterZ;
78 ::ll::TypedStorage<1, 1, bool> mIsMeMarkerOnMap;
79 // NOLINTEND
80
81 public:
82 // static variables
83 // NOLINTBEGIN
84 MCAPI static ::std::add_lvalue_reference_t<char const[18]> NAME();
85 // NOLINTEND
86 };
87
88 struct MinimapHoverInfo {
89 public:
90 // member variables
91 // NOLINTBEGIN
92 ::ll::TypedStorage<4, 12, ::Vec3> mWorldPosition;
93 ::ll::TypedStorage<8, 32, ::std::string> mBiomeName;
94 ::ll::TypedStorage<8, 32, ::std::string> mBlockName;
95 ::ll::TypedStorage<1, 1, bool> mValid;
96 // NOLINTEND
97
98 public:
99 // static variables
100 // NOLINTBEGIN
101 MCAPI static ::std::add_lvalue_reference_t<char const[23]> NAME();
102 // NOLINTEND
103 };
104
105public:
106 // member variables
107 // NOLINTBEGIN
108 ::ll::TypedStorage<1, 1, bool> mIsDirty;
109 ::ll::TypedStorage<8, 8, ::Editor::Services::EditorMinimapServiceProvider*> mMinimapService;
110 ::ll::TypedStorage<8, 8, ::Editor::ServiceProviderCollection*> mServices;
111 ::ll::TypedStorage<8, 64, ::std::unordered_map<::std::string, ::OreUI::EditorMinimapFacet::MinimapData>> mMinimaps;
112 ::ll::TypedStorage<
113 8,
114 64,
115 ::std::unordered_map<::std::string, ::std::vector<::OreUI::EditorMinimapFacet::MinimapOreUIMarkerData>>>
116 mMarkers;
117 ::ll::TypedStorage<8, 24, ::std::vector<::OreUI::EditorMinimapFacet::MinimapOreUIMarkerData>> mGlobalMarkers;
118 ::ll::TypedStorage<8, 64, ::std::unordered_map<::std::string, ::OreUI::EditorMinimapFacet::MinimapData>>
119 mMinimapsSnapshot;
120 ::ll::TypedStorage<
121 8,
122 64,
123 ::std::unordered_map<::std::string, ::std::vector<::OreUI::EditorMinimapFacet::MinimapOreUIMarkerData>>>
124 mMarkersSnapshot;
125 ::ll::TypedStorage<8, 24, ::std::vector<::OreUI::EditorMinimapFacet::MinimapOreUIMarkerData>>
126 mGlobalMarkersSnapshot;
127 ::ll::TypedStorage<8, 64, ::std::unordered_set<::std::string>> mVisibleMinimapUIs;
128 ::ll::TypedStorage<8, 16, ::Bedrock::PubSub::Subscription> mMinimapDataChangedSub;
129 ::ll::TypedStorage<8, 16, ::Bedrock::PubSub::Subscription> mMarkersChangedSub;
130 ::ll::TypedStorage<8, 16, ::Bedrock::PubSub::Subscription> mMeMarkerChangedSub;
131 // NOLINTEND
132
133public:
134 // prevent constructor by default
135 EditorMinimapFacet();
136
137public:
138 // virtual functions
139 // NOLINTBEGIN
140 virtual ~EditorMinimapFacet() /*override*/ = default;
141
142 virtual bool update() /*override*/;
143 // NOLINTEND
144
145public:
146 // member functions
147 // NOLINTBEGIN
148 MCAPI explicit EditorMinimapFacet(::Editor::ServiceProviderCollection* services);
149
150 MCAPI void _handleMarkersChanged(::mce::UUID const& minimapId);
151
152 MCAPI void _handleMeMarkerChanged();
153
154 MCAPI void _handleMinimapDataChanged(::mce::UUID const& minimapId);
155
156 MCAPI ::std::vector<::OreUI::EditorMinimapFacet::MinimapOreUIMarkerData> const& getGlobalMarkers();
157
158 MCFOLD ::std::
159 unordered_map<::std::string, ::std::vector<::OreUI::EditorMinimapFacet::MinimapOreUIMarkerData>> const&
160 getMarkers();
161
162 MCFOLD ::std::unordered_map<::std::string, ::OreUI::EditorMinimapFacet::MinimapData> const& getMinimaps();
163
164 MCAPI ::OreUI::EditorMinimapFacet::MinimapHoverInfo
165 queryMinimapPosition(::std::string const& minimapId, float worldX, float worldZ);
166
167 MCAPI void registerMinimapUI(::std::string const& mapId);
168
169 MCAPI void unregisterMinimapUI(::std::string const& mapId);
170 // NOLINTEND
171
172public:
173 // static variables
174 // NOLINTBEGIN
175 MCAPI static ::std::add_lvalue_reference_t<char const[]> NAME();
176 // NOLINTEND
177
178public:
179 // constructor thunks
180 // NOLINTBEGIN
181 MCAPI void* $ctor(::Editor::ServiceProviderCollection* services);
182 // NOLINTEND
183
184public:
185 // virtual function thunks
186 // NOLINTBEGIN
187 MCAPI bool $update();
188 // NOLINTEND
189};
190
191} // namespace OreUI
Definition ServiceProviderCollection.h:7
Definition EditorMinimapServiceProvider.h:28
Definition EditorMinimapFacet.h:7
Definition UUID.h:8
Definition EditorMinimapFacet.h:20
Definition EditorMinimapFacet.h:24
Definition EditorMinimapFacet.h:22
Definition EditorMinimapFacet.h:18