LeviLamina
Loading...
Searching...
No Matches
CameraItemComponentLegacy.h
1#pragma once
2
3#include "mc/_HeaderOutputPredefine.h"
4
5// auto generated inclusion list
6#include "mc/world/item/components/ICameraItemComponent.h"
7
8// auto generated forward declare list
9// clang-format off
10class Actor;
11class BlockPos;
12class CameraCallbacks;
13class CompoundTag;
14class ItemStack;
15class Player;
16class Vec3;
17namespace Json { class Value; }
18// clang-format on
19
21public:
22 // CameraItemComponentLegacy inner types define
23 enum class UseAction : uchar {
24 None = 0,
25 Place = 1,
26 Use = 2,
27 };
28
29 using PlaceCallback = ::std::function<void(::Vec3 const&, ::Player&)>;
30
31 using UseCallback = ::std::function<void(::Player&)>;
32
33public:
34 // member variables
35 // NOLINTBEGIN
36 ::ll::TypedStorage<4, 4, float> mBlackBarsDuration;
37 ::ll::TypedStorage<4, 4, float> mBlackBarsScreenRatio;
38 ::ll::TypedStorage<4, 4, float> mShutterScreenRatio;
39 ::ll::TypedStorage<4, 4, float> mShutterDuration;
40 ::ll::TypedStorage<4, 4, float> mPictureDuration;
41 ::ll::TypedStorage<4, 4, float> mSlideAwayDuration;
42 ::ll::TypedStorage<1, 1, bool> mPlacingTripod;
43 ::ll::TypedStorage<8, 8, uint64> mPlacingTripodClientTick;
44 ::ll::TypedStorage<8, 8, uint64> mPlacingTripodServerTick;
45 ::ll::TypedStorage<8, 8, ::CameraCallbacks*> mCallbacks;
46 // NOLINTEND
47
48public:
49 // virtual functions
50 // NOLINTBEGIN
51 // vIndex: 0
52 virtual ~CameraItemComponentLegacy() /*override*/ = default;
53
54 // vIndex: 8
55 virtual void takePictureNow(::Player& player, ::Actor* camera, ::Actor* target) /*override*/;
56
57 // vIndex: 10
58 virtual void use(::ItemStack& instance, ::Player& player) /*override*/;
59
60 // vIndex: 11
61 virtual void releaseUsing(::ItemStack& instance, ::Player& player, int durationLeft) /*override*/;
62
63 // vIndex: 12
64 virtual bool
65 useOn(::ItemStack& instance, ::Actor& actor, ::BlockPos const& blockPos, uchar face, ::Vec3 const&) /*override*/;
66
67 // vIndex: 7
68 virtual bool canPlace(::ItemStack const& instance, ::Actor& actor, ::BlockPos const& blockPos, uchar face) const
69 /*override*/;
70
71 // vIndex: 1
72 virtual float blackBarsDuration() const /*override*/;
73
74 // vIndex: 2
75 virtual float blackBarsScreenRatio() const /*override*/;
76
77 // vIndex: 3
78 virtual float shutterScreenRatio() const /*override*/;
79
80 // vIndex: 4
81 virtual float shutterDuration() const /*override*/;
82
83 // vIndex: 5
84 virtual float pictureDuration() const /*override*/;
85
86 // vIndex: 6
87 virtual float slideAwayDuration() const /*override*/;
88
89 // vIndex: 9
90 virtual void registerCallbacks(::CameraCallbacks* callbacks) /*override*/;
91 // NOLINTEND
92
93public:
94 // member functions
95 // NOLINTBEGIN
96 MCAPI ::CameraItemComponentLegacy::UseAction _tryPlace(
97 ::ItemStack const& instance,
98 ::Actor& actor,
99 ::BlockPos const& blockPos,
100 uchar face,
101 ::Vec3& spawnPos
102 ) const;
103
104 MCAPI ::std::unique_ptr<::CompoundTag> buildNetworkTag() const;
105 // NOLINTEND
106
107public:
108 // static functions
109 // NOLINTBEGIN
110 MCAPI static ::Json::Value initializeFromNetwork(::CompoundTag const& tag);
111 // NOLINTEND
112
113public:
114 // virtual function thunks
115 // NOLINTBEGIN
116 MCAPI void $takePictureNow(::Player& player, ::Actor* camera, ::Actor* target);
117
118 MCAPI void $use(::ItemStack& instance, ::Player& player);
119
120 MCAPI void $releaseUsing(::ItemStack& instance, ::Player& player, int durationLeft);
121
122 MCAPI bool $useOn(::ItemStack& instance, ::Actor& actor, ::BlockPos const& blockPos, uchar face, ::Vec3 const&);
123
124 MCAPI bool $canPlace(::ItemStack const& instance, ::Actor& actor, ::BlockPos const& blockPos, uchar face) const;
125
126 MCFOLD float $blackBarsDuration() const;
127
128 MCFOLD float $blackBarsScreenRatio() const;
129
130 MCAPI float $shutterScreenRatio() const;
131
132 MCFOLD float $shutterDuration() const;
133
134 MCAPI float $pictureDuration() const;
135
136 MCAPI float $slideAwayDuration() const;
137
138 MCAPI void $registerCallbacks(::CameraCallbacks* callbacks);
139 // NOLINTEND
140
141public:
142 // vftables
143 // NOLINTBEGIN
144 MCNAPI static void** $vftable();
145 // NOLINTEND
146};
Definition Actor.h:102
Definition BlockPos.h:17
Definition CameraCallbacks.h:11
Definition CameraItemComponentLegacy.h:20
static MCAPI void ** $vftable()
Definition CompoundTag.h:13
Definition ICameraItemComponent.h:15
Definition ItemStack.h:23
Definition Player.h:123
Definition Vec3.h:10