LeviLamina
Loading...
Searching...
No Matches
ScriptBlockEventListener.h
1#pragma once
2
3#include "mc/_HeaderOutputPredefine.h"
4
5// auto generated inclusion list
6#include "mc/world/events/EventListenerDispatcher.h"
7#include "mc/world/events/EventResult.h"
8
9// auto generated forward declare list
10// clang-format off
11class Block;
13class BlockPos;
14class ItemStackBase;
15class Player;
16struct ButtonPushEvent;
18struct LeverActionEvent;
24// clang-format on
25
26namespace ScriptModuleMinecraft {
27
28class ScriptBlockEventListener : public ::EventListenerDispatcher<::BlockEventListener> {
29public:
30 // member variables
31 // NOLINTBEGIN
34 // NOLINTEND
35
36public:
37 // prevent constructor by default
41
42public:
43 // virtual functions
44 // NOLINTBEGIN
45 // vIndex: 22
46 virtual ::EventResult onEvent(::PistonActionEvent const& pistonActionEvent) /*override*/;
47
48 // vIndex: 21
49 virtual ::EventResult onEvent(::LeverActionEvent const& leverActionEvent) /*override*/;
50
51 // vIndex: 20
52 virtual ::EventResult onEvent(::ButtonPushEvent const& buttonPushEvent) /*override*/;
53
54 // vIndex: 19
55 virtual ::EventResult onEvent(::PressurePlatePushEvent const& pressurePlatePushEvent) /*override*/;
56
57 // vIndex: 18
58 virtual ::EventResult onEvent(::PressurePlatePopEvent const& pressurePlatePopEvent) /*override*/;
59
60 // vIndex: 16
61 virtual ::EventResult onEvent(::TripWireTripEvent const& tripWireTripEvent) /*override*/;
62
63 // vIndex: 17
64 virtual ::EventResult onEvent(::TargetBlockHitEvent const& targetBlockHitEvent) /*override*/;
65
66 // vIndex: 13
67 virtual ::EventResult onEvent(::ExplosionStartedEvent const& explosionStartedEvent) /*override*/;
68
69 // vIndex: 1
70 virtual ::EventResult onBlockPlacedByPlayer(
71 ::Player& player,
72 ::Block const& placedBlock,
73 ::BlockPos const& pos,
74 bool isUnderwater
75 ) /*override*/;
76
77 // vIndex: 2
78 virtual ::EventResult onBlockDestroyedByPlayer(
79 ::Player& player,
80 ::Block const& destroyedBlock,
81 ::BlockPos const& pos,
82 ::ItemStackBase const& currentItem,
83 ::ItemStackBase const& itemBeforeBlockBreak
84 ) /*override*/;
85
86 // vIndex: 6
87 virtual ::EventResult onBlockDestructionStarted(
88 ::Player& player,
89 ::BlockPos const& pos,
90 ::Block const& hitBlock,
91 uchar const face
92 ) /*override*/;
93
94 // vIndex: 0
95 virtual ~ScriptBlockEventListener() /*override*/ = default;
96 // NOLINTEND
97
98public:
99 // destructor thunk
100 // NOLINTBEGIN
101
102 // NOLINTEND
103
104public:
105 // virtual function thunks
106 // NOLINTBEGIN
107 MCAPI ::EventResult $onEvent(::PistonActionEvent const& pistonActionEvent);
108
109 MCAPI ::EventResult $onEvent(::LeverActionEvent const& leverActionEvent);
110
111 MCAPI ::EventResult $onEvent(::ButtonPushEvent const& buttonPushEvent);
112
113 MCAPI ::EventResult $onEvent(::PressurePlatePushEvent const& pressurePlatePushEvent);
114
115 MCAPI ::EventResult $onEvent(::PressurePlatePopEvent const& pressurePlatePopEvent);
116
117 MCAPI ::EventResult $onEvent(::TripWireTripEvent const& tripWireTripEvent);
118
119 MCAPI ::EventResult $onEvent(::TargetBlockHitEvent const& targetBlockHitEvent);
120
121 MCAPI ::EventResult $onEvent(::ExplosionStartedEvent const& explosionStartedEvent);
122
123 MCAPI ::EventResult
124 $onBlockPlacedByPlayer(::Player& player, ::Block const& placedBlock, ::BlockPos const& pos, bool isUnderwater);
125
126 MCAPI ::EventResult $onBlockDestroyedByPlayer(
127 ::Player& player,
128 ::Block const& destroyedBlock,
129 ::BlockPos const& pos,
130 ::ItemStackBase const& currentItem,
131 ::ItemStackBase const& itemBeforeBlockBreak
132 );
133
134 MCAPI ::EventResult
135 $onBlockDestructionStarted(::Player& player, ::BlockPos const& pos, ::Block const& hitBlock, uchar const face);
136 // NOLINTEND
137
138public:
139 // vftables
140 // NOLINTBEGIN
141 MCAPI static void** $vftable();
142 // NOLINTEND
143};
144
145} // namespace ScriptModuleMinecraft
Definition BlockEventListener.h:22
Definition BlockPos.h:18
Definition Block.h:36
Definition EventListenerDispatcher.h:6
Definition ItemStackBase.h:35
Definition Player.h:119
Definition ScriptBlockEventListener.h:28
Definition ButtonPushEvent.h:12
Definition ExplosionStartedEvent.h:15
Definition LeverActionEvent.h:12
Definition PistonActionEvent.h:14
Definition PressurePlatePopEvent.h:11
Definition PressurePlatePushEvent.h:12
Definition TargetBlockHitEvent.h:13
Definition TripWireTripEvent.h:12
Definition Alias.h:14