LeviLamina
Loading...
Searching...
No Matches
LecternBlock.h
1#pragma once
2
3#include "mc/_HeaderOutputPredefine.h"
4
5// auto generated inclusion list
6#include "mc/world/Direction.h"
7#include "mc/world/level/block/ActorBlockBase.h"
8#include "mc/world/level/block/BlockSupportType.h"
9#include "mc/world/level/block/BlockType.h"
10
11// auto generated forward declare list
12// clang-format off
13class Actor;
14class Block;
15class BlockPos;
16class BlockSource;
17class Player;
18class Vec3;
19namespace BlockEvents { class BlockPlaceEvent; }
20namespace BlockEvents { class BlockPlayerInteractEvent; }
21namespace BlockEvents { class BlockQueuedTickEvent; }
22// clang-format on
23
24class LecternBlock : public ::ActorBlock {
25public:
26 // prevent constructor by default
27 LecternBlock();
28
29public:
30 // virtual functions
31 // NOLINTBEGIN
32 virtual ::Block const&
33 getPlacementBlock(::Actor const& by, ::BlockPos const& pos, uchar face, ::Vec3 const& clickPos, int itemValue) const
34 /*override*/;
35
36 virtual bool isInteractiveBlock() const /*override*/;
37
38 virtual bool canProvideSupport(::Block const& face, uchar, ::BlockSupportType) const /*override*/;
39
40 virtual bool checkIsPathable(::Actor&, ::BlockPos const&, ::BlockPos const&) const /*override*/;
41
42 virtual ::Block const* playerWillDestroy(::Player& player, ::BlockPos const& pos, ::Block const& block) const
43 /*override*/;
44
45 virtual bool attack(::Player* player, ::BlockPos const& pos) const /*override*/;
46
47 virtual bool hasComparatorSignal() const /*override*/;
48
49 virtual int getComparatorSignal(::BlockSource& region, ::BlockPos const& pos, ::Block const&, uchar) const
50 /*override*/;
51
52 virtual bool isSignalSource() const /*override*/;
53
54 virtual void setupRedstoneComponent(::BlockSource& region, ::BlockPos const& pos) const /*override*/;
55
56 virtual bool shouldConnectToRedstone(::BlockSource&, ::BlockPos const&, ::Direction::Type) const /*override*/;
57 // NOLINTEND
58
59public:
60 // member functions
61 // NOLINTBEGIN
62 MCAPI LecternBlock(::std::string const& nameId, int id);
63
64 MCAPI void _updateRedstone(::BlockSource& region, ::BlockPos const& pos, bool powered) const;
65
66 MCAPI void emitRedstonePulse(::BlockSource& region, ::BlockPos const& pos) const;
67
68 MCFOLD void onPlace(::BlockEvents::BlockPlaceEvent& eventData) const;
69
70 MCAPI void tick(::BlockEvents::BlockQueuedTickEvent& eventData) const;
71
72 MCAPI void use(::BlockEvents::BlockPlayerInteractEvent& eventData) const;
73 // NOLINTEND
74
75public:
76 // constructor thunks
77 // NOLINTBEGIN
78 MCAPI void* $ctor(::std::string const& nameId, int id);
79 // NOLINTEND
80
81public:
82 // virtual function thunks
83 // NOLINTBEGIN
84 MCAPI ::Block const& $getPlacementBlock(
85 ::Actor const& by,
86 ::BlockPos const& pos,
87 uchar face,
88 ::Vec3 const& clickPos,
89 int itemValue
90 ) const;
91
92 MCFOLD bool $isInteractiveBlock() const;
93
94 MCFOLD bool $canProvideSupport(::Block const& face, uchar, ::BlockSupportType) const;
95
96 MCFOLD bool $checkIsPathable(::Actor&, ::BlockPos const&, ::BlockPos const&) const;
97
98 MCAPI ::Block const* $playerWillDestroy(::Player& player, ::BlockPos const& pos, ::Block const& block) const;
99
100 MCAPI bool $attack(::Player* player, ::BlockPos const& pos) const;
101
102 MCFOLD bool $hasComparatorSignal() const;
103
104 MCAPI int $getComparatorSignal(::BlockSource& region, ::BlockPos const& pos, ::Block const&, uchar) const;
105
106 MCFOLD bool $isSignalSource() const;
107
108 MCAPI void $setupRedstoneComponent(::BlockSource& region, ::BlockPos const& pos) const;
109
110 MCFOLD bool $shouldConnectToRedstone(::BlockSource&, ::BlockPos const&, ::Direction::Type) const;
111
112
113 // NOLINTEND
114
115public:
116 // vftables
117 // NOLINTBEGIN
118 MCAPI static void** $vftable();
119 // NOLINTEND
120};
Definition Actor.h:125
Definition BlockPlaceEvent.h:18
Definition BlockPlayerInteractEvent.h:20
Definition BlockQueuedTickEvent.h:18
Definition BlockPos.h:21
Definition BlockSource.h:73
Definition Block.h:69
Definition Player.h:137
Definition Vec3.h:10