LeviLamina
Loading...
Searching...
No Matches
BlockPlayerInteractEvent.h
1#pragma once
2
3#include "mc/_HeaderOutputPredefine.h"
4
5// auto generated inclusion list
6#include "mc/deps/core/math/Vec3.h"
7#include "mc/world/level/block/block_events/BlockEventBase.h"
8
9// auto generated forward declare list
10// clang-format off
11class BlockPos;
12class BlockSource;
13class ItemStack;
14class Player;
15class RenderParams;
16// clang-format on
17
18namespace BlockEvents {
19
20class BlockPlayerInteractEvent : public ::BlockEvents::BlockEventBase {
21public:
22 // member variables
23 // NOLINTBEGIN
24 ::ll::TypedStorage<8, 8, ::Player&> mPlayer;
25 ::ll::TypedStorage<1, 2, ::std::optional<bool>> mSuccessful;
26 ::ll::TypedStorage<4, 16, ::std::optional<::Vec3> const> mHit;
27 ::ll::TypedStorage<1, 1, uchar const> mFace;
28 // NOLINTEND
29
30public:
31 // prevent constructor by default
32 BlockPlayerInteractEvent& operator=(BlockPlayerInteractEvent const&);
33 BlockPlayerInteractEvent(BlockPlayerInteractEvent const&);
34 BlockPlayerInteractEvent();
35
36public:
37 // virtual functions
38 // NOLINTBEGIN
39 virtual ::BlockSource const& getBlockSource() const /*override*/;
40 // NOLINTEND
41
42public:
43 // member functions
44 // NOLINTBEGIN
45 MCAPI BlockPlayerInteractEvent(::Player& player, ::BlockPos pos, uchar face, ::std::optional<::Vec3> hit);
46
47 MCAPI void configureRenderParamsForTrigger(::RenderParams& params);
48
49 MCFOLD ::Player const& getPlayer() const;
50
51 MCFOLD ::Player& getPlayerNonConst();
52
53 MCFOLD bool isClientSide() const;
54
55 MCAPI bool isInteractionFailure() const;
56
57 MCAPI bool isInteractionSuccessful() const;
58
59 MCAPI void setInteractionFailure();
60
61 MCAPI void setInteractionResult(bool isSuccessful);
62
63 MCAPI void setInteractionSuccessful();
64
65 MCAPI void setPlayerSelectedItem(::ItemStack& item);
66 // NOLINTEND
67
68public:
69 // constructor thunks
70 // NOLINTBEGIN
71 MCAPI void* $ctor(::Player& player, ::BlockPos pos, uchar face, ::std::optional<::Vec3> hit);
72 // NOLINTEND
73
74public:
75 // virtual function thunks
76 // NOLINTBEGIN
77 MCFOLD ::BlockSource const& $getBlockSource() const;
78
79
80 // NOLINTEND
81
82public:
83 // vftables
84 // NOLINTBEGIN
85 MCNAPI static void** $vftable();
86 // NOLINTEND
87};
88
89} // namespace BlockEvents
Definition BlockEventBase.h:16
Definition BlockPos.h:21
Definition BlockSource.h:73
Definition ItemStack.h:35
Definition Player.h:137
Definition RenderParams.h:30