LeviLamina
Loading...
Searching...
No Matches
ScriptBlockCustomComponentsRegistry.h
1#pragma once
2
3#include "mc/_HeaderOutputPredefine.h"
4
5// auto generated inclusion list
6#include "mc/deps/scripting/runtime/Result.h"
7#include "mc/scripting/modules/minecraft/ScriptCustomComponentRegistry.h"
8#include "mc/scripting/modules/minecraft/events/ScriptBlockCustomComponentEventTypes.h"
9#include "mc/scripting/modules/minecraft/events/metadata/ScriptCustomComponentEventMetadata.h"
10#include "mc/world/events/ScriptDeferredEventListener.h"
11
12// auto generated forward declare list
13// clang-format off
14class Block;
16class BlockLegacy;
17class HashedString;
20namespace BlockEvents { class BlockEntityFallOnEvent; }
21namespace BlockEvents { class BlockPlaceEvent; }
22namespace BlockEvents { class BlockPlayerDestroyEvent; }
23namespace BlockEvents { class BlockPlayerInteractEvent; }
24namespace BlockEvents { class BlockPlayerPlacingEvent; }
25namespace BlockEvents { class BlockQueuedTickEvent; }
26namespace BlockEvents { class BlockRandomTickEvent; }
27namespace BlockEvents { class BlockStepOffEvent; }
28namespace BlockEvents { class BlockStepOnEvent; }
29namespace Json { class Value; }
30namespace ScriptModuleMinecraft { class ScriptBlockCustomComponentInterface; }
31namespace ScriptModuleMinecraft { struct ScriptBlockCustomComponentAlreadyRegisteredError; }
32namespace ScriptModuleMinecraft { struct ScriptBlockCustomComponentReloadNewComponentError; }
33namespace ScriptModuleMinecraft { struct ScriptBlockCustomComponentReloadNewEventError; }
34namespace ScriptModuleMinecraft { struct ScriptBlockCustomComponentReloadVersionError; }
35namespace ScriptModuleMinecraft { struct ScriptCustomComponentInvalidRegistryError; }
36namespace Scripting { class ModuleBindingBuilder; }
37namespace Scripting { class WeakLifetimeScope; }
38namespace Scripting { struct ModuleDescriptor; }
39// clang-format on
40
41namespace ScriptModuleMinecraft {
42
45public:
46 // ScriptBlockCustomComponentsRegistry inner types declare
47 // clang-format off
49 // clang-format on
50
51 // ScriptBlockCustomComponentsRegistry inner types define
53 public:
54 // member variables
55 // NOLINTBEGIN
60 // NOLINTEND
61
62 public:
63 // prevent constructor by default
67
68 public:
69 // member functions
70 // NOLINTBEGIN
71 MCAPI void setClosureData(
74 );
75
77 // NOLINTEND
78
79 public:
80 // destructor thunk
81 // NOLINTBEGIN
82 MCAPI void $dtor();
83 // NOLINTEND
84 };
85
86public:
87 // member variables
88 // NOLINTBEGIN
95 // NOLINTEND
96
97public:
98 // prevent constructor by default
102
103public:
104 // virtual functions
105 // NOLINTBEGIN
106 // vIndex: 8
107 virtual void onPreFlushAfterEvents() /*override*/;
108
109 // vIndex: 5
110 virtual void onFlushBlockCustomComponentAfterEvents(::ScriptDeferredFlushTracker& deferredTracker) /*override*/;
111
112 // vIndex: 9
113 virtual void onPostFlushAfterEvents() /*override*/;
114
115 // vIndex: 2
116 virtual void _onScriptInitializationComplete() /*override*/;
117
118 // vIndex: 1
119 virtual void _onReload() /*override*/;
120
121 // vIndex: 0
122 virtual ~ScriptBlockCustomComponentsRegistry() /*override*/;
123 // NOLINTEND
124
125public:
126 // member functions
127 // NOLINTBEGIN
128 MCAPI explicit ScriptBlockCustomComponentsRegistry(::ScriptDeferredEventCoordinator& deferredEventCoordinator);
129
130 MCAPI void _bindComponentToCereal(
131 ::HashedString const& compName,
133 );
134
135 MCAPI ::Scripting::Result<
136 void,
142 _componentRegistrationValidatorsCommon(
143 ::std::_List_iterator<::std::_List_val<::std::_List_simple_types<::std::pair<
144 ::HashedString const,
146 compIt,
147 ::HashedString const& name,
149 );
150
151 MCAPI ::Scripting::Result<
152 void,
158 _componentReloadRegistrationValidators(
159 ::std::_List_iterator<::std::_List_val<::std::_List_simple_types<::std::pair<
160 ::HashedString const,
162 compIt,
163 ::HashedString const& name,
165 );
166
167 MCAPI void _registerBlockForEventing(
168 ::BlockLegacy& block,
169 ::std::vector<::gsl::not_null<::BlockCustomComponentsComponent*>> const& comps
170 );
171
172 MCAPI void beforeOnPlayerPlace(::BlockEvents::BlockPlayerPlacingEvent& eventData) const;
173
174 MCAPI bool
175 hasSubscriptionFor(::ScriptModuleMinecraft::ScriptBlockCustomComponentEventTypes type, ::Block const& block) const;
176
177 MCAPI void onEntityFallOn(::BlockEvents::BlockEntityFallOnEvent& eventData) const;
178
179 MCAPI void onPlace(::BlockEvents::BlockPlaceEvent const& eventData) const;
180
181 MCAPI void onPlayerDestroy(::BlockEvents::BlockPlayerDestroyEvent const& eventData) const;
182
183 MCAPI void onPlayerInteract(::BlockEvents::BlockPlayerInteractEvent& eventData) const;
184
185 MCAPI void onQueuedTick(::BlockEvents::BlockQueuedTickEvent const& eventData) const;
186
187 MCAPI void onRandomTick(::BlockEvents::BlockRandomTickEvent const& eventData) const;
188
189 MCAPI void onStepOff(::BlockEvents::BlockStepOffEvent const& eventData) const;
190
191 MCAPI void onStepOn(::BlockEvents::BlockStepOnEvent const& eventData) const;
192
193 MCAPI ::Scripting::Result<
194 void,
200 tryRegisterCustomComponent(
201 ::HashedString const& name,
204 );
205
206 MCAPI ::Scripting::Result<
207 void,
213 tryRegisterCustomComponentV1(
214 ::HashedString const& name,
217 );
218 // NOLINTEND
219
220public:
221 // static functions
222 // NOLINTBEGIN
223 MCAPI static ::ScriptModuleMinecraft::ScriptCustomComponentEventMetadata<
225 _getEventMetadata();
226
227 MCAPI static void bind(::Scripting::ModuleBindingBuilder& moduleBuilder);
228
229 MCAPI static void generateOrderDocumentationForVersion(
230 ::Scripting::ModuleDescriptor const& moduleToDocumentFor,
231 ::Json::Value& eventOrderArray
232 );
233 // NOLINTEND
234
235public:
236 // constructor thunks
237 // NOLINTBEGIN
238 MCAPI void* $ctor(::ScriptDeferredEventCoordinator& deferredEventCoordinator);
239 // NOLINTEND
240
241public:
242 // destructor thunk
243 // NOLINTBEGIN
244 MCAPI void $dtor();
245 // NOLINTEND
246
247public:
248 // virtual function thunks
249 // NOLINTBEGIN
250 MCAPI void $onPreFlushAfterEvents();
251
252 MCAPI void $onFlushBlockCustomComponentAfterEvents(::ScriptDeferredFlushTracker& deferredTracker);
253
254 MCAPI void $onPostFlushAfterEvents();
255
256 MCAPI void $_onScriptInitializationComplete();
257
258 MCAPI void $_onReload();
259 // NOLINTEND
260
261public:
262 // vftables
263 // NOLINTBEGIN
264 MCAPI static void** $vftableForScriptDeferredEventListener();
265
266 MCAPI static void** $vftableForScriptCustomComponentRegistry();
267 // NOLINTEND
268};
269
270} // namespace ScriptModuleMinecraft
Definition BlockCustomComponentsComponent.h:16
Definition BlockEntityFallOnEvent.h:15
Definition BlockPlaceEvent.h:15
Definition BlockPlayerDestroyEvent.h:15
Definition BlockPlayerInteractEvent.h:15
Definition BlockPlayerPlacingEvent.h:15
Definition BlockQueuedTickEvent.h:15
Definition BlockRandomTickEvent.h:15
Definition BlockStepOffEvent.h:15
Definition BlockStepOnEvent.h:15
Definition BlockLegacy.h:88
Definition Block.h:36
Definition HashedString.h:5
Definition Value.h:16
Definition ScriptDeferredEventCoordinator.h:16
Definition ScriptDeferredEventListener.h:10
Definition ScriptDeferredFlushTracker.h:5
Definition ScriptBlockCustomComponentInterface.h:10
Definition ScriptBlockCustomComponentsRegistry.h:44
Definition ScriptCustomComponentRegistry.h:7
Definition ModuleBindingBuilder.h:30
Definition WeakLifetimeScope.h:12
Definition BlockRandomTickEvent.h:11
Definition ScriptBlockCustomComponentAlreadyRegisteredError.h:15
Definition ScriptBlockCustomComponentReloadNewComponentError.h:15
Definition ScriptBlockCustomComponentReloadNewEventError.h:15
Definition ScriptBlockCustomComponentReloadVersionError.h:15
Definition ScriptCustomComponentInvalidRegistryError.h:17
Definition ModuleDescriptor.h:7
Definition Alias.h:14