LeviLamina
Loading...
Searching...
No Matches
SynchedActorData.h
1#pragma once
2
3#include "mc/_HeaderOutputPredefine.h"
4
5// auto generated forward declare list
6// clang-format off
7class Actor;
8class CompoundTag;
9class DataItem;
10class EntityContext;
11class Vec3;
12// clang-format on
13
14class SynchedActorData {
15public:
16 // SynchedActorData inner types declare
17 // clang-format off
18 struct CopyableDataList;
19 // clang-format on
20
21 // SynchedActorData inner types define
22 struct CopyableDataList {
23 public:
24 // member variables
25 // NOLINTBEGIN
26 ::ll::TypedStorage<8, 24, ::std::vector<::std::unique_ptr<::DataItem>>> mData;
27 // NOLINTEND
28
29#ifdef LL_PLAT_S
30#else // LL_PLAT_C
31 public:
32 // prevent constructor by default
33 CopyableDataList& operator=(CopyableDataList const&);
34 CopyableDataList();
35
36#endif
37 public:
38 // member functions
39 // NOLINTBEGIN
40#ifdef LL_PLAT_C
41 MCAPI explicit CopyableDataList(::std::vector<::std::unique_ptr<::DataItem>> const& dataList);
42
43 MCAPI CopyableDataList(::SynchedActorData::CopyableDataList const& other);
44
45 MCAPI ~CopyableDataList();
46#endif
47 // NOLINTEND
48
49 public:
50 // constructor thunks
51 // NOLINTBEGIN
52#ifdef LL_PLAT_C
53 MCFOLD void* $ctor(::std::vector<::std::unique_ptr<::DataItem>> const& dataList);
54
55 MCFOLD void* $ctor(::SynchedActorData::CopyableDataList const& other);
56#endif
57 // NOLINTEND
58
59 public:
60 // destructor thunk
61 // NOLINTBEGIN
62#ifdef LL_PLAT_C
63 MCFOLD void $dtor();
64#endif
65 // NOLINTEND
66 };
67
68 using DataList = ::std::vector<::std::unique_ptr<::DataItem>>;
69
70 using ID = ushort;
71
72 using TypeFloat = float;
73
74 using TypeInt = int;
75
76 using TypeInt64 = int64;
77
78 using TypeInt8 = schar;
79
80 using TypeShort = short;
81
82 using TypeString = ::std::string;
83
84 using TypeVec3 = ::Vec3;
85
86public:
87 template <class T>
88 MCAPI void set(ushort id, T const& value);
89
90public:
91 // member variables
92 // NOLINTBEGIN
93 ::ll::TypedStorage<8, 24, ::std::vector<::std::unique_ptr<::DataItem>>> mItemsArray;
94 ::ll::TypedStorage<8, 24, ::std::bitset<141>> mDirtyFlags;
95 ::ll::TypedStorage<8, 24, ::std::bitset<141>> mHasComponentData;
96 // NOLINTEND
97
98public:
99 // prevent constructor by default
100 SynchedActorData& operator=(SynchedActorData const&);
101 SynchedActorData(SynchedActorData const&);
102
103public:
104 // member functions
105 // NOLINTBEGIN
106 MCAPI SynchedActorData();
107
108 MCAPI SynchedActorData(::SynchedActorData&& rhs);
109
110 MCAPI ::SynchedActorData _clone() const;
111
112 MCAPI ::DataItem* _find(ushort id) const;
113
114 MCAPI ::DataItem& _get(ushort id);
115
116 MCAPI void _resizeToContain(ushort id);
117
118#ifdef LL_PLAT_C
119 MCAPI bool assignValue(::DataItem const& newItem);
120
121 MCAPI void assignValues(
122 ::std::vector<::std::unique_ptr<::DataItem>> const& items,
123 ::Actor& actor,
124 ::std::optional<uint64> targetFrame
125 );
126#endif
127
128 MCAPI ::CompoundTag const& getCompoundTag(ushort id) const;
129
130 MCAPI float getFloat(ushort id) const;
131
132 MCAPI int getInt(ushort id) const;
133
134 MCAPI int64 getInt64(ushort id) const;
135
136 MCAPI schar getInt8(ushort id) const;
137
138 MCAPI short getShort(ushort id) const;
139
140 MCAPI ::std::string const& getString(ushort id) const;
141
142 MCAPI ::Vec3 getVec3(ushort id) const;
143
144 MCAPI bool hasData(ushort id) const;
145
146 MCAPI ::SynchedActorData& operator=(::SynchedActorData&& rhs);
147
148 MCAPI ::std::vector<::std::unique_ptr<::DataItem>> packAll(::EntityContext const& entity) const;
149
150 MCAPI ::std::vector<::std::unique_ptr<::DataItem>> packDirty(::EntityContext& entity);
151
152#ifdef LL_PLAT_C
153 MCAPI void queueAssignment(
154 ::std::vector<::std::unique_ptr<::DataItem>> const& items,
155 ::Actor& actor,
156 ::std::optional<uint64> targetFrame
157 );
158#endif
159
160 MCAPI ~SynchedActorData();
161 // NOLINTEND
162
163public:
164 // static functions
165 // NOLINTBEGIN
166 MCAPI static ::std::vector<::std::unique_ptr<::DataItem>>
167 cloneDataList(::std::vector<::std::unique_ptr<::DataItem>> const& list);
168 // NOLINTEND
169
170public:
171 // static variables
172 // NOLINTBEGIN
173 MCAPI static ::std::string const& DIFF_ITEM_NULL();
174 // NOLINTEND
175
176public:
177 // constructor thunks
178 // NOLINTBEGIN
179 MCFOLD void* $ctor();
180
181 MCAPI void* $ctor(::SynchedActorData&& rhs);
182 // NOLINTEND
183
184public:
185 // destructor thunk
186 // NOLINTBEGIN
187 MCFOLD void $dtor();
188 // NOLINTEND
189};
Definition Actor.h:125
Definition CompoundTag.h:23
Definition DataItem.h:14
Definition EntityContext.h:17
Definition Vec3.h:10
Definition SynchedActorData.h:22