diff options
Diffstat (limited to 'src/gui')
-rw-r--r-- | src/gui/charcreatedialog.cpp | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/gui/charcreatedialog.cpp b/src/gui/charcreatedialog.cpp index 5dc856da5..33806753d 100644 --- a/src/gui/charcreatedialog.cpp +++ b/src/gui/charcreatedialog.cpp @@ -503,9 +503,10 @@ void CharCreateDialog::setFixedGender(const bool fixed, const Gender gender) void CharCreateDialog::updateHair() { - mHairStyle %= Being::getNumOfHairstyles(); - if (mHairStyle < 0) - mHairStyle += Being::getNumOfHairstyles(); + if (mHairStyle <= 0) + mHairStyle = Being::getNumOfHairstyles() - 1; + else + mHairStyle %= Being::getNumOfHairstyles(); if (mHairStyle < static_cast<signed>(minHairStyle) || mHairStyle > static_cast<signed>(maxHairStyle)) { |