diff options
author | Littleboy | 2014-06-03 21:06:34 -0400 |
---|---|---|
committer | Littleboy | 2014-06-16 18:46:14 -0400 |
commit | 73cc1803cb3eb9651e346751e8aa9ae718a85f51 (patch) | |
tree | 935e05b6c65d322bd46009e1826675f48f840adc /engines/lastexpress/entities | |
parent | 5310d49e5305cc5159d875cc8a8699ef6cc4b1b0 (diff) | |
download | scummvm-rg350-73cc1803cb3eb9651e346751e8aa9ae718a85f51.tar.gz scummvm-rg350-73cc1803cb3eb9651e346751e8aa9ae718a85f51.tar.bz2 scummvm-rg350-73cc1803cb3eb9651e346751e8aa9ae718a85f51.zip |
LASTEXPRESS: Rename Waiter* functions
Diffstat (limited to 'engines/lastexpress/entities')
-rw-r--r-- | engines/lastexpress/entities/chapters.cpp | 4 | ||||
-rw-r--r-- | engines/lastexpress/entities/waiter1.cpp | 153 | ||||
-rw-r--r-- | engines/lastexpress/entities/waiter1.h | 66 | ||||
-rw-r--r-- | engines/lastexpress/entities/waiter2.cpp | 102 | ||||
-rw-r--r-- | engines/lastexpress/entities/waiter2.h | 54 |
5 files changed, 171 insertions, 208 deletions
diff --git a/engines/lastexpress/entities/chapters.cpp b/engines/lastexpress/entities/chapters.cpp index b100e30ad4..6023ae6062 100644 --- a/engines/lastexpress/entities/chapters.cpp +++ b/engines/lastexpress/entities/chapters.cpp @@ -1518,8 +1518,8 @@ label_callback_4: RESET_ENTITY_STATE(kEntityAugust, August, setup_function65); RESET_ENTITY_STATE(kEntityMertens, Mertens, setup_function48); RESET_ENTITY_STATE(kEntityCoudert, Coudert, setup_function53); - RESET_ENTITY_STATE(kEntityWaiter1, Waiter1, setup_chapter4Handler); - RESET_ENTITY_STATE(kEntityWaiter2, Waiter2, setup_chapter4Handler); + RESET_ENTITY_STATE(kEntityWaiter1, Waiter1, setup_serving4); + RESET_ENTITY_STATE(kEntityWaiter2, Waiter2, setup_serving4); RESET_ENTITY_STATE(kEntityPascale, Pascale, setup_chapter4Handler); RESET_ENTITY_STATE(kEntityVerges, Verges, setup_chapter4Handler); RESET_ENTITY_STATE(kEntityTatiana, Tatiana, setup_function49); diff --git a/engines/lastexpress/entities/waiter1.cpp b/engines/lastexpress/entities/waiter1.cpp index 21e40d326d..80ec471f1b 100644 --- a/engines/lastexpress/entities/waiter1.cpp +++ b/engines/lastexpress/entities/waiter1.cpp @@ -46,35 +46,35 @@ Waiter1::Waiter1(LastExpressEngine *engine) : Entity(engine, kEntityWaiter1) { ADD_CALLBACK_FUNCTION(Waiter1, updatePosition); ADD_CALLBACK_FUNCTION(Waiter1, callbackActionOnDirection); ADD_CALLBACK_FUNCTION(Waiter1, playSound); - ADD_CALLBACK_FUNCTION(Waiter1, function7); - ADD_CALLBACK_FUNCTION(Waiter1, function8); - ADD_CALLBACK_FUNCTION(Waiter1, function9); - ADD_CALLBACK_FUNCTION(Waiter1, function10); + ADD_CALLBACK_FUNCTION(Waiter1, rebeccaFeedUs); + ADD_CALLBACK_FUNCTION(Waiter1, rebeccaClearOurTable); + ADD_CALLBACK_FUNCTION(Waiter1, abbotCheckMe); + ADD_CALLBACK_FUNCTION(Waiter1, abbotClearTable); ADD_CALLBACK_FUNCTION(Waiter1, chapter1); - ADD_CALLBACK_FUNCTION(Waiter1, function12); - ADD_CALLBACK_FUNCTION(Waiter1, function13); - ADD_CALLBACK_FUNCTION(Waiter1, function14); - ADD_CALLBACK_FUNCTION(Waiter1, function15); - ADD_CALLBACK_FUNCTION(Waiter1, function16); - ADD_CALLBACK_FUNCTION(Waiter1, function17); - ADD_CALLBACK_FUNCTION(Waiter1, function18); - ADD_CALLBACK_FUNCTION(Waiter1, function19); - ADD_CALLBACK_FUNCTION(Waiter1, chapter1Handler); + ADD_CALLBACK_FUNCTION(Waiter1, annaOrder); + ADD_CALLBACK_FUNCTION(Waiter1, augustOrder); + ADD_CALLBACK_FUNCTION(Waiter1, serveAnna); + ADD_CALLBACK_FUNCTION(Waiter1, serveAugust); + ADD_CALLBACK_FUNCTION(Waiter1, clearAnna); + ADD_CALLBACK_FUNCTION(Waiter1, clearTatiana); + ADD_CALLBACK_FUNCTION(Waiter1, clearAugust1); + ADD_CALLBACK_FUNCTION(Waiter1, clearAugust2); + ADD_CALLBACK_FUNCTION(Waiter1, servingDinner); ADD_CALLBACK_FUNCTION(Waiter1, function21); ADD_CALLBACK_FUNCTION(Waiter1, function22); ADD_CALLBACK_FUNCTION(Waiter1, chapter2); - ADD_CALLBACK_FUNCTION(Waiter1, chapter2Handler); - ADD_CALLBACK_FUNCTION(Waiter1, function25); - ADD_CALLBACK_FUNCTION(Waiter1, function26); + ADD_CALLBACK_FUNCTION(Waiter1, inKitchen); + ADD_CALLBACK_FUNCTION(Waiter1, augustComeHere2); + ADD_CALLBACK_FUNCTION(Waiter1, augustClearTable2); ADD_CALLBACK_FUNCTION(Waiter1, chapter3); - ADD_CALLBACK_FUNCTION(Waiter1, chapter3Handler); - ADD_CALLBACK_FUNCTION(Waiter1, augustAnnaDateOrder); - ADD_CALLBACK_FUNCTION(Waiter1, function30); + ADD_CALLBACK_FUNCTION(Waiter1, serving3); + ADD_CALLBACK_FUNCTION(Waiter1, annaComeHere3); + ADD_CALLBACK_FUNCTION(Waiter1, abbotServeLunch3); ADD_CALLBACK_FUNCTION(Waiter1, chapter4); - ADD_CALLBACK_FUNCTION(Waiter1, chapter4Handler); - ADD_CALLBACK_FUNCTION(Waiter1, augustOrderSteak); - ADD_CALLBACK_FUNCTION(Waiter1, augustServeDuck); - ADD_CALLBACK_FUNCTION(Waiter1, function35); + ADD_CALLBACK_FUNCTION(Waiter1, serving4); + ADD_CALLBACK_FUNCTION(Waiter1, augustOrder4); + ADD_CALLBACK_FUNCTION(Waiter1, serveAugust4); + ADD_CALLBACK_FUNCTION(Waiter1, augustClearTable); ADD_CALLBACK_FUNCTION(Waiter1, chapter5); ADD_CALLBACK_FUNCTION(Waiter1, chapter5Handler); ADD_NULL_FUNCTION(); @@ -132,7 +132,7 @@ IMPLEMENT_FUNCTION_S(6, Waiter1, playSound) IMPLEMENT_FUNCTION_END ////////////////////////////////////////////////////////////////////////// -IMPLEMENT_FUNCTION(7, Waiter1, function7) +IMPLEMENT_FUNCTION(7, Waiter1, rebeccaFeedUs) switch (savepoint.action) { default: break; @@ -173,12 +173,12 @@ IMPLEMENT_FUNCTION(7, Waiter1, function7) IMPLEMENT_FUNCTION_END ////////////////////////////////////////////////////////////////////////// -IMPLEMENT_FUNCTION(8, Waiter1, function8) +IMPLEMENT_FUNCTION(8, Waiter1, rebeccaClearOurTable) serveTable(savepoint, "911", kEntityTables3, "010L", "010M", "913", &ENTITY_PARAM(1, 2)); IMPLEMENT_FUNCTION_END ////////////////////////////////////////////////////////////////////////// -IMPLEMENT_FUNCTION(9, Waiter1, function9) +IMPLEMENT_FUNCTION(9, Waiter1, abbotCheckMe) switch (savepoint.action) { default: break; @@ -225,7 +225,7 @@ IMPLEMENT_FUNCTION(9, Waiter1, function9) IMPLEMENT_FUNCTION_END ////////////////////////////////////////////////////////////////////////// -IMPLEMENT_FUNCTION(10, Waiter1, function10) +IMPLEMENT_FUNCTION(10, Waiter1, abbotClearTable) serveTable(savepoint, "916", kEntityTables4, "014E", "014F", "918", &ENTITY_PARAM(2, 3), false); IMPLEMENT_FUNCTION_END @@ -236,7 +236,7 @@ IMPLEMENT_FUNCTION(11, Waiter1, chapter1) break; case kActionNone: - setup_chapter1Handler(); + setup_servingDinner(); break; case kActionDefault: @@ -265,47 +265,47 @@ IMPLEMENT_FUNCTION(11, Waiter1, chapter1) IMPLEMENT_FUNCTION_END ////////////////////////////////////////////////////////////////////////// -IMPLEMENT_FUNCTION(12, Waiter1, function12) +IMPLEMENT_FUNCTION(12, Waiter1, annaOrder) handleServer(savepoint, "907", kEntityAnna, kAction268773672, &ENTITY_PARAM(0, 1)); IMPLEMENT_FUNCTION_END ////////////////////////////////////////////////////////////////////////// -IMPLEMENT_FUNCTION(13, Waiter1, function13) +IMPLEMENT_FUNCTION(13, Waiter1, augustOrder) handleServer(savepoint, "911", kEntityAugust, kAction268773672, &ENTITY_PARAM(0, 2), "010F"); IMPLEMENT_FUNCTION_END ////////////////////////////////////////////////////////////////////////// -IMPLEMENT_FUNCTION(14, Waiter1, function14) +IMPLEMENT_FUNCTION(14, Waiter1, serveAnna) handleServer(savepoint, "908", kEntityAnna, kAction170016384, &ENTITY_PARAM(0, 4)); IMPLEMENT_FUNCTION_END ////////////////////////////////////////////////////////////////////////// -IMPLEMENT_FUNCTION(15, Waiter1, function15) +IMPLEMENT_FUNCTION(15, Waiter1, serveAugust) handleServer(savepoint, "912", kEntityAugust, kAction170016384, &ENTITY_PARAM(0, 5)); IMPLEMENT_FUNCTION_END ////////////////////////////////////////////////////////////////////////// -IMPLEMENT_FUNCTION(16, Waiter1, function16) +IMPLEMENT_FUNCTION(16, Waiter1, clearAnna) serveTable(savepoint, "907", kEntityTables0, "001N", "001P", "909", &ENTITY_PARAM(0, 6)); IMPLEMENT_FUNCTION_END ////////////////////////////////////////////////////////////////////////// -IMPLEMENT_FUNCTION(17, Waiter1, function17) +IMPLEMENT_FUNCTION(17, Waiter1, clearTatiana) serveTable(savepoint, "915", kEntityTables4, "014E", "014F", "917", &ENTITY_PARAM(1, 1), true, false, 67); IMPLEMENT_FUNCTION_END ////////////////////////////////////////////////////////////////////////// -IMPLEMENT_FUNCTION(18, Waiter1, function18) +IMPLEMENT_FUNCTION(18, Waiter1, clearAugust1) serveTable(savepoint, "911", kEntityTables3, "010L", "010H", "913", &ENTITY_PARAM(0, 7)); IMPLEMENT_FUNCTION_END ////////////////////////////////////////////////////////////////////////// -IMPLEMENT_FUNCTION(19, Waiter1, function19) +IMPLEMENT_FUNCTION(19, Waiter1, clearAugust2) serveTable(savepoint, "911", kEntityTables3, "010L", "010M", "913", &ENTITY_PARAM(0, 8), true, true); IMPLEMENT_FUNCTION_END ////////////////////////////////////////////////////////////////////////// -IMPLEMENT_FUNCTION(20, Waiter1, chapter1Handler) +IMPLEMENT_FUNCTION(20, Waiter1, servingDinner) switch (savepoint.action) { default: break; @@ -328,16 +328,16 @@ IMPLEMENT_FUNCTION(20, Waiter1, chapter1Handler) if (!getEntities()->isInKitchen(kEntityWaiter1) && !getEntities()->isSomebodyInsideRestaurantOrSalon()) break; - HANDLE_TABLE(0, 1, 1, setup_function12); - HANDLE_TABLE(0, 2, 2, setup_function13); - HANDLE_TABLE(0, 3, 3, setup_function7); - HANDLE_TABLE(0, 4, 4, setup_function14); - HANDLE_TABLE(0, 5, 5, setup_function15); - HANDLE_TABLE(0, 6, 6, setup_function16); - HANDLE_TABLE(1, 1, 7, setup_function17); - HANDLE_TABLE(0, 7, 8, setup_function18); - HANDLE_TABLE(0, 8, 9, setup_function19); - HANDLE_TABLE(1, 2, 10, setup_function8); + HANDLE_TABLE(0, 1, 1, setup_annaOrder); + HANDLE_TABLE(0, 2, 2, setup_augustOrder); + HANDLE_TABLE(0, 3, 3, setup_rebeccaFeedUs); + HANDLE_TABLE(0, 4, 4, setup_serveAnna); + HANDLE_TABLE(0, 5, 5, setup_serveAugust); + HANDLE_TABLE(0, 6, 6, setup_clearAnna); + HANDLE_TABLE(1, 1, 7, setup_clearTatiana); + HANDLE_TABLE(0, 7, 8, setup_clearAugust1); + HANDLE_TABLE(0, 8, 9, setup_clearAugust2); + HANDLE_TABLE(1, 2, 10, setup_rebeccaClearOurTable); break; case kActionCallback: @@ -415,7 +415,7 @@ IMPLEMENT_FUNCTION(23, Waiter1, chapter2) break; case kActionNone: - setup_chapter2Handler(); + setup_inKitchen(); break; case kActionDefault: @@ -434,7 +434,7 @@ IMPLEMENT_FUNCTION(23, Waiter1, chapter2) IMPLEMENT_FUNCTION_END ////////////////////////////////////////////////////////////////////////// -IMPLEMENT_FUNCTION(24, Waiter1, chapter2Handler) +IMPLEMENT_FUNCTION(24, Waiter1, inKitchen) switch (savepoint.action) { default: break; @@ -443,19 +443,19 @@ IMPLEMENT_FUNCTION(24, Waiter1, chapter2Handler) if (!getEntities()->isInKitchen(kEntityWaiter1) || !getEntities()->isSomebodyInsideRestaurantOrSalon()) break; - HANDLE_TABLE(1, 3, 1, setup_function25); - HANDLE_TABLE(1, 4, 2, setup_function26); + HANDLE_TABLE(1, 3, 1, setup_augustComeHere2); + HANDLE_TABLE(1, 4, 2, setup_augustClearTable2); break; case kActionCallback: if (getCallback() == 1) - HANDLE_TABLE(1, 4, 2, setup_function26); + HANDLE_TABLE(1, 4, 2, setup_augustClearTable2); break; } IMPLEMENT_FUNCTION_END ////////////////////////////////////////////////////////////////////////// -IMPLEMENT_FUNCTION(25, Waiter1, function25) +IMPLEMENT_FUNCTION(25, Waiter1, augustComeHere2) switch (savepoint.action) { default: break; @@ -496,7 +496,7 @@ IMPLEMENT_FUNCTION(25, Waiter1, function25) IMPLEMENT_FUNCTION_END ////////////////////////////////////////////////////////////////////////// -IMPLEMENT_FUNCTION(26, Waiter1, function26) +IMPLEMENT_FUNCTION(26, Waiter1, augustClearTable2) serveTable(savepoint, "957", kEntityTables0, "016E", "016D", "959", &ENTITY_PARAM(1, 4)); IMPLEMENT_FUNCTION_END @@ -507,7 +507,7 @@ IMPLEMENT_FUNCTION(27, Waiter1, chapter3) break; case kActionNone: - setup_chapter3Handler(); + setup_serving3(); break; case kActionDefault: @@ -530,7 +530,7 @@ IMPLEMENT_FUNCTION(27, Waiter1, chapter3) IMPLEMENT_FUNCTION_END ////////////////////////////////////////////////////////////////////////// -IMPLEMENT_FUNCTION(28, Waiter1, chapter3Handler) +IMPLEMENT_FUNCTION(28, Waiter1, serving3) switch (savepoint.action) { default: break; @@ -541,42 +541,42 @@ IMPLEMENT_FUNCTION(28, Waiter1, chapter3Handler) if (ENTITY_PARAM(1, 5)) { setCallback(1); - setup_augustAnnaDateOrder(); + setup_annaComeHere3(); break; } label_callback_1: if (ENTITY_PARAM(1, 6)) { setCallback(2); - setup_function9(); + setup_abbotCheckMe(); break; } label_callback_2: if (ENTITY_PARAM(2, 4)) { setCallback(3); - setup_function30(); + setup_abbotServeLunch3(); break; } label_callback_3: if (ENTITY_PARAM(2, 3)) { setCallback(4); - setup_function10(); + setup_abbotClearTable(); break; } label_callback_4: if (ENTITY_PARAM(0, 3)) { setCallback(5); - setup_function7(); + setup_rebeccaFeedUs(); break; } label_callback_5: if (ENTITY_PARAM(1, 2)) { setCallback(6); - setup_function8(); + setup_rebeccaClearOurTable(); break; } break; @@ -606,7 +606,8 @@ label_callback_5: IMPLEMENT_FUNCTION_END ////////////////////////////////////////////////////////////////////////// -IMPLEMENT_FUNCTION(29, Waiter1, augustAnnaDateOrder) +IMPLEMENT_FUNCTION(29, Waiter1, annaComeHere3) + // August and Anna order dinner switch (savepoint.action) { default: break; @@ -652,7 +653,7 @@ IMPLEMENT_FUNCTION(29, Waiter1, augustAnnaDateOrder) IMPLEMENT_FUNCTION_END ////////////////////////////////////////////////////////////////////////// -IMPLEMENT_FUNCTION(30, Waiter1, function30) +IMPLEMENT_FUNCTION(30, Waiter1, abbotServeLunch3) switch (savepoint.action) { default: break; @@ -704,7 +705,7 @@ IMPLEMENT_FUNCTION(31, Waiter1, chapter4) break; case kActionNone: - setup_chapter4Handler(); + setup_serving4(); break; case kActionDefault: @@ -727,7 +728,7 @@ IMPLEMENT_FUNCTION(31, Waiter1, chapter4) IMPLEMENT_FUNCTION_END ////////////////////////////////////////////////////////////////////////// -IMPLEMENT_FUNCTION(32, Waiter1, chapter4Handler) +IMPLEMENT_FUNCTION(32, Waiter1, serving4) switch (savepoint.action) { default: break; @@ -743,42 +744,42 @@ IMPLEMENT_FUNCTION(32, Waiter1, chapter4Handler) if (ENTITY_PARAM(1, 7)) { setCallback(1); - setup_augustOrderSteak(); + setup_augustOrder4(); break; } label_callback_1: if (ENTITY_PARAM(1, 8)) { setCallback(2); - setup_augustServeDuck(); + setup_serveAugust4(); break; } label_callback_2: if (ENTITY_PARAM(2, 1)) { setCallback(3); - setup_function35(); + setup_augustClearTable(); break; } label_callback_3: if (ENTITY_PARAM(2, 2)) { setCallback(4); - setup_function9(); + setup_abbotCheckMe(); break; } label_callback_4: if (ENTITY_PARAM(2, 3)) { setCallback(5); - setup_function10(); + setup_abbotClearTable(); break; } label_callback_5: if (ENTITY_PARAM(0, 3)) { setCallback(6); - setup_function7(); + setup_rebeccaFeedUs(); break; } break; @@ -821,7 +822,8 @@ label_callback_5: IMPLEMENT_FUNCTION_END ////////////////////////////////////////////////////////////////////////// -IMPLEMENT_FUNCTION(33, Waiter1, augustOrderSteak) +IMPLEMENT_FUNCTION(33, Waiter1, augustOrder4) + // August orders a steak switch (savepoint.action) { default: break; @@ -864,7 +866,8 @@ IMPLEMENT_FUNCTION(33, Waiter1, augustOrderSteak) IMPLEMENT_FUNCTION_END ////////////////////////////////////////////////////////////////////////// -IMPLEMENT_FUNCTION(34, Waiter1, augustServeDuck) +IMPLEMENT_FUNCTION(34, Waiter1, serveAugust4) + // August is being served switch (savepoint.action) { default: break; @@ -907,7 +910,7 @@ IMPLEMENT_FUNCTION(34, Waiter1, augustServeDuck) IMPLEMENT_FUNCTION_END ////////////////////////////////////////////////////////////////////////// -IMPLEMENT_FUNCTION(35, Waiter1, function35) +IMPLEMENT_FUNCTION(35, Waiter1, augustClearTable) serveTable(savepoint, "911", kEntityTables3, "010L", "010M", "914", &ENTITY_PARAM(2, 1), false, true); IMPLEMENT_FUNCTION_END diff --git a/engines/lastexpress/entities/waiter1.h b/engines/lastexpress/entities/waiter1.h index 2a0c56e8ab..64c66550af 100644 --- a/engines/lastexpress/entities/waiter1.h +++ b/engines/lastexpress/entities/waiter1.h @@ -80,29 +80,24 @@ public: */ DECLARE_FUNCTION_1(playSound, const char *filename) - DECLARE_FUNCTION(function7) - DECLARE_FUNCTION(function8) - DECLARE_FUNCTION(function9) - DECLARE_FUNCTION(function10) + DECLARE_FUNCTION(rebeccaFeedUs) + DECLARE_FUNCTION(rebeccaClearOurTable) + DECLARE_FUNCTION(abbotCheckMe) + DECLARE_FUNCTION(abbotClearTable) /** * Setup Chapter 1 */ DECLARE_FUNCTION(chapter1) - DECLARE_FUNCTION(function12) - DECLARE_FUNCTION(function13) - DECLARE_FUNCTION(function14) - DECLARE_FUNCTION(function15) - DECLARE_FUNCTION(function16) - DECLARE_FUNCTION(function17) - DECLARE_FUNCTION(function18) - DECLARE_FUNCTION(function19) - - /** - * Handle Chapter 1 events - */ - DECLARE_FUNCTION(chapter1Handler) - + DECLARE_FUNCTION(annaOrder) + DECLARE_FUNCTION(augustOrder) + DECLARE_FUNCTION(serveAnna) + DECLARE_FUNCTION(serveAugust) + DECLARE_FUNCTION(clearAnna) + DECLARE_FUNCTION(clearTatiana) + DECLARE_FUNCTION(clearAugust1) + DECLARE_FUNCTION(clearAugust2) + DECLARE_FUNCTION(servingDinner) DECLARE_FUNCTION(function21) DECLARE_FUNCTION(function22) @@ -110,41 +105,26 @@ public: * Setup Chapter 2 */ DECLARE_FUNCTION(chapter2) - - /** - * Handle Chapter 2 events - */ - DECLARE_FUNCTION(chapter2Handler) - - DECLARE_FUNCTION(function25) - DECLARE_FUNCTION(function26) + DECLARE_FUNCTION(inKitchen) + DECLARE_FUNCTION(augustComeHere2) + DECLARE_FUNCTION(augustClearTable2) /** * Setup Chapter 3 */ DECLARE_FUNCTION(chapter3) - - /** - * Handle Chapter 3 events - */ - DECLARE_FUNCTION(chapter3Handler) - - DECLARE_FUNCTION(augustAnnaDateOrder) - DECLARE_FUNCTION(function30) + DECLARE_FUNCTION(serving3) + DECLARE_FUNCTION(annaComeHere3) + DECLARE_FUNCTION(abbotServeLunch3) /** * Setup Chapter 4 */ DECLARE_FUNCTION(chapter4) - - /** - * Handle Chapter 4 events - */ - DECLARE_FUNCTION(chapter4Handler) - - DECLARE_FUNCTION(augustOrderSteak) - DECLARE_FUNCTION(augustServeDuck) - DECLARE_FUNCTION(function35) + DECLARE_FUNCTION(serving4) + DECLARE_FUNCTION(augustOrder4) + DECLARE_FUNCTION(serveAugust4) + DECLARE_FUNCTION(augustClearTable) /** * Setup Chapter 5 diff --git a/engines/lastexpress/entities/waiter2.cpp b/engines/lastexpress/entities/waiter2.cpp index 8641818454..ebb5a3efb4 100644 --- a/engines/lastexpress/entities/waiter2.cpp +++ b/engines/lastexpress/entities/waiter2.cpp @@ -39,29 +39,29 @@ Waiter2::Waiter2(LastExpressEngine *engine) : Entity(engine, kEntityWaiter2) { ADD_CALLBACK_FUNCTION(Waiter2, callbackActionOnDirection); ADD_CALLBACK_FUNCTION(Waiter2, callSavepoint); ADD_CALLBACK_FUNCTION(Waiter2, playSound); - ADD_CALLBACK_FUNCTION(Waiter2, function7); + ADD_CALLBACK_FUNCTION(Waiter2, monsieurServeUs); ADD_CALLBACK_FUNCTION(Waiter2, chapter1); - ADD_CALLBACK_FUNCTION(Waiter2, function9); - ADD_CALLBACK_FUNCTION(Waiter2, function10); - ADD_CALLBACK_FUNCTION(Waiter2, function11); - ADD_CALLBACK_FUNCTION(Waiter2, function12); - ADD_CALLBACK_FUNCTION(Waiter2, function13); - ADD_CALLBACK_FUNCTION(Waiter2, chapter1Handler); + ADD_CALLBACK_FUNCTION(Waiter2, milosOrder); + ADD_CALLBACK_FUNCTION(Waiter2, monsieurOrder); + ADD_CALLBACK_FUNCTION(Waiter2, clearAlexei); + ADD_CALLBACK_FUNCTION(Waiter2, clearMilos); + ADD_CALLBACK_FUNCTION(Waiter2, clearMonsieur); + ADD_CALLBACK_FUNCTION(Waiter2, servingDinner); ADD_CALLBACK_FUNCTION(Waiter2, function15); ADD_CALLBACK_FUNCTION(Waiter2, function16); ADD_CALLBACK_FUNCTION(Waiter2, chapter2); - ADD_CALLBACK_FUNCTION(Waiter2, chapter2Handler); - ADD_CALLBACK_FUNCTION(Waiter2, function19); - ADD_CALLBACK_FUNCTION(Waiter2, function20); - ADD_CALLBACK_FUNCTION(Waiter2, function21); + ADD_CALLBACK_FUNCTION(Waiter2, inKitchen); + ADD_CALLBACK_FUNCTION(Waiter2, tatianaClearTableB); + ADD_CALLBACK_FUNCTION(Waiter2, ivoComeHere); + ADD_CALLBACK_FUNCTION(Waiter2, ivoClearTableC); ADD_CALLBACK_FUNCTION(Waiter2, chapter3); - ADD_CALLBACK_FUNCTION(Waiter2, chapter3Handler); - ADD_CALLBACK_FUNCTION(Waiter2, function24); + ADD_CALLBACK_FUNCTION(Waiter2, serving3); + ADD_CALLBACK_FUNCTION(Waiter2, annaBringTea3); ADD_CALLBACK_FUNCTION(Waiter2, chapter4); - ADD_CALLBACK_FUNCTION(Waiter2, chapter4Handler); - ADD_CALLBACK_FUNCTION(Waiter2, function27); - ADD_CALLBACK_FUNCTION(Waiter2, function28); - ADD_CALLBACK_FUNCTION(Waiter2, function29); + ADD_CALLBACK_FUNCTION(Waiter2, serving4); + ADD_CALLBACK_FUNCTION(Waiter2, augustNeedsADrink); + ADD_CALLBACK_FUNCTION(Waiter2, serveAugustADrink); + ADD_CALLBACK_FUNCTION(Waiter2, annaNeedsADrink); ADD_CALLBACK_FUNCTION(Waiter2, chapter5); ADD_CALLBACK_FUNCTION(Waiter2, chapter5Handler); ADD_NULL_FUNCTION() @@ -105,7 +105,7 @@ IMPLEMENT_FUNCTION_S(6, Waiter2, playSound) IMPLEMENT_FUNCTION_END ////////////////////////////////////////////////////////////////////////// -IMPLEMENT_FUNCTION(7, Waiter2, function7) +IMPLEMENT_FUNCTION(7, Waiter2, monsieurServeUs) switch (savepoint.action) { default: break; @@ -154,7 +154,7 @@ IMPLEMENT_FUNCTION(8, Waiter2, chapter1) break; case kActionNone: - setup_chapter1Handler(); + setup_servingDinner(); break; case kActionDefault: @@ -178,7 +178,7 @@ IMPLEMENT_FUNCTION(8, Waiter2, chapter1) IMPLEMENT_FUNCTION_END ////////////////////////////////////////////////////////////////////////// -IMPLEMENT_FUNCTION(9, Waiter2, function9) +IMPLEMENT_FUNCTION(9, Waiter2, milosOrder) switch (savepoint.action) { default: break; @@ -224,7 +224,7 @@ IMPLEMENT_FUNCTION(9, Waiter2, function9) IMPLEMENT_FUNCTION_END ////////////////////////////////////////////////////////////////////////// -IMPLEMENT_FUNCTION(10, Waiter2, function10) +IMPLEMENT_FUNCTION(10, Waiter2, monsieurOrder) switch (savepoint.action) { default: break; @@ -270,22 +270,22 @@ IMPLEMENT_FUNCTION(10, Waiter2, function10) IMPLEMENT_FUNCTION_END ////////////////////////////////////////////////////////////////////////// -IMPLEMENT_FUNCTION(11, Waiter2, function11) +IMPLEMENT_FUNCTION(11, Waiter2, clearAlexei) serveTable(savepoint, "919", kEntityTables1, "005H", "005J", "921", &ENTITY_PARAM(0, 3), 63); IMPLEMENT_FUNCTION_END ////////////////////////////////////////////////////////////////////////// -IMPLEMENT_FUNCTION(12, Waiter2, function12) +IMPLEMENT_FUNCTION(12, Waiter2, clearMilos) serveTable(savepoint, "923", kEntityTables2, "009F", "009G", "926", &ENTITY_PARAM(0, 4)); IMPLEMENT_FUNCTION_END ////////////////////////////////////////////////////////////////////////// -IMPLEMENT_FUNCTION(13, Waiter2, function13) +IMPLEMENT_FUNCTION(13, Waiter2, clearMonsieur) serveTable(savepoint, "923", kEntityTables2, "009F", "009G", "926", &ENTITY_PARAM(0, 5)); IMPLEMENT_FUNCTION_END ////////////////////////////////////////////////////////////////////////// -IMPLEMENT_FUNCTION(14, Waiter2, chapter1Handler) +IMPLEMENT_FUNCTION(14, Waiter2, servingDinner) switch (savepoint.action) { default: break; @@ -296,31 +296,31 @@ switch (savepoint.action) { if (ENTITY_PARAM(0, 1)) { setCallback(1); - setup_function9(); + setup_milosOrder(); break; } if (ENTITY_PARAM(1, 2)) { setCallback(2); - setup_function10(); + setup_monsieurOrder(); break; } if (ENTITY_PARAM(0, 3)) { setCallback(3); - setup_function11(); + setup_clearAlexei(); break; } if (ENTITY_PARAM(0, 4)) { setCallback(4); - setup_function12(); + setup_clearMilos(); break; } if (ENTITY_PARAM(0, 5)) { setCallback(5); - setup_function13(); + setup_clearMonsieur(); } break; @@ -367,7 +367,7 @@ IMPLEMENT_FUNCTION(17, Waiter2, chapter2) break; case kActionNone: - setup_chapter2Handler(); + setup_inKitchen(); break; case kActionDefault: @@ -387,7 +387,7 @@ IMPLEMENT_FUNCTION(17, Waiter2, chapter2) IMPLEMENT_FUNCTION_END ////////////////////////////////////////////////////////////////////////// -IMPLEMENT_FUNCTION(18, Waiter2, chapter2Handler) +IMPLEMENT_FUNCTION(18, Waiter2, inKitchen) switch (savepoint.action) { default: break; @@ -398,21 +398,21 @@ IMPLEMENT_FUNCTION(18, Waiter2, chapter2Handler) if (ENTITY_PARAM(0, 6)) { setCallback(1); - setup_function19(); + setup_tatianaClearTableB(); break; } label_callback_1: if (ENTITY_PARAM(0, 7)) { setCallback(2); - setup_function20(); + setup_ivoComeHere(); break; } label_callback_2: if (ENTITY_PARAM(0, 8) || ENTITY_PARAM(0, 5)) { setCallback(3); - setup_function21(); + setup_ivoClearTableC(); } break; @@ -442,12 +442,12 @@ label_callback_2: IMPLEMENT_FUNCTION_END ////////////////////////////////////////////////////////////////////////// -IMPLEMENT_FUNCTION(19, Waiter2, function19) +IMPLEMENT_FUNCTION(19, Waiter2, tatianaClearTableB) serveTable(savepoint, "969", kEntityTables1, "005H2", "018A", "971", &ENTITY_PARAM(0, 6), 63); IMPLEMENT_FUNCTION_END ////////////////////////////////////////////////////////////////////////// -IMPLEMENT_FUNCTION(20, Waiter2, function20) +IMPLEMENT_FUNCTION(20, Waiter2, ivoComeHere) switch (savepoint.action) { default: break; @@ -473,7 +473,7 @@ IMPLEMENT_FUNCTION(20, Waiter2, function20) IMPLEMENT_FUNCTION_END ////////////////////////////////////////////////////////////////////////// -IMPLEMENT_FUNCTION(21, Waiter2, function21) +IMPLEMENT_FUNCTION(21, Waiter2, ivoClearTableC) serveTable(savepoint, "974", kEntityTables2, "009F2", "009G", "976", &ENTITY_PARAM(0, 8), 0, true, &ENTITY_PARAM(0, 5)); IMPLEMENT_FUNCTION_END @@ -484,7 +484,7 @@ IMPLEMENT_FUNCTION(22, Waiter2, chapter3) break; case kActionNone: - setup_chapter3Handler(); + setup_serving3(); break; case kActionDefault: @@ -503,7 +503,7 @@ IMPLEMENT_FUNCTION(22, Waiter2, chapter3) IMPLEMENT_FUNCTION_END ////////////////////////////////////////////////////////////////////////// -IMPLEMENT_FUNCTION(23, Waiter2, chapter3Handler) +IMPLEMENT_FUNCTION(23, Waiter2, serving3) if (savepoint.action != kActionNone) return; @@ -512,18 +512,18 @@ IMPLEMENT_FUNCTION(23, Waiter2, chapter3Handler) if (ENTITY_PARAM(1, 1)) { setCallback(1); - setup_function24(); + setup_annaBringTea3(); return; } if (ENTITY_PARAM(1, 2)) { setCallback(2); - setup_function7(); + setup_monsieurServeUs(); } IMPLEMENT_FUNCTION_END ////////////////////////////////////////////////////////////////////////// -IMPLEMENT_FUNCTION(24, Waiter2, function24) +IMPLEMENT_FUNCTION(24, Waiter2, annaBringTea3) serveSalon(savepoint, "927", "Ann3143A", kEntityAnna, "Ann31444", "112C", kAction122288808, "928", &ENTITY_PARAM(1, 1)); IMPLEMENT_FUNCTION_END @@ -534,7 +534,7 @@ IMPLEMENT_FUNCTION(25, Waiter2, chapter4) break; case kActionNone: - setup_chapter4Handler(); + setup_serving4(); break; case kActionDefault: @@ -556,7 +556,7 @@ IMPLEMENT_FUNCTION(25, Waiter2, chapter4) IMPLEMENT_FUNCTION_END ////////////////////////////////////////////////////////////////////////// -IMPLEMENT_FUNCTION(26, Waiter2, chapter4Handler) +IMPLEMENT_FUNCTION(26, Waiter2, serving4) switch (savepoint.action) { default: break; @@ -574,19 +574,19 @@ IMPLEMENT_FUNCTION(26, Waiter2, chapter4Handler) if (ENTITY_PARAM(1, 5)) { setCallback(2); - setup_function28(); + setup_serveAugustADrink(); break; } if (ENTITY_PARAM(1, 4)) { setCallback(3); - setup_function29(); + setup_annaNeedsADrink(); break; } if (ENTITY_PARAM(1, 2)) { setCallback(4); - setup_function7(); + setup_monsieurServeUs(); } break; @@ -608,17 +608,17 @@ IMPLEMENT_FUNCTION(26, Waiter2, chapter4Handler) IMPLEMENT_FUNCTION_END ////////////////////////////////////////////////////////////////////////// -IMPLEMENT_FUNCTION(27, Waiter2, function27) +IMPLEMENT_FUNCTION(27, Waiter2, augustNeedsADrink) serveSalon(savepoint, "929", "", kEntityAugust, "Aug4003", "122D", kAction134486752, "930", &ENTITY_PARAM(1, 3)); IMPLEMENT_FUNCTION_END ////////////////////////////////////////////////////////////////////////// -IMPLEMENT_FUNCTION(28, Waiter2, function28) +IMPLEMENT_FUNCTION(28, Waiter2, serveAugustADrink) serveSalon(savepoint, "931", "", kEntityAugust, "Aug4004", "122E", kAction125826561, "930", &ENTITY_PARAM(1, 5)); IMPLEMENT_FUNCTION_END ////////////////////////////////////////////////////////////////////////// -IMPLEMENT_FUNCTION(29, Waiter2, function29) +IMPLEMENT_FUNCTION(29, Waiter2, annaNeedsADrink) serveSalon(savepoint, "932", "", kEntityAnna, "Ann4151", "127D", kAction122288808, "930", &ENTITY_PARAM(1, 4)); IMPLEMENT_FUNCTION_END diff --git a/engines/lastexpress/entities/waiter2.h b/engines/lastexpress/entities/waiter2.h index 0ed85cd1a0..e8dc8f48e0 100644 --- a/engines/lastexpress/entities/waiter2.h +++ b/engines/lastexpress/entities/waiter2.h @@ -80,24 +80,19 @@ public: */ DECLARE_FUNCTION_1(playSound, const char *filename) - DECLARE_FUNCTION(function7) + DECLARE_FUNCTION(monsieurServeUs) /** * Setup Chapter 1 */ DECLARE_FUNCTION(chapter1) - DECLARE_FUNCTION(function9) - DECLARE_FUNCTION(function10) - DECLARE_FUNCTION(function11) - DECLARE_FUNCTION(function12) - DECLARE_FUNCTION(function13) - - /** - * Handle Chapter 1 events - */ - DECLARE_FUNCTION(chapter1Handler) - + DECLARE_FUNCTION(milosOrder) + DECLARE_FUNCTION(monsieurOrder) + DECLARE_FUNCTION(clearAlexei) + DECLARE_FUNCTION(clearMilos) + DECLARE_FUNCTION(clearMonsieur) + DECLARE_FUNCTION(servingDinner) DECLARE_FUNCTION(function15) DECLARE_FUNCTION(function16) @@ -105,41 +100,26 @@ public: * Setup Chapter 2 */ DECLARE_FUNCTION(chapter2) - - /** - * Handle Chapter 2 events - */ - DECLARE_FUNCTION(chapter2Handler) - - DECLARE_FUNCTION(function19) - DECLARE_FUNCTION(function20) - DECLARE_FUNCTION(function21) + DECLARE_FUNCTION(inKitchen) + DECLARE_FUNCTION(tatianaClearTableB) + DECLARE_FUNCTION(ivoComeHere) + DECLARE_FUNCTION(ivoClearTableC) /** * Setup Chapter 3 */ DECLARE_FUNCTION(chapter3) - - /** - * Handle Chapter 3 events - */ - DECLARE_FUNCTION(chapter3Handler) - - DECLARE_FUNCTION(function24) + DECLARE_FUNCTION(serving3) + DECLARE_FUNCTION(annaBringTea3) /** * Setup Chapter 4 */ DECLARE_FUNCTION(chapter4) - - /** - * Handle Chapter 4 events - */ - DECLARE_FUNCTION(chapter4Handler) - - DECLARE_FUNCTION(function27) - DECLARE_FUNCTION(function28) - DECLARE_FUNCTION(function29) + DECLARE_FUNCTION(serving4) + DECLARE_FUNCTION(augustNeedsADrink) + DECLARE_FUNCTION(serveAugustADrink) + DECLARE_FUNCTION(annaNeedsADrink) /** * Setup Chapter 5 |