feat(component): add CCharacterComponent::GetSectionsRecord

This commit is contained in:
fallenoak 2025-10-16 20:15:55 -05:00
parent a694ba173b
commit eb40e5ff01
No known key found for this signature in database
GPG Key ID: 7628F8E61AEA070D
2 changed files with 14 additions and 0 deletions

View File

@ -63,6 +63,18 @@ void CCharacterComponent::GeosRenderPrep() {
this->m_flags &= ~0x4; this->m_flags &= ~0x4;
} }
CharSectionsRec* CCharacterComponent::GetSectionsRecord(COMPONENT_VARIATIONS sectionIndex, int32_t variationIndex, int32_t colorIndex, bool* found) {
return ComponentGetSectionsRecord(
CCharacterComponent::s_chrVarArray,
this->m_data.raceID,
this->m_data.sexID,
sectionIndex,
variationIndex,
colorIndex,
found
);
}
void CCharacterComponent::Init(ComponentData* data, const char* a3) { void CCharacterComponent::Init(ComponentData* data, const char* a3) {
if (data->model) { if (data->model) {
data->model->Release(); data->model->Release();

View File

@ -5,6 +5,7 @@
#include "gx/Texture.hpp" #include "gx/Texture.hpp"
#include <cstdint> #include <cstdint>
class CharSectionsRec;
class CM2Model; class CM2Model;
struct st_race; struct st_race;
@ -65,6 +66,7 @@ class CCharacterComponent {
// Member functions // Member functions
void CreateBaseTexture(); void CreateBaseTexture();
void GeosRenderPrep(); void GeosRenderPrep();
CharSectionsRec* GetSectionsRecord(COMPONENT_VARIATIONS sectionIndex, int32_t variationIndex, int32_t colorIndex, bool* found);
void Init(ComponentData* data, const char* a3); void Init(ComponentData* data, const char* a3);
int32_t ItemsLoaded(int32_t a2); int32_t ItemsLoaded(int32_t a2);
void PrepSections(); void PrepSections();