mirror of
https://github.com/whoahq/whoa.git
synced 2026-02-01 00:02:45 +03:00
feat(component): add CCharacterComponent::ClearItemDisplay
This commit is contained in:
parent
ea51e2e20f
commit
a431b30cf9
@ -654,6 +654,21 @@ void CCharacterComponent::UpdateBaseTexture(EGxTexCommand cmd, uint32_t width, u
|
||||
}
|
||||
}
|
||||
|
||||
void CCharacterComponent::ClearItemDisplay(COMPONENT_SECTIONS section, int32_t priority) {
|
||||
if (priority == -1) {
|
||||
return;
|
||||
}
|
||||
|
||||
if (this->m_itemDisplays[section].texture[priority]) {
|
||||
TextureCacheDestroyTexture(this->m_itemDisplays[section].texture[priority]);
|
||||
this->m_itemDisplays[section].texture[priority] = nullptr;
|
||||
}
|
||||
|
||||
this->m_itemDisplays[section].displayID[priority] = 0;
|
||||
|
||||
this->m_itemDisplays[section].priorityDirty &= ~(1 << priority);
|
||||
}
|
||||
|
||||
void CCharacterComponent::CreateBaseTexture() {
|
||||
auto dataFormat = this->m_textureFormat == GxTex_Dxt1
|
||||
? GxTex_Dxt1
|
||||
|
||||
@ -80,6 +80,7 @@ class CCharacterComponent {
|
||||
ComponentItemDisplay m_itemDisplays[NUM_COMPONENT_SECTIONS] = {};
|
||||
|
||||
// Member functions
|
||||
void ClearItemDisplay(COMPONENT_SECTIONS section, int32_t priority);
|
||||
void CreateBaseTexture();
|
||||
void GeosRenderPrep();
|
||||
CharSectionsRec* GetSectionsRecord(COMPONENT_VARIATIONS sectionIndex, int32_t variationIndex, int32_t colorIndex, bool* found);
|
||||
|
||||
Loading…
Reference in New Issue
Block a user