diff options
author | Paul Gilbert | 2015-01-02 11:29:15 -1000 |
---|---|---|
committer | Paul Gilbert | 2015-01-02 11:29:15 -1000 |
commit | bef5dbdc0a8640e3d51af5f1ef9ceb92ab930900 (patch) | |
tree | b668d9bbb8eecd2b0f59dd38a61f868cdcf5bc96 /engines/xeen/saves.h | |
parent | feacce66b92f17c655d70ec2cc233fc63feb517c (diff) | |
download | scummvm-rg350-bef5dbdc0a8640e3d51af5f1ef9ceb92ab930900.tar.gz scummvm-rg350-bef5dbdc0a8640e3d51af5f1ef9ceb92ab930900.tar.bz2 scummvm-rg350-bef5dbdc0a8640e3d51af5f1ef9ceb92ab930900.zip |
XEEN: Replaced conditions array with named field structure
Diffstat (limited to 'engines/xeen/saves.h')
-rw-r--r-- | engines/xeen/saves.h | 27 |
1 files changed, 25 insertions, 2 deletions
diff --git a/engines/xeen/saves.h b/engines/xeen/saves.h index 3d8978e25a..307582505f 100644 --- a/engines/xeen/saves.h +++ b/engines/xeen/saves.h @@ -49,7 +49,7 @@ enum Skill { THIEVERY = 0, ARMS_MASTER = 1, ASTROLOGER = 2, BODYBUILDER = 3, SPOT_DOORS = 16, DANGER_SENSE = 17 }; -enum Condition { CURSED = 0, HEART_BROKEN = 1, WEAK = 2, POISONED = 3, +enum ConditionType { CURSED = 0, HEART_BROKEN = 1, WEAK = 2, POISONED = 3, DISEASED = 4, INSANE = 5, IN_LOVE = 6, DRUNK = 7, SLEEP = 8, DEPRESSED = 9, CONFUSED = 10, PARALYZED = 11 }; @@ -129,6 +129,29 @@ public: void synchronize(Common::Serializer &s); }; +class Conditions { + byte _cursed; + byte _heartBroken; + byte _weak; + byte _poisoned; + byte _diseased; + byte _insane; + byte _inLove; + byte _drunk; + byte _asleep; + byte _depressed; + byte _confused; + byte _paralyzed; + byte _unconscious; + byte _dead; + byte _stoned; + byte _eradicated; +public: + Conditions(); + + void synchronize(Common::Serializer &s); +}; + class PlayerStruct { public: Common::String _name; @@ -166,7 +189,7 @@ public: AttributePair _poisonResistence; AttributePair _energyResistence; AttributePair _magicResistence; - int _conditions[16]; + Conditions _conditions; int _townUnknown; int _unknown2; int _currentHp; |