LeviLamina
Loading...
Searching...
No Matches
PlayerMovement.h
1#pragma once
2
3#include "mc/_HeaderOutputPredefine.h"
4
5// auto generated inclusion list
6#include "mc/deps/input/InputMode.h"
7#include "mc/entity/components/PlayerPositionModeComponent.h"
8
9// auto generated forward declare list
10// clang-format off
11class EntityContext;
12class Vec2;
15struct ActorUniqueID;
18struct MoveInputState;
22struct Tick;
24// clang-format on
25
26namespace PlayerMovement {
27// functions
28// NOLINTBEGIN
29MCAPI void applyInputLocks(::ClientInputLockComponent const& lockComponent, ::MoveInputState& inputState);
30
31#ifdef LL_PLAT_C
32MCAPI ::Vec2 calculateButtonMoveVector(::MoveInputState const& inputState);
33#endif
34
35MCAPI ::Vec2 calculateMoveVector(
36 ::MoveInputState const& inputState,
37 bool playerIsFlying,
38 ::ActorDataFlagComponent const& playerData,
39 bool playerIsInWater,
40 ::SneakingComponent const* sneakComponent
41);
42
43MCAPI void clearInputState(::MoveInputComponent& input);
44
45#ifdef LL_PLAT_C
46MCAPI float getBob(::EntityContext const& provider);
47
48MCAPI float getBobPrev(::EntityContext const& provider);
49#endif
50
51MCAPI ::ActorUniqueID
52getControllingPassengerID(::std::vector<::StrictActorIDEntityContextPair> const& passengers, int controllingSeat);
53
54MCAPI ::InputMode getInputMode(::EntityContext const& provider);
55
56MCAPI ::PlayerPositionModeComponent::PositionMode getPositionMode(::EntityContext const& provider);
57
58MCAPI void initializePlayer(::EntityContext& provider);
59
60#ifdef LL_PLAT_C
61MCAPI void initializeRemotePlayer(::EntityContext& provider);
62#endif
63
64MCAPI bool isGamepad(::PlayerInputModeComponent const& playerInputModeComponent);
65
66MCAPI void resetBob(::EntityContext& provider);
67
68MCAPI void setElytraFlightTimeTicks(::EntityContext& provider, ::Tick const& value);
69
70MCAPI void setPositionMode(::EntityContext& provider, ::PlayerPositionModeComponent::PositionMode positionMode);
71
72MCAPI bool shouldStopEmoting(
73 ::Vec2 rawMove,
74 ::ActorDataFlagComponent& actorDataFlag,
75 ::ActorDataDirtyFlagsComponent& actorDataDirtyFlags,
76 ::ClientInputLockComponent& lockComponent,
77 ::VanillaClientGameplayComponent& vanillaClientGameplayComponent
78);
79// NOLINTEND
80
81} // namespace PlayerMovement
Definition EntityContext.h:17
Definition Vec2.h:5
Definition ActorDataDirtyFlagsComponent.h:5
Definition ActorDataFlagComponent.h:10
Definition ActorUniqueID.h:10
Definition ClientInputLockComponent.h:10
Definition MoveInputComponent.h:11
Definition MoveInputState.h:9
Definition PlayerInputModeComponent.h:9
Definition SneakingComponent.h:5
Definition StrictActorIDEntityContextPair.h:9
Definition Tick.h:5
Definition VanillaClientGameplayComponent.h:8