Skip to content
LeviMC
English
AutoLightDark
LeviLamina
Loading...
Searching...
No Matches
Model.h
1#pragma once
2
3#include "mc/_HeaderOutputPredefine.h"
4
5// auto generated inclusion list
6#include "mc/deps/application/AppPlatformListener.h"
7#include "mc/deps/core/math/Vec3.h"
8#include "mc/deps/core/string/HashedString.h"
9#include "mc/deps/minecraft_renderer/renderer/MaterialVariants.h"
10#include "mc/world/phys/AABB.h"
11
12// auto generated forward declare list
13// clang-format off
14class Actor;
18class ExpressionNode;
19class Mob;
20class ModelPart;
23class RenderParams;
24class ScreenContext;
25struct ActorTextureInfo;
26struct MERSUniformData;
27namespace dragon { struct RenderMetadata; }
28namespace mce { struct ClientTexture; }
29// clang-format on
30
31class Model : public ::AppPlatformListener {
32public:
33 // member variables
34 // NOLINTBEGIN
35 ::ll::TypedStorage<4, 12, ::Vec3> mLeashOffset;
36 ::ll::TypedStorage<4, 4, float> mAttackTime;
37 ::ll::TypedStorage<1, 1, bool> mYoung;
38 ::ll::TypedStorage<1, 1, bool> mRiding;
39 ::ll::TypedStorage<8, 24, ::std::vector<::ModelPart*>> mAllParts;
40 ::ll::TypedStorage<8, 64, ::std::unordered_map<::HashedString, ::HashedString>> mParticleEffectsMap;
41 ::ll::TypedStorage<8, 64, ::std::unordered_map<::HashedString, ::ModelPartLocator>> mLocators;
42 ::ll::TypedStorage<8, 24, ::std::vector<::std::pair<::std::shared_ptr<::RenderController>, ::ExpressionNode>>>
43 mRenderControllers;
44 ::ll::TypedStorage<8, 24, ::std::vector<::std::shared_ptr<::DataDrivenGeometry>>> mGeometries;
45 ::ll::TypedStorage<8, 8, uint64> mQueryableGeometryIndex;
46 ::ll::TypedStorage<4, 24, ::AABB> mAABB;
47 ::ll::TypedStorage<8, 32, ::MaterialVariants> mMaterialVariants;
48 // NOLINTEND
49
50public:
51 // virtual functions
52 // NOLINTBEGIN
53 virtual ~Model() /*override*/;
54
55 virtual void clear();
56
57 virtual void onAppSuspended() /*override*/;
58
59 virtual void preDraw(::ScreenContext&);
60
61 virtual void postDraw(::ScreenContext&);
62
63 virtual void render(::ScreenContext& screenContext);
64
65 virtual void render(
66 ::ScreenContext& screenContext,
67 ::Actor& e,
68 float time,
69 float r,
70 float bob,
71 float yRot,
72 float xRot,
73 float scale
74 );
75
76 virtual void render(::BaseActorRenderContext&);
77
78 virtual void
79 render(::BaseActorRenderContext& baseActorRenderContext, ::Actor&, float, float, float, float, float, float);
80
81 virtual void setupAnim(float time, float r, float bob, float yRot, float xRot, float scale);
82
83 virtual void setupAnim();
84
85 virtual void prepareMobModel(::Mob&, float, float, float);
86
87 virtual float getHeightAdjustment() const;
88
89 virtual ::AABB buildAABB() const;
90 // NOLINTEND
91
92public:
93 // member functions
94 // NOLINTBEGIN
95 MCNAPI Model();
96
97 MCNAPI void assignPartToGroup(
98 ::ModelPart& part,
99 bool forceToUniqueGroup,
100 int skinnedMeshGroupIdentifier,
101 ::DataDrivenGeometry* owningGeometry
102 );
103
104 MCNAPI void dataDrivenDraw(
105 ::RenderParams& renderParams,
106 ::dragon::RenderMetadata const& renderMetadata,
107 ::gsl::not_null<::RenderController const*> renderController,
109 ::ClientPBRTextureData const& textureData,
110 ::std::optional<::MERSUniformData> const& mersUniforms
111 );
112
113 MCNAPI void draw(
114 ::ScreenContext& screenContext,
115 ::dragon::RenderMetadata const& renderMetadata,
116 ::mce::ClientTexture const& texture
117 );
118
119 MCNAPI void draw(
120 ::ScreenContext& screenContext,
121 ::dragon::RenderMetadata const& renderMetadata,
122 ::ActorTextureInfo const& textureInfo
123 );
124 // NOLINTEND
125
126public:
127 // constructor thunks
128 // NOLINTBEGIN
129 MCNAPI void* $ctor();
130 // NOLINTEND
131
132public:
133 // destructor thunk
134 // NOLINTBEGIN
135 MCNAPI void $dtor();
136 // NOLINTEND
137
138public:
139 // virtual function thunks
140 // NOLINTBEGIN
141 MCNAPI void $clear();
142
143 MCNAPI void $onAppSuspended();
144
146
148
149 MCNAPI void $render(::ScreenContext& screenContext);
150
151 MCNAPI void $render(
152 ::ScreenContext& screenContext,
153 ::Actor& e,
154 float time,
155 float r,
156 float bob,
157 float yRot,
158 float xRot,
159 float scale
160 );
161
163
164 MCNAPI void
165 $render(::BaseActorRenderContext& baseActorRenderContext, ::Actor&, float, float, float, float, float, float);
166
167 MCNAPI void $setupAnim(float time, float r, float bob, float yRot, float xRot, float scale);
168
169 MCNAPI void $setupAnim();
170
171 MCNAPI void $prepareMobModel(::Mob&, float, float, float);
172
173 MCNAPI float $getHeightAdjustment() const;
174
175 MCNAPI ::AABB $buildAABB() const;
176 // NOLINTEND
177
178public:
179 // vftables
180 // NOLINTBEGIN
181 MCNAPI static void** $vftable();
182 // NOLINTEND
183};
Definition Actor.h:116
Definition AppPlatformListener.h:16
Definition BaseActorRenderContext.h:5
Definition ClientPBRTextureData.h:5
Definition DataDrivenGeometry.h:5
Definition ExpressionNode.h:35
Definition Mob.h:58
Definition ModelPartLocator.h:11
Definition ModelPart.h:5
Definition Model.h:5
MCAPI void $render(::BaseActorRenderContext &)
MCAPI void $setupAnim(float time, float r, float bob, float yRot, float xRot, float scale)
MCAPI void dataDrivenDraw(::RenderParams &renderParams, ::dragon::RenderMetadata const &renderMetadata, ::gsl::not_null<::RenderController const * > renderController, ::DataDrivenGeometry &geo, ::ClientPBRTextureData const &textureData, ::std::optional<::MERSUniformData > const &mersUniforms)
MCAPI void $preDraw(::ScreenContext &)
MCAPI float $getHeightAdjustment() const
MCAPI void * $ctor()
MCAPI void $onAppSuspended()
MCAPI void $render(::ScreenContext &screenContext)
MCAPI void draw(::ScreenContext &screenContext, ::dragon::RenderMetadata const &renderMetadata, ::mce::ClientTexture const &texture)
MCAPI void $prepareMobModel(::Mob &, float, float, float)
MCAPI void $dtor()
MCAPI void draw(::ScreenContext &screenContext, ::dragon::RenderMetadata const &renderMetadata, ::ActorTextureInfo const &textureInfo)
MCAPI void $postDraw(::ScreenContext &)
MCAPI void $render(::ScreenContext &screenContext, ::Actor &e, float time, float r, float bob, float yRot, float xRot, float scale)
MCAPI void $clear()
MCAPI Model()
MCAPI void $setupAnim()
MCAPI::AABB $buildAABB() const
MCAPI void $render(::BaseActorRenderContext &baseActorRenderContext, ::Actor &, float, float, float, float, float, float)
static MCAPI void ** $vftable()
MCAPI void assignPartToGroup(::ModelPart &part, bool forceToUniqueGroup, int skinnedMeshGroupIdentifier, ::DataDrivenGeometry *owningGeometry)
Definition RenderController.h:5
Definition RenderParams.h:29
Definition ScreenContext.h:5
Definition ActorTextureInfo.h:5
Definition MERSUniformData.h:5
Definition RenderMetadata.h:7
Definition ClientTexture.h:7