Skip to content
LeviMC
English
AutoLightDark
LeviLamina
Loading...
Searching...
No Matches
CrafterBlock.h
1#pragma once
2
3#include "mc/_HeaderOutputPredefine.h"
4
5// auto generated inclusion list
6#include "mc/world/Flip.h"
7#include "mc/world/level/block/ActorBlockBase.h"
8#include "mc/world/level/block/BlockType.h"
9
10// auto generated forward declare list
11// clang-format off
12class Actor;
13class Block;
14class BlockPos;
15class BlockSource;
16class Vec3;
17namespace BlockEvents { class BlockPlayerInteractEvent; }
18namespace BlockEvents { class BlockQueuedTickEvent; }
19namespace BlockEvents { class BlockRedstoneUpdateEvent; }
20// clang-format on
21
22class CrafterBlock : public ::ActorBlock {
23public:
24 // virtual functions
25 // NOLINTBEGIN
26 virtual int getVariant(::Block const& block) const /*override*/;
27
28 virtual ::Block const&
29 getPlacementBlock(::Actor const& by, ::BlockPos const& pos, uchar face, ::Vec3 const& clickPos, int itemValue) const
30 /*override*/;
31
32 virtual void onRemove(::BlockSource& region, ::BlockPos const& pos) const /*override*/;
33
34 virtual bool isInteractiveBlock() const /*override*/;
35
36 virtual bool isContainerBlock() const /*override*/;
37
38 virtual bool hasComparatorSignal() const /*override*/;
39
40 virtual int getComparatorSignal(::BlockSource& region, ::BlockPos const& pos, ::Block const& block, uchar dir) const
41 /*override*/;
42
43 virtual ::Block const& getRenderBlock() const /*override*/;
44
45 virtual uchar getMappedFace(uchar face, ::Block const& block) const /*override*/;
46
47 virtual ::Flip getFaceFlip(uchar face, ::Block const& block) const /*override*/;
48
49 virtual bool allowStateMismatchOnPlacement(::Block const& clientTarget, ::Block const& serverTarget) const
50 /*override*/;
51 // NOLINTEND
52
53public:
54 // member functions
55 // NOLINTBEGIN
57
58 MCAPI void tick(::BlockEvents::BlockQueuedTickEvent& eventData) const;
59
60 MCNAPI void use(::BlockEvents::BlockPlayerInteractEvent& eventData) const;
61 // NOLINTEND
62
63public:
64 // virtual function thunks
65 // NOLINTBEGIN
66 MCNAPI int $getVariant(::Block const& block) const;
67
68 MCNAPI ::Block const& $getPlacementBlock(
69 ::Actor const& by,
70 ::BlockPos const& pos,
71 uchar face,
72 ::Vec3 const& clickPos,
73 int itemValue
74 ) const;
75
76 MCNAPI void $onRemove(::BlockSource& region, ::BlockPos const& pos) const;
77
78 MCNAPI bool $isInteractiveBlock() const;
79
80 MCNAPI bool $isContainerBlock() const;
81
82 MCNAPI bool $hasComparatorSignal() const;
83
84 MCNAPI int
85 $getComparatorSignal(::BlockSource& region, ::BlockPos const& pos, ::Block const& block, uchar dir) const;
86
87 MCNAPI ::Block const& $getRenderBlock() const;
88
89 MCNAPI uchar $getMappedFace(uchar face, ::Block const& block) const;
90
91 MCNAPI ::Flip $getFaceFlip(uchar face, ::Block const& block) const;
92
93 MCNAPI bool $allowStateMismatchOnPlacement(::Block const& clientTarget, ::Block const& serverTarget) const;
94
95
96 // NOLINTEND
97
98public:
99 // vftables
100 // NOLINTBEGIN
101 MCNAPI static void** $vftable();
102 // NOLINTEND
103};
Definition Actor.h:116
Definition BlockPlayerInteractEvent.h:18
Definition BlockQueuedTickEvent.h:16
Definition BlockRedstoneUpdateEvent.h:15
Definition BlockPos.h:14
Definition BlockSource.h:72
Definition Block.h:42
Definition CrafterBlock.h:22
MCAPI void use(::BlockEvents::BlockPlayerInteractEvent &eventData) const
MCAPI bool $isContainerBlock() const
MCAPI bool $hasComparatorSignal() const
MCAPI void _onRedstoneUpdate(::BlockEvents::BlockRedstoneUpdateEvent &blockEvent) const
MCAPI int $getComparatorSignal(::BlockSource &region, ::BlockPos const &pos, ::Block const &block, uchar dir) const
static MCAPI void ** $vftable()
MCAPI int $getVariant(::Block const &block) const
MCAPI bool $isInteractiveBlock() const
MCAPI bool $allowStateMismatchOnPlacement(::Block const &clientTarget, ::Block const &serverTarget) const
MCAPI::Block const & $getPlacementBlock(::Actor const &by, ::BlockPos const &pos, uchar face, ::Vec3 const &clickPos, int itemValue) const
MCAPI::Block const & $getRenderBlock() const
MCAPI::Flip $getFaceFlip(uchar face, ::Block const &block) const
MCAPI void $onRemove(::BlockSource &region, ::BlockPos const &pos) const
MCAPI uchar $getMappedFace(uchar face, ::Block const &block) const
Definition Vec3.h:10