feat(glue): partially implement CCharacterComponent::RenderPrep

This commit is contained in:
fallenoak 2025-10-14 08:36:07 -05:00
parent 88b93b89af
commit 4dd9dfbd78
No known key found for this signature in database
GPG Key ID: 7628F8E61AEA070D
2 changed files with 24 additions and 0 deletions

View File

@ -7,6 +7,20 @@ CCharacterComponent* CCharacterComponent::AllocComponent() {
return STORM_NEW(CCharacterComponent);
}
void CCharacterComponent::GeosRenderPrep() {
// TODO
// Default all sections (0 - 2000) to hidden
this->m_data.model->SetGeometryVisible(0, 2000, 0);
// Show base "skin" section (0)
this->m_data.model->SetGeometryVisible(0, 0, 1);
// TODO
this->m_flags &= ~0x4;
}
void CCharacterComponent::Init(ComponentData* data, const char* a3) {
if (data->model) {
data->model->Release();
@ -18,5 +32,13 @@ void CCharacterComponent::Init(ComponentData* data, const char* a3) {
}
void CCharacterComponent::RenderPrep(int32_t a2) {
if (this->m_data.flags & 0x1) {
if (this->m_flags & 0x4) {
this->GeosRenderPrep();
}
return;
}
// TODO
}

View File

@ -25,9 +25,11 @@ class CCharacterComponent {
static CCharacterComponent* AllocComponent();
// Member variables
uint32_t m_flags = 0x1 | 0x2 | 0x4;
ComponentData m_data;
// Member functions
void GeosRenderPrep();
void Init(ComponentData* data, const char* a3);
void RenderPrep(int32_t a2);
};