mirror of
https://github.com/Kelsidavis/WoWee.git
synced 2026-03-22 23:30:14 +00:00
Fix NPC hair/geoset rendering using DBC lookups
Use CharHairGeosets.dbc to map (race, sex, hairStyleId) to the correct group 0 scalp mesh instead of the broken 101+hairStyleId formula. Filter group 0 submeshes so only the body base and correct hair mesh render (prevents overlapping scalp variants). Fix ItemDisplayInfo.dbc column indices (5→7) and geoset formulas for equipment. Add CharSections.dbc hair texture lookup and CharacterFacialHairStyles.dbc support.
This commit is contained in:
parent
4c77f7ee7b
commit
e8fecfb3be
4 changed files with 162 additions and 41 deletions
|
|
@ -146,6 +146,11 @@ private:
|
|||
std::unordered_map<uint32_t, CreatureDisplayData> displayDataMap_; // displayId → display data
|
||||
std::unordered_map<uint32_t, HumanoidDisplayExtra> humanoidExtraMap_; // extraDisplayId → humanoid data
|
||||
std::unordered_map<uint32_t, std::string> modelIdToPath_; // modelId → M2 path (from CreatureModelData.dbc)
|
||||
// CharHairGeosets.dbc: key = (raceId<<16)|(sexId<<8)|variationId → geosetId (skinSectionId)
|
||||
std::unordered_map<uint32_t, uint16_t> hairGeosetMap_;
|
||||
// CharFacialHairStyles.dbc: key = (raceId<<16)|(sexId<<8)|variationId → {geoset100, geoset300, geoset200}
|
||||
struct FacialHairGeosets { uint16_t geoset100 = 0; uint16_t geoset300 = 0; uint16_t geoset200 = 0; };
|
||||
std::unordered_map<uint32_t, FacialHairGeosets> facialHairGeosetMap_;
|
||||
std::unordered_map<uint64_t, uint32_t> creatureInstances_; // guid → render instanceId
|
||||
std::unordered_map<uint64_t, uint32_t> creatureModelIds_; // guid → loaded modelId
|
||||
uint32_t nextCreatureModelId_ = 5000; // Model IDs for online creatures
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue