diff options
Diffstat (limited to 'engines')
-rw-r--r-- | engines/xeen/dialogs.cpp | 11 | ||||
-rw-r--r-- | engines/xeen/dialogs.h | 5 | ||||
-rw-r--r-- | engines/xeen/dialogs_dismiss.cpp | 8 | ||||
-rw-r--r-- | engines/xeen/dialogs_exchange.cpp | 10 | ||||
-rw-r--r-- | engines/xeen/dialogs_items.cpp | 54 | ||||
-rw-r--r-- | engines/xeen/dialogs_options.cpp | 16 | ||||
-rw-r--r-- | engines/xeen/dialogs_party.cpp | 18 | ||||
-rw-r--r-- | engines/xeen/dialogs_spells.cpp | 6 | ||||
-rw-r--r-- | engines/xeen/interface.cpp | 8 | ||||
-rw-r--r-- | engines/xeen/resources.cpp | 12 | ||||
-rw-r--r-- | engines/xeen/resources.h | 2 | ||||
-rw-r--r-- | engines/xeen/town.cpp | 46 |
12 files changed, 94 insertions, 102 deletions
diff --git a/engines/xeen/dialogs.cpp b/engines/xeen/dialogs.cpp index 8bb0af0833..116054dfe7 100644 --- a/engines/xeen/dialogs.cpp +++ b/engines/xeen/dialogs.cpp @@ -47,14 +47,19 @@ void ButtonContainer::restoreButtons() { _buttons = _savedButtons.pop(); } -void ButtonContainer::addButton(const Common::Rect &bounds, int val, SpriteResource *sprites, bool draw) { - _buttons.push_back(UIButton(bounds, val, sprites, draw)); +void ButtonContainer::addButton(const Common::Rect &bounds, int val, + SpriteResource *sprites) { + _buttons.push_back(UIButton(bounds, val, sprites, true)); +} + +void ButtonContainer::addButton(const Common::Rect &bounds, int val) { + _buttons.push_back(UIButton(bounds, val, nullptr, false)); } void ButtonContainer::addPartyButtons(XeenEngine *vm) { for (uint idx = 0; idx < MAX_ACTIVE_PARTY; ++idx) { addButton(Common::Rect(CHAR_FACES_X[idx], 150, CHAR_FACES_X[idx] + 32, 182), - Common::KEYCODE_F1 + idx, nullptr, false); + Common::KEYCODE_F1 + idx); } } diff --git a/engines/xeen/dialogs.h b/engines/xeen/dialogs.h index 02e945b665..e2d8bc929c 100644 --- a/engines/xeen/dialogs.h +++ b/engines/xeen/dialogs.h @@ -66,8 +66,9 @@ public: void restoreButtons(); - void addButton(const Common::Rect &bounds, int val, - SpriteResource *sprites = nullptr, bool draw = true); + void addButton(const Common::Rect &bounds, int val, SpriteResource *sprites); + + void addButton(const Common::Rect &bounds, int val); void addPartyButtons(XeenEngine *vm); }; diff --git a/engines/xeen/dialogs_dismiss.cpp b/engines/xeen/dialogs_dismiss.cpp index 0c28affa6c..1317d84447 100644 --- a/engines/xeen/dialogs_dismiss.cpp +++ b/engines/xeen/dialogs_dismiss.cpp @@ -88,10 +88,10 @@ void Dismiss::execute() { void Dismiss::loadButtons() { _iconSprites.load("esc.icn"); addButton(Common::Rect(225, 120, 249, 140), Common::KEYCODE_ESCAPE, &_iconSprites); - addButton(Common::Rect(16, 16, 48, 48), Common::KEYCODE_1, &_iconSprites, false); - addButton(Common::Rect(117, 16, 149, 48), Common::KEYCODE_2, &_iconSprites, false); - addButton(Common::Rect(16, 59, 48, 91), Common::KEYCODE_3, &_iconSprites, false); - addButton(Common::Rect(117, 59, 149, 91), Common::KEYCODE_4, &_iconSprites, false); + addButton(Common::Rect(16, 16, 48, 48), Common::KEYCODE_1); + addButton(Common::Rect(117, 16, 149, 48), Common::KEYCODE_2); + addButton(Common::Rect(16, 59, 48, 91), Common::KEYCODE_3); + addButton(Common::Rect(117, 59, 149, 91), Common::KEYCODE_4); } } // End of namespace Xeen diff --git a/engines/xeen/dialogs_exchange.cpp b/engines/xeen/dialogs_exchange.cpp index 0b1e538b38..37da4e0963 100644 --- a/engines/xeen/dialogs_exchange.cpp +++ b/engines/xeen/dialogs_exchange.cpp @@ -70,11 +70,11 @@ void ExchangeDialog::execute(Character *&c, int &charIndex) { void ExchangeDialog::loadButtons() { _iconSprites.load("esc.icn"); - addButton(Common::Rect(225, 120, 249, 245), Common::KEYCODE_ESCAPE, &_iconSprites, true); - addButton(Common::Rect(16, 16, 48, 48), Common::KEYCODE_1, &_iconSprites, false); - addButton(Common::Rect(117, 16, 149, 48), Common::KEYCODE_2, &_iconSprites, false); - addButton(Common::Rect(16, 59, 48, 91), Common::KEYCODE_3, &_iconSprites, false); - addButton(Common::Rect(117, 59, 149, 91), Common::KEYCODE_4, &_iconSprites, false); + addButton(Common::Rect(225, 120, 249, 245), Common::KEYCODE_ESCAPE, &_iconSprites); + addButton(Common::Rect(16, 16, 48, 48), Common::KEYCODE_1); + addButton(Common::Rect(117, 16, 149, 48), Common::KEYCODE_2); + addButton(Common::Rect(16, 59, 48, 91), Common::KEYCODE_3); + addButton(Common::Rect(117, 59, 149, 91), Common::KEYCODE_4); } } // End of namespace Xeen diff --git a/engines/xeen/dialogs_items.cpp b/engines/xeen/dialogs_items.cpp index f8131db0f1..21a8856e3c 100644 --- a/engines/xeen/dialogs_items.cpp +++ b/engines/xeen/dialogs_items.cpp @@ -530,15 +530,15 @@ void ItemsDialog::loadButtons(ItemsMode mode, Character *&c) { addButton(Common::Rect(148, 109, 172, 129), Common::KEYCODE_e, &_iconSprites); addButton(Common::Rect(284, 109, 308, 129), Common::KEYCODE_ESCAPE, &_iconSprites); addButton(Common::Rect(148, 109, 172, 129), Common::KEYCODE_u, &_iconSprites); - addButton(Common::Rect(8, 20, 263, 28), Common::KEYCODE_1, &_iconSprites, false); - addButton(Common::Rect(8, 29, 263, 37), Common::KEYCODE_2, &_iconSprites, false); - addButton(Common::Rect(8, 38, 263, 46), Common::KEYCODE_3, &_iconSprites, false); - addButton(Common::Rect(8, 47, 263, 55), Common::KEYCODE_4, &_iconSprites, false); - addButton(Common::Rect(8, 56, 263, 64), Common::KEYCODE_5, &_iconSprites, false); - addButton(Common::Rect(8, 65, 263, 73), Common::KEYCODE_6, &_iconSprites, false); - addButton(Common::Rect(8, 74, 263, 82), Common::KEYCODE_7, &_iconSprites, false); - addButton(Common::Rect(8, 83, 263, 91), Common::KEYCODE_8, &_iconSprites, false); - addButton(Common::Rect(8, 92, 263, 100), Common::KEYCODE_9, &_iconSprites, false); + addButton(Common::Rect(8, 20, 263, 28), Common::KEYCODE_1); + addButton(Common::Rect(8, 29, 263, 37), Common::KEYCODE_2); + addButton(Common::Rect(8, 38, 263, 46), Common::KEYCODE_3); + addButton(Common::Rect(8, 47, 263, 55), Common::KEYCODE_4); + addButton(Common::Rect(8, 56, 263, 64), Common::KEYCODE_5); + addButton(Common::Rect(8, 65, 263, 73), Common::KEYCODE_6); + addButton(Common::Rect(8, 74, 263, 82), Common::KEYCODE_7); + addButton(Common::Rect(8, 83, 263, 91), Common::KEYCODE_8); + addButton(Common::Rect(8, 92, 263, 100), Common::KEYCODE_9); } else { addButton(Common::Rect(12, 109, 36, 129), Common::KEYCODE_w, &_iconSprites); addButton(Common::Rect(46, 109, 70, 129), Common::KEYCODE_a, &_iconSprites); @@ -549,15 +549,15 @@ void ItemsDialog::loadButtons(ItemsMode mode, Character *&c) { addButton(Common::Rect(216, 109, 240, 129), Common::KEYCODE_d, &_iconSprites); addButton(Common::Rect(250, 109, 274, 129), Common::KEYCODE_q, &_iconSprites); addButton(Common::Rect(284, 109, 308, 129), Common::KEYCODE_ESCAPE, &_iconSprites); - addButton(Common::Rect(8, 20, 263, 28), Common::KEYCODE_1, &_iconSprites, false); - addButton(Common::Rect(8, 29, 263, 37), Common::KEYCODE_2, &_iconSprites, false); - addButton(Common::Rect(8, 38, 263, 46), Common::KEYCODE_3, &_iconSprites, false); - addButton(Common::Rect(8, 47, 263, 55), Common::KEYCODE_4, &_iconSprites, false); - addButton(Common::Rect(8, 56, 263, 64), Common::KEYCODE_5, &_iconSprites, false); - addButton(Common::Rect(8, 65, 263, 73), Common::KEYCODE_6, &_iconSprites, false); - addButton(Common::Rect(8, 74, 263, 82), Common::KEYCODE_7, &_iconSprites, false); - addButton(Common::Rect(8, 83, 263, 91), Common::KEYCODE_8, &_iconSprites, false); - addButton(Common::Rect(8, 92, 263, 100), Common::KEYCODE_9, &_iconSprites, false); + addButton(Common::Rect(8, 20, 263, 28), Common::KEYCODE_1); + addButton(Common::Rect(8, 29, 263, 37), Common::KEYCODE_2); + addButton(Common::Rect(8, 38, 263, 46), Common::KEYCODE_3); + addButton(Common::Rect(8, 47, 263, 55), Common::KEYCODE_4); + addButton(Common::Rect(8, 56, 263, 64), Common::KEYCODE_5); + addButton(Common::Rect(8, 65, 263, 73), Common::KEYCODE_6); + addButton(Common::Rect(8, 74, 263, 82), Common::KEYCODE_7); + addButton(Common::Rect(8, 83, 263, 91), Common::KEYCODE_8); + addButton(Common::Rect(8, 92, 263, 100), Common::KEYCODE_9); addPartyButtons(_vm); } @@ -807,15 +807,15 @@ int ItemsDialog::doItemOptions(Character &c, int actionIndex, int itemIndex, Ite escSprites.load("esc.icn"); addButton(Common::Rect(235, 111, 259, 131), Common::KEYCODE_ESCAPE, &escSprites); - addButton(Common::Rect(8, 20, 263, 28), Common::KEYCODE_1, &escSprites, false); - addButton(Common::Rect(8, 29, 263, 37), Common::KEYCODE_2, &escSprites, false); - addButton(Common::Rect(8, 38, 263, 46), Common::KEYCODE_3, &escSprites, false); - addButton(Common::Rect(8, 47, 263, 55), Common::KEYCODE_4, &escSprites, false); - addButton(Common::Rect(8, 56, 263, 64), Common::KEYCODE_5, &escSprites, false); - addButton(Common::Rect(8, 65, 263, 73), Common::KEYCODE_6, &escSprites, false); - addButton(Common::Rect(8, 74, 263, 82), Common::KEYCODE_7, &escSprites, false); - addButton(Common::Rect(8, 83, 263, 91), Common::KEYCODE_8, &escSprites, false); - addButton(Common::Rect(8, 92, 263, 100), Common::KEYCODE_9, &escSprites, false); + addButton(Common::Rect(8, 20, 263, 28), Common::KEYCODE_1); + addButton(Common::Rect(8, 29, 263, 37), Common::KEYCODE_2); + addButton(Common::Rect(8, 38, 263, 46), Common::KEYCODE_3); + addButton(Common::Rect(8, 47, 263, 55), Common::KEYCODE_4); + addButton(Common::Rect(8, 56, 263, 64), Common::KEYCODE_5); + addButton(Common::Rect(8, 65, 263, 73), Common::KEYCODE_6); + addButton(Common::Rect(8, 74, 263, 82), Common::KEYCODE_7); + addButton(Common::Rect(8, 83, 263, 91), Common::KEYCODE_8); + addButton(Common::Rect(8, 92, 263, 100), Common::KEYCODE_9); w.open(); w.writeString(Common::String::format(WHICH_ITEM, ITEM_ACTIONS[actionIndex])); diff --git a/engines/xeen/dialogs_options.cpp b/engines/xeen/dialogs_options.cpp index 8f02559837..4b4974b9aa 100644 --- a/engines/xeen/dialogs_options.cpp +++ b/engines/xeen/dialogs_options.cpp @@ -155,17 +155,17 @@ void OptionsMenu::showTitles2() { } void OptionsMenu::setupButtons(SpriteResource *buttons) { - addButton(Common::Rect(124, 87, 124 + 53, 87 + 10), 'S', buttons, false); - addButton(Common::Rect(126, 98, 126 + 47, 98 + 10), 'L', buttons, false); - addButton(Common::Rect(91, 110, 91 + 118, 110 + 10), 'C', buttons, false); - addButton(Common::Rect(85, 121, 85 + 131, 121 + 10), 'O', buttons, false); + addButton(Common::Rect(124, 87, 124 + 53, 87 + 10), 'S'); + addButton(Common::Rect(126, 98, 126 + 47, 98 + 10), 'L'); + addButton(Common::Rect(91, 110, 91 + 118, 110 + 10), 'C'); + addButton(Common::Rect(85, 121, 85 + 131, 121 + 10), 'O'); } void WorldOptionsMenu::setupButtons(SpriteResource *buttons) { - addButton(Common::Rect(93, 53, 93 + 134, 53 + 20), 'S', buttons, true); - addButton(Common::Rect(93, 78, 93 + 134, 78 + 20), 'L', buttons, true); - addButton(Common::Rect(93, 103, 93 + 134, 103 + 20), 'C', buttons, true); - addButton(Common::Rect(93, 128, 93 + 134, 128 + 20), 'O', buttons, true); + addButton(Common::Rect(93, 53, 93 + 134, 53 + 20), 'S', buttons); + addButton(Common::Rect(93, 78, 93 + 134, 78 + 20), 'L', buttons); + addButton(Common::Rect(93, 103, 93 + 134, 103 + 20), 'C', buttons); + addButton(Common::Rect(93, 128, 93 + 134, 128 + 20), 'O', buttons); } /*------------------------------------------------------------------------*/ diff --git a/engines/xeen/dialogs_party.cpp b/engines/xeen/dialogs_party.cpp index 7414ce3404..544c110c82 100644 --- a/engines/xeen/dialogs_party.cpp +++ b/engines/xeen/dialogs_party.cpp @@ -280,7 +280,7 @@ void PartyDialog::loadButtons() { addButton(Common::Rect(122, 100, 146, 120), Common::KEYCODE_r, &_uiSprites); addButton(Common::Rect(157, 100, 181, 120), Common::KEYCODE_c, &_uiSprites); addButton(Common::Rect(192, 100, 216, 120), Common::KEYCODE_x, &_uiSprites); - addButton(Common::Rect(0, 0, 0, 0), Common::KEYCODE_ESCAPE, &_uiSprites, false); + addButton(Common::Rect(0, 0, 0, 0), Common::KEYCODE_ESCAPE); } void PartyDialog::initDrawStructs() { @@ -310,10 +310,10 @@ void PartyDialog::setupFaces(int firstDisplayChar, bool updateFlag) { // Reset the button areas for the display character images while (_buttons.size() > 7) _buttons.remove_at(7); - addButton(Common::Rect(16, 16, 48, 48), Common::KEYCODE_1, &_uiSprites, false); - addButton(Common::Rect(117, 16, 149, 48), Common::KEYCODE_2, &_uiSprites, false); - addButton(Common::Rect(59, 59, 91, 91), Common::KEYCODE_3, &_uiSprites, false); - addButton(Common::Rect(117, 59, 151, 91), Common::KEYCODE_4, &_uiSprites, false); + addButton(Common::Rect(16, 16, 48, 48), Common::KEYCODE_1); + addButton(Common::Rect(117, 16, 149, 48), Common::KEYCODE_2); + addButton(Common::Rect(59, 59, 91, 91), Common::KEYCODE_3); + addButton(Common::Rect(117, 59, 151, 91), Common::KEYCODE_4); for (posIndex = 0; posIndex < 4; ++posIndex) { @@ -712,10 +712,10 @@ int PartyDialog::selectCharacter(bool isDelete, int firstDisplayChar) { saveButtons(); addButton(Common::Rect(225, isDelete ? 120 : 84, 249, isDelete ? 140 : 104), Common::KEYCODE_ESCAPE, &iconSprites); - addButton(Common::Rect(16, 16, 48, 48), Common::KEYCODE_1, &iconSprites, false); - addButton(Common::Rect(117, 16, 149, 48), Common::KEYCODE_2, &iconSprites, false); - addButton(Common::Rect(16, 59, 48, 91), Common::KEYCODE_3, &iconSprites, false); - addButton(Common::Rect(117, 59, 149, 91), Common::KEYCODE_4, &iconSprites, false); + addButton(Common::Rect(16, 16, 48, 48), Common::KEYCODE_1); + addButton(Common::Rect(117, 16, 149, 48), Common::KEYCODE_2); + addButton(Common::Rect(16, 59, 48, 91), Common::KEYCODE_3); + addButton(Common::Rect(117, 59, 149, 91), Common::KEYCODE_4); addPartyButtons(_vm); int result = -1, v; diff --git a/engines/xeen/dialogs_spells.cpp b/engines/xeen/dialogs_spells.cpp index dbe48c1a99..6a8b160dd8 100644 --- a/engines/xeen/dialogs_spells.cpp +++ b/engines/xeen/dialogs_spells.cpp @@ -152,7 +152,7 @@ Character *SpellsDialog::execute(Character *c, int isCasting) { int spellIndex = (c->_currentSpell == -1) ? 39 : c->_currentSpell; int spellId = SPELLS_ALLOWED[category][spellIndex]; - screen._windows[10].writeString(Common::String::format(SPELL_DETAILS, + screen._windows[10].writeString(Common::String::format(CAST_SPELL_DETAILS, c->_name.c_str(), spells._spellNames[spellId].c_str(), spells.calcSpellPoints(spellId, c->getCurrentLevel()), SPELL_GEM_COST[spellId], c->_currentSp)); @@ -280,8 +280,8 @@ Character *SpellsDialog::execute(Character *c, int isCasting) { void SpellsDialog::loadButtons() { _iconSprites.load("main.icn"); _scrollSprites.load("scroll.icn"); - addButton(Common::Rect(187, 26, 198, 36), Common::KEYCODE_UP, &_scrollSprites, true); - addButton(Common::Rect(187, 111, 198, 121), Common::KEYCODE_DOWN, &_scrollSprites, true); + addButton(Common::Rect(187, 26, 198, 36), Common::KEYCODE_UP, &_scrollSprites); + addButton(Common::Rect(187, 111, 198, 121), Common::KEYCODE_DOWN, &_scrollSprites); addButton(Common::Rect(40, 28, 187, 36), Common::KEYCODE_1); addButton(Common::Rect(40, 37, 187, 45), Common::KEYCODE_2); addButton(Common::Rect(40, 46, 187, 54), Common::KEYCODE_3); diff --git a/engines/xeen/interface.cpp b/engines/xeen/interface.cpp index 0c7f15dc5f..04206581ec 100644 --- a/engines/xeen/interface.cpp +++ b/engines/xeen/interface.cpp @@ -239,10 +239,10 @@ void Interface::setMainButtons(bool combatMode) { addButton(Common::Rect(235, 169, 259, 189), (Common::KBD_CTRL << 16) |Common::KEYCODE_LEFT, &_iconSprites); addButton(Common::Rect(260, 169, 284, 189), Common::KEYCODE_DOWN, &_iconSprites); addButton(Common::Rect(286, 169, 310, 189), (Common::KBD_CTRL << 16) | Common::KEYCODE_RIGHT, &_iconSprites); - addButton(Common::Rect(236, 11, 308, 69), Common::KEYCODE_EQUALS, &_iconSprites, false); - addButton(Common::Rect(239, 27, 312, 37), Common::KEYCODE_1, &_iconSprites, false); - addButton(Common::Rect(239, 37, 312, 47), Common::KEYCODE_2, &_iconSprites, false); - addButton(Common::Rect(239, 47, 312, 57), Common::KEYCODE_3, &_iconSprites, false); + addButton(Common::Rect(236, 11, 308, 69), Common::KEYCODE_EQUALS); + addButton(Common::Rect(239, 27, 312, 37), Common::KEYCODE_1); + addButton(Common::Rect(239, 37, 312, 47), Common::KEYCODE_2); + addButton(Common::Rect(239, 47, 312, 57), Common::KEYCODE_3); addPartyButtons(_vm); if (combatMode) { diff --git a/engines/xeen/resources.cpp b/engines/xeen/resources.cpp index 0fe20fb2c4..da57a8085b 100644 --- a/engines/xeen/resources.cpp +++ b/engines/xeen/resources.cpp @@ -931,18 +931,6 @@ const char *const SPELLS_PURCHASE = "\x3l\xB""000\x9""000\xC""d%s Do you wish to purchase " "\xC""09%s\xC""d for %u?"; -const char *const SPELL_DETAILS = - "\xD\x2\x3""c\xB""122\x9""013\xC""37C\xC""dast" - "\x9""040\xC""37N\xC""dew\x9""067ESC\x1""000\xB""000\x3""cCast Spell\n" - "\n" - "%s\x3l\n" - "\n" - "Spell Ready:\x3""c\n" - "\n" - "\xC""09%s\xC""d\x2\x3l\n" - "\xB""082Cost\x3r\x9""000%u/%u\x3l\n" - "Cur SP\x3r\x9""000%u\x1"; - const char *const MAP_TEXT = "\x3""c\xB""000\x9""000%s\x3l\xB""139" "\x9""000X = %d\x3r\x9""000Y = %d\x3""c\x9""000%s"; diff --git a/engines/xeen/resources.h b/engines/xeen/resources.h index 30eb4f5b63..c61784475c 100644 --- a/engines/xeen/resources.h +++ b/engines/xeen/resources.h @@ -288,8 +288,6 @@ extern const char *const SPELLS_PRESS_A_KEY; extern const char *const SPELLS_PURCHASE; -extern const char *const SPELL_DETAILS; - extern const char *const MAP_TEXT; extern const char *const LIGHT_COUNT_TEXT; diff --git a/engines/xeen/town.cpp b/engines/xeen/town.cpp index b850439021..2723226996 100644 --- a/engines/xeen/town.cpp +++ b/engines/xeen/town.cpp @@ -108,11 +108,11 @@ int Town::townAction(int actionId) { case 1: // Blacksmith _icons1.load("esc.icn"); - addButton(Common::Rect(261, 100, 285, 120), Common::KEYCODE_ESCAPE, &_icons1, true); - addButton(Common::Rect(234, 54, 308, 62), 0, &_icons1, false); - addButton(Common::Rect(234, 64, 308, 72), Common::KEYCODE_b, &_icons1, false); - addButton(Common::Rect(234, 74, 308, 82), 0, &_icons1, false); - addButton(Common::Rect(234, 84, 308, 92), 0, &_icons1, false); + addButton(Common::Rect(261, 100, 285, 120), Common::KEYCODE_ESCAPE, &_icons1); + addButton(Common::Rect(234, 54, 308, 62), 0); + addButton(Common::Rect(234, 64, 308, 72), Common::KEYCODE_b); + addButton(Common::Rect(234, 74, 308, 82), 0); + addButton(Common::Rect(234, 84, 308, 92), 0); sound.playSample(nullptr, 0); vocName = isDarkCc ? "see2.voc" : "whaddayo.voc"; @@ -122,11 +122,11 @@ int Town::townAction(int actionId) { // Guild loadStrings("spldesc.bin"); _icons1.load("esc.icn"); - addButton(Common::Rect(261, 100, 285, 120), Common::KEYCODE_ESCAPE, &_icons1, true); - addButton(Common::Rect(234, 54, 308, 62), 0, &_icons1, false); - addButton(Common::Rect(234, 64, 308, 72), Common::KEYCODE_b, &_icons1, false); - addButton(Common::Rect(234, 74, 308, 82), Common::KEYCODE_s, &_icons1, false); - addButton(Common::Rect(234, 84, 308, 92), 0, &_icons1, false); + addButton(Common::Rect(261, 100, 285, 120), Common::KEYCODE_ESCAPE, &_icons1); + addButton(Common::Rect(234, 54, 308, 62), 0); + addButton(Common::Rect(234, 64, 308, 72), Common::KEYCODE_b); + addButton(Common::Rect(234, 74, 308, 82), Common::KEYCODE_s); + addButton(Common::Rect(234, 84, 308, 92), 0); _vm->_mode = MODE_17; sound.playSample(nullptr, 0); @@ -137,12 +137,12 @@ int Town::townAction(int actionId) { // Tavern loadStrings("tavern.bin"); _icons1.load("tavern.icn"); - addButton(Common::Rect(281, 108, 305, 128), Common::KEYCODE_ESCAPE, &_icons1, true); - addButton(Common::Rect(242, 108, 266, 128), Common::KEYCODE_s, &_icons1, true); - addButton(Common::Rect(234, 54, 308, 62), Common::KEYCODE_d, &_icons1, false); - addButton(Common::Rect(234, 64, 308, 72), Common::KEYCODE_f, &_icons1, false); - addButton(Common::Rect(234, 74, 308, 82), Common::KEYCODE_t, &_icons1, false); - addButton(Common::Rect(234, 84, 308, 92), Common::KEYCODE_r, &_icons1, false); + addButton(Common::Rect(281, 108, 305, 128), Common::KEYCODE_ESCAPE, &_icons1); + addButton(Common::Rect(242, 108, 266, 128), Common::KEYCODE_s, &_icons1); + addButton(Common::Rect(234, 54, 308, 62), Common::KEYCODE_d); + addButton(Common::Rect(234, 64, 308, 72), Common::KEYCODE_f); + addButton(Common::Rect(234, 74, 308, 82), Common::KEYCODE_t); + addButton(Common::Rect(234, 84, 308, 92), Common::KEYCODE_r); _vm->_mode = MODE_17; sound.playSample(nullptr, 0); @@ -152,11 +152,11 @@ int Town::townAction(int actionId) { case 4: // Temple _icons1.load("esc.icn"); - addButton(Common::Rect(261, 100, 285, 120), Common::KEYCODE_ESCAPE, &_icons1, true); - addButton(Common::Rect(234, 54, 308, 62), Common::KEYCODE_h, &_icons1, false); - addButton(Common::Rect(234, 64, 308, 72), Common::KEYCODE_d, &_icons1, false); - addButton(Common::Rect(234, 74, 308, 82), Common::KEYCODE_u, &_icons1, false); - addButton(Common::Rect(234, 84, 308, 92), 0, &_icons1, false); + addButton(Common::Rect(261, 100, 285, 120), Common::KEYCODE_ESCAPE, &_icons1); + addButton(Common::Rect(234, 54, 308, 62), Common::KEYCODE_h); + addButton(Common::Rect(234, 64, 308, 72), Common::KEYCODE_d); + addButton(Common::Rect(234, 74, 308, 82), Common::KEYCODE_u); + addButton(Common::Rect(234, 84, 308, 92), 0); sound.playSample(nullptr, 0); vocName = isDarkCc ? "help2.voc" : "maywe2.voc"; @@ -168,8 +168,8 @@ int Town::townAction(int actionId) { _v2 = 0; _icons1.load("train.icn"); - addButton(Common::Rect(281, 108, 305, 128), Common::KEYCODE_ESCAPE, &_icons1, true); - addButton(Common::Rect(242, 108, 266, 128), Common::KEYCODE_t, &_icons1, false); + addButton(Common::Rect(281, 108, 305, 128), Common::KEYCODE_ESCAPE, &_icons1); + addButton(Common::Rect(242, 108, 266, 128), Common::KEYCODE_t); sound.playSample(nullptr, 0); vocName = isDarkCc ? "training.voc" : "youtrn1.voc"; |