LeviLamina
Loading...
Searching...
No Matches
EffectCommand.h
1#pragma once
2
3#include "mc/_HeaderOutputPredefine.h"
4
5// auto generated inclusion list
6#include "mc/server/commands/Command.h"
7#include "mc/server/commands/CommandSelector.h"
8#include "mc/server/commands/CommandSelectorResults.h"
9
10// auto generated forward declare list
11// clang-format off
12class Actor;
13class CommandOrigin;
14class CommandOutput;
15class CommandRegistry;
16class MobEffect;
17struct EffectDuration;
18// clang-format on
19
20class EffectCommand : public ::Command {
21public:
22 // EffectCommand inner types define
23 enum class Mode : int {
24 Add = 0,
25 Clear = 1,
26 AddInfinite = 2,
27 };
28
29public:
30 // member variables
31 // NOLINTBEGIN
32 ::ll::TypedStorage<8, 200, ::CommandSelector<::Actor>> mTargets;
33 ::ll::TypedStorage<4, 4, ::EffectCommand::Mode> mMode;
34 ::ll::TypedStorage<8, 8, ::MobEffect const*> mEffect;
35 ::ll::TypedStorage<4, 4, int> mDuration;
36 ::ll::TypedStorage<4, 4, int> mAmplifier;
37 ::ll::TypedStorage<1, 1, bool> mHideParticles;
38 // NOLINTEND
39
40public:
41 // virtual functions
42 // NOLINTBEGIN
43 virtual void execute(::CommandOrigin const& origin, ::CommandOutput& output) const /*override*/;
44
45 virtual ~EffectCommand() /*override*/ = default;
46 // NOLINTEND
47
48public:
49 // member functions
50 // NOLINTBEGIN
51 MCAPI void
52 _add(::CommandSelectorResults<::Actor>& targets, ::CommandOutput& output, ::EffectDuration duration) const;
53
54#ifdef LL_PLAT_C
55 MCAPI bool _checkIsValidAmplifierRange(::CommandOutput& output) const;
56#endif
57
58 MCAPI void _clearAllEffects(::CommandSelectorResults<::Actor>& targets, ::CommandOutput& output) const;
59
60 MCAPI void _clearEffect(
62 ::CommandOutput& output,
63 ::MobEffect const& effect,
64 bool throwsErrorOnNoEffect
65 ) const;
66 // NOLINTEND
67
68public:
69 // static functions
70 // NOLINTBEGIN
71 MCAPI static void setup(::CommandRegistry& registry);
72 // NOLINTEND
73
74public:
75 // virtual function thunks
76 // NOLINTBEGIN
77 MCAPI void $execute(::CommandOrigin const& origin, ::CommandOutput& output) const;
78
79
80 // NOLINTEND
81
82public:
83 // vftables
84 // NOLINTBEGIN
85 MCNAPI static void** $vftable();
86 // NOLINTEND
87};
Definition Actor.h:106
Definition CommandOrigin.h:32
Definition CommandOutput.h:19
Definition CommandRegistry.h:50
Definition CommandSelectorResults.h:6
Definition Command.h:17
Definition EffectCommand.h:20
static MCAPI void ** $vftable()
Definition MobEffect.h:27
Definition EffectDuration.h:5