Skip to content

Commit

Permalink
KOTOR2: Add skin and face getter and setter for chargen info
Browse files Browse the repository at this point in the history
  • Loading branch information
Nostritius committed May 9, 2018
1 parent a37d980 commit 1926c27
Show file tree
Hide file tree
Showing 2 changed files with 26 additions and 0 deletions.
16 changes: 16 additions & 0 deletions src/engines/kotor2/gui/chargen/chargeninfo.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -130,6 +130,14 @@ CharacterGenerationInfo *CharacterGenerationInfo::createRandomFemaleSentinel() {
CharacterGenerationInfo::CharacterGenerationInfo() {
}

Skin CharacterGenerationInfo::getSkin() const {
return _skin;
}

unsigned int CharacterGenerationInfo::getFace() const {
return _face;
}

Gender CharacterGenerationInfo::getGender() const {
return _gender;
}
Expand All @@ -138,6 +146,14 @@ Class CharacterGenerationInfo::getClass() const {
return _class;
}

void CharacterGenerationInfo::setSkin(Skin skin) {
_skin = skin;
}

void CharacterGenerationInfo::setFace(unsigned int face) {
_face = face;
}

Common::UString CharacterGenerationInfo::getPortrait() const {
Common::UString portrait;
portrait += "po_p";
Expand Down
10 changes: 10 additions & 0 deletions src/engines/kotor2/gui/chargen/chargeninfo.h
Original file line number Diff line number Diff line change
Expand Up @@ -40,10 +40,20 @@ class CharacterGenerationInfo {
static CharacterGenerationInfo *createRandomMaleSentinel();
static CharacterGenerationInfo *createRandomFemaleSentinel();

/** Get the skin type of the character. */
Skin getSkin() const;
/** Get the current face index of the character. */
unsigned int getFace() const;

Gender getGender() const;

Class getClass() const;

/** Set the skin type of the Character. */
void setSkin(Skin skin);
/** Set the face index of the character. */
void setFace(unsigned int face);

Common::UString getPortrait() const;

private:
Expand Down

0 comments on commit 1926c27

Please sign in to comment.