diff options
author | Thanasis Antoniou | 2019-07-11 15:35:58 +0300 |
---|---|---|
committer | Thanasis Antoniou | 2019-07-11 16:15:05 +0300 |
commit | e0da90cdb8640461a2b0518cbe6834c4bdee446c (patch) | |
tree | 89ee505614e26d5d6d04030231a53fe899fc18c5 /engines | |
parent | 0195599ea25306a8a612875322a130826109785a (diff) | |
download | scummvm-rg350-e0da90cdb8640461a2b0518cbe6834c4bdee446c.tar.gz scummvm-rg350-e0da90cdb8640461a2b0518cbe6834c4bdee446c.tar.bz2 scummvm-rg350-e0da90cdb8640461a2b0518cbe6834c4bdee446c.zip |
BLADERUNNER: No rats when Lucy is in UG01
Diffstat (limited to 'engines')
-rw-r--r-- | engines/bladerunner/script/ai/free_slot_a.cpp | 28 | ||||
-rw-r--r-- | engines/bladerunner/script/ai/free_slot_b.cpp | 28 | ||||
-rw-r--r-- | engines/bladerunner/script/ai/lucy.cpp | 2 |
3 files changed, 53 insertions, 5 deletions
diff --git a/engines/bladerunner/script/ai/free_slot_a.cpp b/engines/bladerunner/script/ai/free_slot_a.cpp index f7c4849ca6..d87663a4a1 100644 --- a/engines/bladerunner/script/ai/free_slot_a.cpp +++ b/engines/bladerunner/script/ai/free_slot_a.cpp @@ -610,13 +610,24 @@ void AIScriptFreeSlotA::goToRandomUGxx() { switch (Random_Query(1, 14)) { case 1: // kSetUG01 +#if BLADERUNNER_ORIGINAL_BUGS AI_Movement_Track_Append(kActorFreeSlotA, 450, 1); AI_Movement_Track_Append(kActorFreeSlotA, 451, 5); AI_Movement_Track_Append(kActorFreeSlotA, 450, 0); break; - +#else + // Don't put rats in UG01 when Lucy is also here + if (!Actor_Query_In_Set(kActorLucy, kSetUG01)) { + AI_Movement_Track_Append(kActorFreeSlotA, 450, 1); + AI_Movement_Track_Append(kActorFreeSlotA, 451, 5); + AI_Movement_Track_Append(kActorFreeSlotA, 450, 0); + break; + } +#endif // BLADERUNNER_ORIGINAL_BUGS + // fall through case 2: // kSetUG01 +#if BLADERUNNER_ORIGINAL_BUGS World_Waypoint_Set(463, kSetUG01, 144.98f, -50.13f, -175.75f); World_Waypoint_Set(464, kSetUG01, 105.6f, -50.13f, -578.46f); World_Waypoint_Set(465, kSetUG01, 62.0f, -50.13f, -574.0f); @@ -625,7 +636,20 @@ void AIScriptFreeSlotA::goToRandomUGxx() { AI_Movement_Track_Append(kActorFreeSlotA, 465, 5); AI_Movement_Track_Append(kActorFreeSlotA, 463, 5); break; - +#else + // Don't put rats in UG01 when Lucy is also here + if (!Actor_Query_In_Set(kActorLucy, kSetUG01)) { + World_Waypoint_Set(463, kSetUG01, 144.98f, -50.13f, -175.75f); + World_Waypoint_Set(464, kSetUG01, 105.6f, -50.13f, -578.46f); + World_Waypoint_Set(465, kSetUG01, 62.0f, -50.13f, -574.0f); + AI_Movement_Track_Append(kActorFreeSlotA, 463, 1); + AI_Movement_Track_Append(kActorFreeSlotA, 464, 1); + AI_Movement_Track_Append(kActorFreeSlotA, 465, 5); + AI_Movement_Track_Append(kActorFreeSlotA, 463, 5); + break; + } +#endif // BLADERUNNER_ORIGINAL_BUGS + // fall through case 3: // kSetUG04 AI_Movement_Track_Append(kActorFreeSlotA, 446, 15); diff --git a/engines/bladerunner/script/ai/free_slot_b.cpp b/engines/bladerunner/script/ai/free_slot_b.cpp index f945021254..ddb7f047ff 100644 --- a/engines/bladerunner/script/ai/free_slot_b.cpp +++ b/engines/bladerunner/script/ai/free_slot_b.cpp @@ -460,13 +460,24 @@ void AIScriptFreeSlotB::goToRandomUGxx() { switch (Random_Query(1, 14)) { case 1: // kSetUG01 +#if BLADERUNNER_ORIGINAL_BUGS AI_Movement_Track_Append(kActorFreeSlotB, 450, 1); AI_Movement_Track_Append(kActorFreeSlotB, 451, 5); AI_Movement_Track_Append(kActorFreeSlotB, 450, 0); break; - +#else + // Don't put rats in UG01 when Lucy is also here + if (!Actor_Query_In_Set(kActorLucy, kSetUG01)) { + AI_Movement_Track_Append(kActorFreeSlotB, 450, 1); + AI_Movement_Track_Append(kActorFreeSlotB, 451, 5); + AI_Movement_Track_Append(kActorFreeSlotB, 450, 0); + break; + } +#endif // BLADERUNNER_ORIGINAL_BUGS + // fall through case 2: // kSetUG01 +#if BLADERUNNER_ORIGINAL_BUGS World_Waypoint_Set(466, kSetUG01, 144.98f, -50.13f, -175.75f); World_Waypoint_Set(547, kSetUG01, 105.6f, -50.13f, -578.46f); World_Waypoint_Set(548, kSetUG01, 62.0f, -50.13f, -574.0f); @@ -475,7 +486,20 @@ void AIScriptFreeSlotB::goToRandomUGxx() { AI_Movement_Track_Append(kActorFreeSlotB, 548, 5); AI_Movement_Track_Append(kActorFreeSlotB, 466, 5); break; - +#else + // Don't put rats in UG01 when Lucy is also here + if (!Actor_Query_In_Set(kActorLucy, kSetUG01)) { + World_Waypoint_Set(466, kSetUG01, 144.98f, -50.13f, -175.75f); + World_Waypoint_Set(547, kSetUG01, 105.6f, -50.13f, -578.46f); + World_Waypoint_Set(548, kSetUG01, 62.0f, -50.13f, -574.0f); + AI_Movement_Track_Append(kActorFreeSlotB, 466, 1); + AI_Movement_Track_Append(kActorFreeSlotB, 547, 1); + AI_Movement_Track_Append(kActorFreeSlotB, 548, 5); + AI_Movement_Track_Append(kActorFreeSlotB, 466, 5); + break; + } +#endif // BLADERUNNER_ORIGINAL_BUGS + // fall through case 3: // kSetUG04 AI_Movement_Track_Append(kActorFreeSlotB, 446, 15); diff --git a/engines/bladerunner/script/ai/lucy.cpp b/engines/bladerunner/script/ai/lucy.cpp index 5b1b2d3a64..786d41012d 100644 --- a/engines/bladerunner/script/ai/lucy.cpp +++ b/engines/bladerunner/script/ai/lucy.cpp @@ -527,7 +527,7 @@ bool AIScriptLucy::GoalChanged(int currentGoalNumber, int newGoalNumber) { case kGoalLucyUG01RunAway: AI_Movement_Track_Flush(kActorLucy); AI_Movement_Track_Append_Run(kActorLucy, 545, 0); - AI_Movement_Track_Append(kActorLucy, 33, 0); + AI_Movement_Track_Append(kActorLucy, 33, 0); // kSetFreeSlotA AI_Movement_Track_Repeat(kActorLucy); break; |