LeviLamina
Loading...
Searching...
No Matches
TickTimeManagerServer.h
1#pragma once
2
3#include "mc/_HeaderOutputPredefine.h"
4
5// auto generated inclusion list
6#include "mc/deps/core/utility/NonOwnerPointer.h"
7#include "mc/deps/core/utility/UniqueOwnerPointer.h"
8#include "mc/deps/core/utility/pub_sub/Subscription.h"
9#include "mc/world/level/TickTimeManager.h"
10
11// auto generated forward declare list
12// clang-format off
16class LevelData;
18class LevelStorage;
19class PacketSender;
22namespace cereal { struct ReflectionCtx; }
23// clang-format on
24
25class TickTimeManagerServer : public ::TickTimeManager {
26public:
27 // member variables
28 // NOLINTBEGIN
29 ::ll::TypedStorage<8, 16, ::gsl::not_null<::Bedrock::UniqueOwnerPointer<::WorldClockRegistryServer>>>
30 mWorldClockRegistry;
31 ::ll::TypedStorage<8, 8, int64> mLastTimePacketSent;
32 ::ll::TypedStorage<8, 16, ::Bedrock::PubSub::Subscription> mOnGameplayUserAdded;
33 ::ll::TypedStorage<8, 16, ::Bedrock::PubSub::Subscription> mOnSaveLevelDataSubscription;
34 ::ll::TypedStorage<8, 16, ::Bedrock::PubSub::Subscription> mOnWakeUpAllPlayersSubscription;
35 // NOLINTEND
36
37public:
38 // prevent constructor by default
39 TickTimeManagerServer();
40
41public:
42 // virtual functions
43 // NOLINTBEGIN
44 virtual ~TickTimeManagerServer() /*override*/ = default;
45
46 virtual void update() /*override*/;
47
48 virtual ::Bedrock::NotNullNonOwnerPtr<::WorldClockRegistry const> const getWorldClockRegistry() const /*override*/;
49
50 virtual ::Bedrock::NotNullNonOwnerPtr<::WorldClockRegistry> const getWorldClockRegistry() /*override*/;
51 // NOLINTEND
52
53public:
54 // member functions
55 // NOLINTBEGIN
56 MCAPI TickTimeManagerServer(
57 ::Bedrock::NotNullNonOwnerPtr<::LevelData> const& levelData,
59 ::Bedrock::NotNullNonOwnerPtr<::PacketSender> const& packetSender,
60 ::Bedrock::NotNullNonOwnerPtr<::LevelEventCoordinator> const& levelEventCoordinator
61 );
62
63 MCAPI void _onWakeUpAllPlayers();
64
65 MCAPI void _saveWorldClocks(::LevelStorage& levelStorage) const;
66
67 MCAPI void
68 intitializeWithLevelStorageManagerConnector(::ILevelStorageManagerConnector& levelStorageManagerConnector);
69
70 MCAPI void loadWorldClocks(::LevelStorage& levelStorage);
71
72 MCAPI void registerForGameplayUserManagerEvents(::IGameplayUserManagerConnector& gameplayUserManagerConnector);
73
74 MCAPI void
75 registerForPlayerSleepManagerEvents(::IServerPlayerSleepManagerConnector& serverPlayerSleepManagerConnector);
76 // NOLINTEND
77
78public:
79 // constructor thunks
80 // NOLINTBEGIN
81 MCAPI void* $ctor(
82 ::Bedrock::NotNullNonOwnerPtr<::LevelData> const& levelData,
84 ::Bedrock::NotNullNonOwnerPtr<::PacketSender> const& packetSender,
85 ::Bedrock::NotNullNonOwnerPtr<::LevelEventCoordinator> const& levelEventCoordinator
86 );
87 // NOLINTEND
88
89public:
90 // virtual function thunks
91 // NOLINTBEGIN
92 MCAPI void $update();
93
94 MCAPI ::Bedrock::NotNullNonOwnerPtr<::WorldClockRegistry const> const $getWorldClockRegistry() const;
95
96 MCAPI ::Bedrock::NotNullNonOwnerPtr<::WorldClockRegistry> const $getWorldClockRegistry();
97
98
99 // NOLINTEND
100};
Definition IGameplayUserManagerConnector.h:14
Definition ILevelStorageManagerConnector.h:13
Definition IServerPlayerSleepManagerConnector.h:13
Definition LevelData.h:55
Definition LevelEventCoordinator.h:26
Definition LevelStorage.h:25
Definition PacketSender.h:17
Definition TickTimeManager.h:16
Definition WorldClockRegistryServer.h:21
Definition WorldClockRegistry.h:23
Definition ReflectionCtx.h:11
Definition ctx.h:5