mirror of
https://github.com/whoahq/whoa.git
synced 2026-11-07 15:19:53 +03:00
feat(component): add CCharacterComponent::ClearItemDisplay
This commit is contained in:
2 files changed
+16
No files matched your search
@@ -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);
|
||||
|
||||
Reference in new issue
Block a user