Usage: Apply this patch to wowmodelviewer/src folder.

Index: charcontrol.cpp
===================================================================
--- charcontrol.cpp (revision 687)
+++ charcontrol.cpp (working copy)
@@ -896,19 +896,19 @@
// select hairstyle geoset(s)
for (CharHairGeosetsDB::Iterator it = hairdb.begin(); it != hairdb.end(); ++it) {
- if (it->getUInt(CharHairGeosetsDB::Race)==cd.race && it->getUInt(CharHairGeosetsDB::Gender)==cd.gender) {
- unsigned int id = it->getUInt(CharHairGeosetsDB::Geoset);
- unsigned int section = it->getUInt(CharHairGeosetsDB::Section);
+ if (it->getUInt(CharHairGeosetsDB::Race)==cd.race &&
+ it->getUInt(CharHairGeosetsDB::Gender)==cd.gender &&
+ it->getUInt(CharHairGeosetsDB::Section)==cd.hairStyle)
+ {
+ unsigned int geosetId = it->getUInt(CharHairGeosetsDB::Geoset);
+ bald = it->getUInt(CharHairGeosetsDB::Bald) != 0;
- if (id!=0) {
- for (size_t j=0; j<model->geosets.size(); j++) {
- if (model->geosets[j].id == id)
- model->showGeosets[j] = ((cd.hairStyle == section) && showHair);
- }
-
- } else if (cd.hairStyle==section) {
- bald = true;
- }
+ for (size_t j=0; j<model->geosets.size(); j++) {
+ if (model->geosets[j].id == geosetId)
+ model->showGeosets[j] = showHair;
+ else if (model->geosets[j].id >= 1 && model->geosets[j].id <= cd.maxHairStyle)
+ model->showGeosets[j] = false;
+ }
}
}
#if 0 // for worgen female
Index: database.h
===================================================================
--- database.h (revision 687)
+++ database.h (working copy)
@@ -193,8 +193,8 @@
static const size_t Race = 1; // uint
static const size_t Gender = 2; // uint, 0 = Male, 1 = Female
static const size_t Section = 3; // uint, ID unique between race, and gender.
- static const size_t Geoset = 4; // uint, Defines hairstyle, each number should be unique for that race / gender combo.
- //static const size_t Bald = 5; // uint, If this hairstyle bald or not .
+ static const size_t Geoset = 5; // uint, Defines hairstyle, each number should be unique for that race / gender combo.
+ static const size_t Bald = 7;
Record getByParams(unsigned int race, unsigned int gender, unsigned int section);
int getGeosetsFor(unsigned int race, unsigned int gender);










