3#include "mc/_HeaderOutputPredefine.h"
6#include "mc/certificates/identity/LegacyMultiplayerToken.h"
7#include "mc/certificates/identity/PlayerAuthenticationType.h"
8#include "mc/certificates/identity/RawGameServerToken.h"
9#include "mc/client/network/ClientNetworkHandler.h"
10#include "mc/deps/core/utility/NonOwnerPointer.h"
11#include "mc/deps/core/utility/pub_sub/Subscription.h"
12#include "mc/network/NetworkIdentifier.h"
13#include "mc/network/connection/DisconnectFailReason.h"
14#include "mc/platform/brstd/move_only_function.h"
15#include "mc/world/actor/player/SkinMemThresholds.h"
16#include "mc/world/level/LevelListener.h"
17#include "mc/world/level/dimension/DimensionDefinitionGroup.h"
92namespace mce {
class UUID; }
99 ::ll::TypedStorage<8, 16, ::DimensionDefinitionGroup> mDimensionDefinitionGroup;
100 ::ll::TypedStorage<8, 24, ::Bedrock::NonOwnerPointer<::ILevel>> mMultiPlayerLevel;
101 ::ll::TypedStorage<4, 4, int> mPendingTime;
102 ::ll::TypedStorage<8, 32, ::std::string> mServerIdentifier;
103 ::ll::TypedStorage<8, 8, ::std::unique_ptr<::NetworkChunkInserter>> mChunkInsertQueue;
104 ::ll::TypedStorage<8, 176, ::NetworkIdentifier> mServerGuid;
105 ::ll::TypedStorage<4, 4, ::PlayerAuthenticationType> mPlayerAuthenticationType;
106 ::ll::TypedStorage<8, 8, ::LegacyMultiplayerToken> mPlayerLegacyMultiplayerToken;
107 ::ll::TypedStorage<8, 32, ::RawGameServerToken> mGameServerToken;
108 ::ll::TypedStorage<8, 16, ::Bedrock::PubSub::Subscription> mPackSettingChangeSubscriber;
109 ::ll::TypedStorage<8, 8, ::std::chrono::steady_clock::time_point> mNextChunkRequestDrainTime;
110 ::ll::TypedStorage<8, 16, ::std::shared_ptr<bool>> mExistanceTracker;
111 ::ll::TypedStorage<8, 8, ::std::unique_ptr<::IPersonaNetworkHandlerDelegate>> mPersonaNetworkHandlerDelegate;
112 ::ll::TypedStorage<8, 24, ::SkinMemThresholds> mSkinMemThresholds;
113 ::ll::TypedStorage<1, 1, bool> mIsConnectedToApplicationLayer;
114 ::ll::TypedStorage<8, 24, ::Bedrock::NotNullNonOwnerPtr<::cereal::ReflectionCtx>> mCtx;
115 ::ll::TypedStorage<8, 8, ::std::unique_ptr<::EntityOverrides>> mEntityOverrides;
119 ::brstd::move_only_function<::std::unique_ptr<::MultiPlayerLevel>(::ClientCreateLevelArguments&&) const>>
121 ::ll::TypedStorage<8, 24, ::Bedrock::NotNullNonOwnerPtr<::AppPlatform>> mAppPlatform;
126 LegacyClientNetworkHandler();
131 virtual ~LegacyClientNetworkHandler() ;
133 virtual
void onPlayerReady(::Player& player) ;
135 virtual
void onConnect(::NetworkIdentifier const& hostId) ;
137 virtual
void onUnableToConnect(
138 ::Connection::DisconnectFailReason discoReason,
139 ::std::
string const& messageFromServer,
140 ::std::
string const& messageBodyOverride
143 virtual
bool getIsConnectedToApplicationLayer() const ;
145 virtual
void handle(::NetworkIdentifier const& source, ::AddActorPacket const& packet) ;
147 virtual
void handle(::NetworkIdentifier const& source, ::AddItemActorPacket const& packet) ;
149 virtual
void handle(::NetworkIdentifier const& source, ::AddPaintingPacket const& packet) ;
151 virtual
void handle(::NetworkIdentifier const& source, ::AddPlayerPacket const& packet) ;
153 virtual
void handle(::NetworkIdentifier const&, ::AnimatePacket const& packet) ;
156 handle(::NetworkIdentifier const& source, ::std::shared_ptr<::BlockActorDataPacket> packet) ;
158 virtual
void handle(::NetworkIdentifier const& source, ::BlockEventPacket const& packet) ;
160 virtual
void handle(::NetworkIdentifier const& source, ::ChangeDimensionPacket const& packet) ;
162 virtual
void handle(::NetworkIdentifier const& source, ::ContainerClosePacket const& packet) ;
164 virtual
void handle(::NetworkIdentifier const& source, ::ContainerOpenPacket const& packet) ;
166 virtual
void handle(::NetworkIdentifier const& source, ::ContainerRegistryCleanupPacket const& packet) ;
168 virtual
void handle(::NetworkIdentifier const& source, ::ContainerSetDataPacket const& packet) ;
170 virtual
void handle(::NetworkIdentifier const& source, ::DisconnectPacket const& packet) ;
172 virtual
void handle(::NetworkIdentifier const& source, ::std::shared_ptr<::LevelChunkPacket> packet) ;
175 handle(::NetworkIdentifier const& source, ::std::shared_ptr<::ClientCacheMissResponsePacket> packet) ;
177 virtual
void handle(::NetworkIdentifier const& source, ::GameRulesChangedPacket const& packet) ;
179 virtual
void handle(::NetworkIdentifier const& source, ::HurtArmorPacket const& packet) ;
181 virtual
void handle(::NetworkIdentifier const& source, ::InventoryContentPacket const& packet) ;
183 virtual
void handle(::NetworkIdentifier const& source, ::InventorySlotPacket const& packet) ;
186 handle(::NetworkIdentifier const&, ::std::shared_ptr<::InventoryTransactionPacket> packet) ;
188 virtual
void handle(::NetworkIdentifier const& source, ::MobArmorEquipmentPacket const& packet) ;
190 virtual
void handle(::NetworkIdentifier const&, ::MobEffectPacket const& packet) ;
193 handle(::NetworkIdentifier const& source, ::std::shared_ptr<::MobEquipmentPacket> packetPtr) ;
195 virtual
void handle(::NetworkIdentifier const& source, ::MoveActorAbsolutePacket const& packet) ;
197 virtual
void handle(::NetworkIdentifier const& source, ::MoveActorDeltaPacket const& packet) ;
199 virtual
void handle(::NetworkIdentifier const&, ::MovementEffectPacket const& packet) ;
201 virtual
void handle(::NetworkIdentifier const& source, ::MovePlayerPacket const& packet) ;
203 virtual
void handle(::NetworkIdentifier const& source, ::NetworkSettingsPacket const& packet) ;
205 virtual
void handle(::NetworkIdentifier const& source, ::NetworkStackLatencyPacket const& packet) ;
207 virtual
void handle(::NetworkIdentifier const& source, ::PlayerHotbarPacket const& packet) ;
209 virtual
void handle(::NetworkIdentifier const& source, ::PlayerListPacket const& packet) ;
211 virtual
void handle(::NetworkIdentifier const& source, ::PlayerSkinPacket const& packet) ;
213 virtual
void handle(::NetworkIdentifier const&, ::PlayerUpdateEntityOverridesPacket const& packet) ;
215 virtual
void handle(::NetworkIdentifier const& source, ::RemoveActorPacket const& packet) ;
217 virtual
void handle(::NetworkIdentifier const& source, ::SetActorDataPacket const& packet) ;
219 virtual
void handle(::NetworkIdentifier const& source, ::SetActorLinkPacket const& packet) ;
221 virtual
void handle(::NetworkIdentifier const&, ::SetActorMotionPacket const& packet) ;
223 virtual
void handle(::NetworkIdentifier const& source, ::MotionPredictionHintsPacket const& packet) ;
225 virtual
void handle(::NetworkIdentifier const& source, ::SetCommandsEnabledPacket const& packet) ;
227 virtual
void handle(::NetworkIdentifier const& source, ::SetDefaultGameTypePacket const& packet) ;
229 virtual
void handle(::NetworkIdentifier const& source, ::SetDifficultyPacket const& packet) ;
231 virtual
void handle(::NetworkIdentifier const& source, ::SetHealthPacket const& packet) ;
233 virtual
void handle(::NetworkIdentifier const& source, ::SetSpawnPositionPacket const& packet) ;
235 virtual
void handle(::NetworkIdentifier const& source, ::SetTimePacket const& packet) ;
237 virtual
void handle(::NetworkIdentifier const& source, ::SetHudPacket const& packet) ;
239 virtual
void handle(::NetworkIdentifier const& source, ::SpawnParticleEffectPacket const& packet) ;
241 virtual
void handle(::NetworkIdentifier const& source, ::StartGamePacket const& packet) ;
243 virtual
void handle(::NetworkIdentifier const& source, ::std::shared_ptr<::UpdateBlockPacket> packet) ;
246 handle(::NetworkIdentifier const& source, ::std::shared_ptr<::UpdateBlockSyncedPacket> packet) ;
248 virtual
void handle(::NetworkIdentifier const& source, ::CreativeContentPacket const& packet) ;
250 virtual
void handle(::NetworkIdentifier const&, ::ItemRegistryPacket const& packet) ;
252 virtual
void handle(::NetworkIdentifier const& source, ::DimensionDataPacket const& packet) ;
254 virtual
void handle(::NetworkIdentifier const& source, ::UpdateAbilitiesPacket const& packet) ;
256 virtual
void handle(::NetworkIdentifier const& source, ::UpdateAdventureSettingsPacket const& packet) ;
258 virtual
void handle(::NetworkIdentifier const& source, ::ServerStatsPacket const& packet) ;
260 virtual
void onTick() ;
262 virtual
void onEntityRemoved(::Actor& entity) ;
264 virtual
void onLevelDestruction(::std::
string const&) ;
270 MCAPI explicit LegacyClientNetworkHandler(::LegacyClientNetworkHandlerArguments&& args);
272 MCAPI
void _drainCacheMissesQueueAndSendPacket();
274 MCAPI ::std::
string _getServerIdentifier() const;
276 MCAPI
void _removePlayer(::mce::UUID const& playerEntryId);
278 MCAPI
bool _shouldKeepSkinBasedOnMemory(::mce::UUID const& playerId, ::SerializedSkinRef const& skin) const;
280 MCAPI
void onSubClientConnect();
286 MCAPI static
void handleUpdateBlock(
287 ::IBlockSource& region,
288 ::BlockPos const& pos,
289 ::Block const& block,
292 ::ActorBlockSyncMessage const* syncMsg
299 MCAPI
void* $ctor(::LegacyClientNetworkHandlerArguments&& args);
311 MCAPI
void $onPlayerReady(::Player& player);
313 MCAPI
void $onConnect(::NetworkIdentifier const& hostId);
315 MCAPI
void $onUnableToConnect(
316 ::Connection::DisconnectFailReason discoReason,
317 ::std::
string const& messageFromServer,
318 ::std::
string const& messageBodyOverride
321 MCFOLD
bool $getIsConnectedToApplicationLayer() const;
323 MCAPI
void $handle(::NetworkIdentifier const& source, ::AddActorPacket const& packet);
325 MCAPI
void $handle(::NetworkIdentifier const& source, ::AddItemActorPacket const& packet);
327 MCAPI
void $handle(::NetworkIdentifier const& source, ::AddPaintingPacket const& packet);
329 MCAPI
void $handle(::NetworkIdentifier const& source, ::AddPlayerPacket const& packet);
331 MCAPI
void $handle(::NetworkIdentifier const&, ::AnimatePacket const& packet);
333 MCAPI
void $handle(::NetworkIdentifier const& source, ::std::shared_ptr<::BlockActorDataPacket> packet);
335 MCAPI
void $handle(::NetworkIdentifier const& source, ::BlockEventPacket const& packet);
337 MCAPI
void $handle(::NetworkIdentifier const& source, ::ChangeDimensionPacket const& packet);
339 MCAPI
void $handle(::NetworkIdentifier const& source, ::ContainerClosePacket const& packet);
341 MCAPI
void $handle(::NetworkIdentifier const& source, ::ContainerOpenPacket const& packet);
343 MCAPI
void $handle(::NetworkIdentifier const& source, ::ContainerRegistryCleanupPacket const& packet);
345 MCAPI
void $handle(::NetworkIdentifier const& source, ::ContainerSetDataPacket const& packet);
347 MCAPI
void $handle(::NetworkIdentifier const& source, ::DisconnectPacket const& packet);
349 MCAPI
void $handle(::NetworkIdentifier const& source, ::std::shared_ptr<::LevelChunkPacket> packet);
351 MCAPI
void $handle(::NetworkIdentifier const& source, ::std::shared_ptr<::ClientCacheMissResponsePacket> packet);
353 MCAPI
void $handle(::NetworkIdentifier const& source, ::GameRulesChangedPacket const& packet);
355 MCAPI
void $handle(::NetworkIdentifier const& source, ::HurtArmorPacket const& packet);
357 MCAPI
void $handle(::NetworkIdentifier const& source, ::InventoryContentPacket const& packet);
359 MCAPI
void $handle(::NetworkIdentifier const& source, ::InventorySlotPacket const& packet);
361 MCAPI
void $handle(::NetworkIdentifier const&, ::std::shared_ptr<::InventoryTransactionPacket> packet);
363 MCAPI
void $handle(::NetworkIdentifier const& source, ::MobArmorEquipmentPacket const& packet);
365 MCAPI
void $handle(::NetworkIdentifier const&, ::MobEffectPacket const& packet);
367 MCAPI
void $handle(::NetworkIdentifier const& source, ::std::shared_ptr<::MobEquipmentPacket> packetPtr);
369 MCAPI
void $handle(::NetworkIdentifier const& source, ::MoveActorAbsolutePacket const& packet);
371 MCAPI
void $handle(::NetworkIdentifier const& source, ::MoveActorDeltaPacket const& packet);
373 MCAPI
void $handle(::NetworkIdentifier const&, ::MovementEffectPacket const& packet);
375 MCAPI
void $handle(::NetworkIdentifier const& source, ::MovePlayerPacket const& packet);
377 MCAPI
void $handle(::NetworkIdentifier const& source, ::NetworkSettingsPacket const& packet);
379 MCAPI
void $handle(::NetworkIdentifier const& source, ::NetworkStackLatencyPacket const& packet);
381 MCAPI
void $handle(::NetworkIdentifier const& source, ::PlayerHotbarPacket const& packet);
383 MCAPI
void $handle(::NetworkIdentifier const& source, ::PlayerListPacket const& packet);
385 MCAPI
void $handle(::NetworkIdentifier const& source, ::PlayerSkinPacket const& packet);
387 MCAPI
void $handle(::NetworkIdentifier const&, ::PlayerUpdateEntityOverridesPacket const& packet);
389 MCAPI
void $handle(::NetworkIdentifier const& source, ::RemoveActorPacket const& packet);
391 MCAPI
void $handle(::NetworkIdentifier const& source, ::SetActorDataPacket const& packet);
393 MCAPI
void $handle(::NetworkIdentifier const& source, ::SetActorLinkPacket const& packet);
395 MCAPI
void $handle(::NetworkIdentifier const&, ::SetActorMotionPacket const& packet);
397 MCAPI
void $handle(::NetworkIdentifier const& source, ::MotionPredictionHintsPacket const& packet);
399 MCAPI
void $handle(::NetworkIdentifier const& source, ::SetCommandsEnabledPacket const& packet);
401 MCAPI
void $handle(::NetworkIdentifier const& source, ::SetDefaultGameTypePacket const& packet);
403 MCAPI
void $handle(::NetworkIdentifier const& source, ::SetDifficultyPacket const& packet);
405 MCAPI
void $handle(::NetworkIdentifier const& source, ::SetHealthPacket const& packet);
407 MCAPI
void $handle(::NetworkIdentifier const& source, ::SetSpawnPositionPacket const& packet);
409 MCAPI
void $handle(::NetworkIdentifier const& source, ::SetTimePacket const& packet);
411 MCAPI
void $handle(::NetworkIdentifier const& source, ::SetHudPacket const& packet);
413 MCAPI
void $handle(::NetworkIdentifier const& source, ::SpawnParticleEffectPacket const& packet);
415 MCAPI
void $handle(::NetworkIdentifier const& source, ::StartGamePacket const& packet);
417 MCAPI
void $handle(::NetworkIdentifier const& source, ::std::shared_ptr<::UpdateBlockPacket> packet);
419 MCAPI
void $handle(::NetworkIdentifier const& source, ::std::shared_ptr<::UpdateBlockSyncedPacket> packet);
421 MCAPI
void $handle(::NetworkIdentifier const& source, ::CreativeContentPacket const& packet);
423 MCAPI
void $handle(::NetworkIdentifier const&, ::ItemRegistryPacket const& packet);
425 MCAPI
void $handle(::NetworkIdentifier const& source, ::DimensionDataPacket const& packet);
427 MCAPI
void $handle(::NetworkIdentifier const& source, ::UpdateAbilitiesPacket const& packet);
429 MCAPI
void $handle(::NetworkIdentifier const& source, ::UpdateAdventureSettingsPacket const& packet);
431 MCAPI
void $handle(::NetworkIdentifier const& source, ::ServerStatsPacket const& packet);
433 MCAPI
void $onTick();
435 MCAPI
void $onEntityRemoved(::Actor& entity);
437 MCAPI
void $onLevelDestruction(::std::
string const&);
Definition AddActorPacket.h:29
Definition AddItemActorPacket.h:23
Definition AddPaintingPacket.h:20
Definition AddPlayerPacket.h:30
Definition AnimatePacket.h:19
Definition BlockActorDataPacket.h:19
Definition BlockEventPacket.h:19
Definition ChangeDimensionPacket.h:19
Definition ClientCacheMissResponsePacket.h:17
Definition ClientNetworkHandler.h:5
Definition ContainerClosePacket.h:19
Definition ContainerOpenPacket.h:19
Definition ContainerRegistryCleanupPacket.h:19
Definition ContainerSetDataPacket.h:19
Definition CreativeContentPacket.h:22
Definition DimensionDataPacket.h:17
Definition DisconnectPacket.h:17
Definition EntityOverrides.h:8
Definition GameRulesChangedPacket.h:19
Definition HurtArmorPacket.h:19
Definition IBlockSource.h:38
Definition IPersonaNetworkHandlerDelegate.h:5
Definition InventoryContentPacket.h:21
Definition InventorySlotPacket.h:20
Definition InventoryTransactionPacket.h:24
Definition ItemRegistryPacket.h:19
Definition LegacyClientNetworkHandler.h:5
static MCAPI void ** $vftableForClientNetworkHandler()
static MCAPI void ** $vftableForLevelListener()
Definition LevelChunkPacket.h:19
Definition LevelListener.h:28
Definition MobArmorEquipmentPacket.h:19
Definition MobEffectPacket.h:19
Definition MobEquipmentPacket.h:24
Definition MotionPredictionHintsPacket.h:19
Definition MoveActorAbsolutePacket.h:19
Definition MoveActorDeltaPacket.h:17
Definition MovePlayerPacket.h:22
Definition MovementEffectPacket.h:19
Definition MultiPlayerLevel.h:5
Definition NetworkChunkInserter.h:5
Definition NetworkSettingsPacket.h:19
Definition NetworkStackLatencyPacket.h:19
Definition PlayerHotbarPacket.h:19
Definition PlayerListPacket.h:18
Definition PlayerSkinPacket.h:19
Definition PlayerUpdateEntityOverridesPacket.h:18
Definition RemoveActorPacket.h:19
Definition SerializedSkinRef.h:23
Definition ServerStatsPacket.h:19
Definition SetActorDataPacket.h:26
Definition SetActorLinkPacket.h:19
Definition SetActorMotionPacket.h:19
Definition SetCommandsEnabledPacket.h:19
Definition SetDefaultGameTypePacket.h:19
Definition SetDifficultyPacket.h:19
Definition SetHealthPacket.h:19
Definition SetHudPacket.h:19
Definition SetSpawnPositionPacket.h:19
Definition SetTimePacket.h:19
Definition SpawnParticleEffectPacket.h:19
Definition StartGamePacket.h:31
Definition UpdateAbilitiesPacket.h:18
Definition UpdateAdventureSettingsPacket.h:19
Definition UpdateBlockPacket.h:19
Definition UpdateBlockSyncedPacket.h:19
Definition ActorBlockSyncMessage.h:8
Definition ClientCreateLevelArguments.h:5
Definition LegacyClientNetworkHandlerArguments.h:5
Definition ReflectionCtx.h:11