3#include "mc/_HeaderOutputPredefine.h"
6#include "mc/client/gui/DirtyFlag.h"
7#include "mc/client/gui/GameEventNotification.h"
8#include "mc/client/gui/screens/IntellisenseHandler.h"
9#include "mc/client/gui/screens/controllers/ClientInstanceScreenController.h"
10#include "mc/client/gui/screens/controllers/HostOptionStates.h"
11#include "mc/deps/core/math/Vec3.h"
12#include "mc/deps/core/utility/pub_sub/Subscription.h"
13#include "mc/world/level/BlockPos.h"
20namespace Json {
class Value; }
26 enum class SelectionDirection :
int {
34 ::ll::TypedStorage<8, 32, ::std::string> mCurrentMessage;
35 ::ll::TypedStorage<8, 32, ::std::string> mCurrentHistoryPrefix;
36 ::ll::TypedStorage<1, 1, bool> mRefreshChatMessages;
37 ::ll::TypedStorage<1, 1, bool> mLockMessagesUpdates;
38 ::ll::TypedStorage<1, 1, bool> mScrollChatToBottom;
39 ::ll::TypedStorage<1, 1, bool> mHasUnreadMessages;
40 ::ll::TypedStorage<8, 8, uint64> mCurrentSentMessageIndex;
41 ::ll::TypedStorage<1, 1, bool> mNeedsLayoutUpdate;
42 ::ll::TypedStorage<1, 1, bool> mLastKeyboardActive;
43 ::ll::TypedStorage<1, 1, bool> mUpdateCoordinateUI;
44 ::ll::TypedStorage<1, 1, bool> mIsDevConsole;
45 ::ll::TypedStorage<1, 1, bool> mSendMessage;
46 ::ll::TypedStorage<1, 1, bool> mUpdateIntellisense;
47 ::ll::TypedStorage<8, 104, ::IntellisenseHandler> mIntellisense;
48 ::ll::TypedStorage<4, 4, ::HostOptionStates> mCurrentHostOption;
49 ::ll::TypedStorage<8, 24, ::std::vector<::std::string>> mHostCommands;
50 ::ll::TypedStorage<4, 4, uint> mExpectedCommandDepth;
51 ::ll::TypedStorage<8, 32, ::std::string> mTeleportWhoName;
52 ::ll::TypedStorage<8, 32, ::std::string> mTeleportWhereName;
53 ::ll::TypedStorage<8, 32, ::std::string> mDeferedCollectionFocusName;
54 ::ll::TypedStorage<4, 4, int> mDeferedCollectionFocusIndex;
55 ::ll::TypedStorage<1, 1, bool> mWaitOneTick;
56 ::ll::TypedStorage<1, 1, bool> mChatTextBoxNeedsUpdate;
57 ::ll::TypedStorage<4, 12, ::Vec3> mPositionCoordinates;
58 ::ll::TypedStorage<4, 16, ::std::optional<::BlockPos>> mFacingCoordinates;
59 ::ll::TypedStorage<8, 24, ::std::vector<::std::pair<::HostOptionStates, ::std::string>>> mMainHostButtons;
60 ::ll::TypedStorage<8, 16, ::Bedrock::PubSub::Subscription> mProfanityToggleSubscription;
61 ::ll::TypedStorage<1, 1, bool> mShouldUseFilteredMessage;
66 ChatScreenController();
71 virtual ~ChatScreenController() ;
73 virtual void onInit() ;
75 virtual void onOpen() ;
77 virtual void onEntered() ;
79 virtual void addStaticScreenVars(::Json::Value& globalVars) ;
81 virtual ::ui::DirtyFlag handleGameEventNotification(::ui::GameEventNotification notification) ;
83 virtual ::ui::DirtyFlag tick() ;
90 ChatScreenController(::std::shared_ptr<::ClientInstanceScreenModel> model,
bool openWithCommand,
bool isDevConsole);
92 MCAPI
void _buildHostButtons();
94 MCAPI
void _getBottomButtonFocusOverrideDown(::std::string& focusOverride);
96 MCAPI
void _getBottomButtonFocusOverrideUp(::std::string& focusOverride, uint64 lastIndex);
98 MCAPI ::std::string _getExitMessage()
const;
100 MCAPI ::std::optional<uint64> _getNextMessageIndex(
101 ::ChatScreenController::SelectionDirection direction,
102 ::std::deque<::std::string>
const& sentMessages
105 MCAPI ::std::string _getSendMessage()
const;
107 MCAPI
void _handleChatMessage(::std::string
const& message, ::std::string
const& ttsMessage);
109 MCAPI
void _handleSelectSentMessage(::ChatScreenController::SelectionDirection direction);
111 MCAPI
bool _hostOptionNavigation();
113 MCAPI
void _initScreenControllerProxy();
115 MCAPI
void _refreshChatMessages();
117 MCAPI
void _refreshDevConsoleScreenMessages();
119 MCAPI
void _registerBindings();
121 MCAPI
void _registerBindingsHostOptions();
123 MCAPI
void _registerBindingsSubCommand(
124 ::std::vector<::HostOptionSubCommand>& subCommandButtons,
125 ::StringHash
const& gridName,
126 ::StringHash
const& collectionName
129 MCAPI
void _registerEventHandlers();
131 MCAPI
void _registerEventHandlersHostOptions();
133 MCAPI
void _registerSubControllers();
135 MCAPI
void _sendChatMessage();
137 MCAPI
void _teleportWhereHelper();
139 MCAPI
void _teleportWhoHelper();
145 MCAPI
static char const*
const& DEV_CONSOLE_SCREEN_NAME();
151 MCAPI
void* $ctor(::std::shared_ptr<::ClientInstanceScreenModel> model,
bool openWithCommand,
bool isDevConsole);
163 MCAPI
void $onInit();
165 MCAPI
void $onOpen();
167 MCAPI
void $onEntered();
169 MCAPI
void $addStaticScreenVars(::Json::Value& globalVars);
171 MCAPI ::ui::DirtyFlag $handleGameEventNotification(::ui::GameEventNotification notification);
173 MCAPI ::ui::DirtyFlag $tick();
Definition ChatScreenController.h:5
static MCAPI void ** $vftableForScreenController()
static MCAPI void ** $vftableForEnableNonOwnerReferences()
Definition ClientInstanceScreenController.h:5
Definition ClientInstanceScreenModel.h:5
Definition StringHash.h:5
Definition HostOptionSubCommand.h:5