LeviLamina
Loading...
Searching...
No Matches
ClientInputHandler.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/input/InputBindingMode.h"
8#include "mc/deps/input/InputMode.h"
9
10// auto generated forward declare list
11// clang-format off
12class Actor;
16class Config;
17class IClientInstance;
18class IGameModuleApp;
19class InputHandler;
20class ItemStack;
21class ScreenContext;
26namespace Input::Debug { class ISplitscreenRedirect; }
27// clang-format on
28
30public:
31 // member variables
32 // NOLINTBEGIN
33 ::ll::TypedStorage<8, 24, ::Bedrock::NotNullNonOwnerPtr<::IClientInstance>> mClient;
34 ::ll::TypedStorage<8, 8, ::InputHandler&> mInputHandler;
35 ::ll::TypedStorage<8, 24, ::Bedrock::NotNullNonOwnerPtr<::Input::Debug::ISplitscreenRedirect>>
36 mDebugSplitscreenInputRedirect;
37 ::ll::TypedStorage<4, 4, ::InputBindingMode> mInputBindingMode;
38 ::ll::TypedStorage<8, 8, ::std::unique_ptr<::ClientBindingFactory>> mBindingFactory;
39 ::ll::TypedStorage<8, 8, ::std::unique_ptr<::ClientInputMappingFactory>> mMappingFactory;
40 ::ll::TypedStorage<8, 32, ::std::string> mExpectedInGameInputMode;
41 ::ll::TypedStorage<1, 1, bool> mIsFlying;
42 ::ll::TypedStorage<1, 1, bool> mIsSneaking;
43 ::ll::TypedStorage<1, 1, bool> mIsSprinting;
44 ::ll::TypedStorage<1, 1, bool> mIsSwimming;
45 ::ll::TypedStorage<1, 1, bool> mIsInWater;
46 ::ll::TypedStorage<1, 1, bool> mIsExpediateEmoteActive;
47 ::ll::TypedStorage<1, 1, bool> mIsInAscendableBlock;
48 ::ll::TypedStorage<1, 1, bool> mIsOnDescendableBlock;
49 ::ll::TypedStorage<1, 1, bool> mIsCreativeMode;
50 ::ll::TypedStorage<1, 1, bool> mIsSpectatorMode;
51 ::ll::TypedStorage<1, 1, bool> mInteractActive;
52 ::ll::TypedStorage<1, 1, bool> mHasMobEffects;
53 ::ll::TypedStorage<8, 8, ::std::unique_ptr<::ClientInputHandlerProxy>> mProxy;
54 // NOLINTEND
55
56public:
57 // prevent constructor by default
58 ClientInputHandler& operator=(ClientInputHandler const&);
59 ClientInputHandler(ClientInputHandler const&);
60 ClientInputHandler();
61
62public:
63 // member functions
64 // NOLINTBEGIN
65 MCAPI ClientInputHandler(
66 ::Bedrock::NotNullNonOwnerPtr<::IClientInstance> const& client,
67 ::InputHandler& inputHandler,
68 ::Bedrock::NotNullNonOwnerPtr<::Input::Debug::ISplitscreenRedirect> const& debugSplitscreenInputRedirect,
69 ::IGameModuleApp& gameModuleApp
70 );
71
72 MCAPI ::Actor* _interactWithEntity() const;
73
74 MCAPI ::std::string _interactWithImmersiveReader() const;
75
76 MCAPI ::ItemStack const& _interactWithItem() const;
77
78 MCAPI bool _shouldUseGameInputMapping() const;
79
80 MCAPI bool canInteract() const;
81
82 MCAPI bool canPaddle() const;
83
84 MCAPI ::std::string getBoatExitText() const;
85
86 MCAPI ::InputMode getCurrentInputMode() const;
87
88 MCAPI void getCursorPos(float& xCursor, float& yCursor) const;
89
90 MCAPI ::std::string getInteractText() const;
91
92 MCAPI bool getSplitscreenJoinPromptVisible() const;
93
94 MCAPI bool isBlockSelectToggled() const;
95
96 MCAPI bool isTouchGameplayAllowed() const;
97
98 MCAPI void onConfigChanged(::Config const& c);
99
100 MCAPI void popInputMapping(bool inGame);
101
102 MCAPI void pushInputMapping(bool inGame);
103
104 MCAPI void releaseButtonsAndSticks();
105
106 MCAPI void render(::ScreenContext& screenContext);
107
108 MCAPI void resetPlayerState();
109
110 MCAPI void setBlockSelectToggle(bool value);
111
112 MCAPI void setDisableInput(bool disable);
113
114 MCAPI void setSuspendDirectionalInput(bool suspendDirectionalInput);
115
116 MCAPI void setSuspendInput(bool suspendInput);
117
118 MCAPI bool showBoatExit() const;
119
120 MCAPI void updateInputMapping();
121
122 MCAPI bool updateInputMode(::std::string const& mode);
123
124 MCAPI void updatePlayerState(
125 ::gsl::not_null<::IClientInstance const*> client,
126 ::MovementAbilitiesComponent const& abilities,
127 ::MobEffectsComponent const& mobEffects,
128 ::ActorDataFlagComponent const& synchedActorData,
129 ::MoveInputComponent& moveInput,
130 bool isRiding,
131 bool isInWater
132 );
133
134 MCAPI bool useFreeformPickDirection() const;
135
136 MCAPI ~ClientInputHandler();
137 // NOLINTEND
138
139public:
140 // constructor thunks
141 // NOLINTBEGIN
142 MCAPI void* $ctor(
143 ::Bedrock::NotNullNonOwnerPtr<::IClientInstance> const& client,
144 ::InputHandler& inputHandler,
145 ::Bedrock::NotNullNonOwnerPtr<::Input::Debug::ISplitscreenRedirect> const& debugSplitscreenInputRedirect,
146 ::IGameModuleApp& gameModuleApp
147 );
148 // NOLINTEND
149
150public:
151 // destructor thunk
152 // NOLINTBEGIN
153 MCAPI void $dtor();
154 // NOLINTEND
155};
Definition Actor.h:113
Definition ClientBindingFactory.h:5
Definition ClientInputHandlerProxy.h:5
Definition ClientInputHandler.h:5
Definition ClientInputMappingFactory.h:5
Definition Config.h:5
Definition IClientInstance.h:5
Definition IGameModuleApp.h:5
Definition InputHandler.h:5
Definition ISplitscreenRedirect.h:7
Definition ItemStack.h:26
Definition ScreenContext.h:5
Definition ActorDataFlagComponent.h:9
Definition MobEffectsComponent.h:8
Definition MoveInputComponent.h:11
Definition MovementAbilitiesComponent.h:5