aboutsummaryrefslogtreecommitdiff
path: root/engines/avalanche
diff options
context:
space:
mode:
authoruruk2013-08-12 17:23:39 +0200
committeruruk2013-08-12 17:23:39 +0200
commit31a165c7006a548c5fc79837ba1854dd72d23087 (patch)
treeb2a68a5c8233624310e212c644ca38fec5b85138 /engines/avalanche
parent24312c45f88b8d948251f7958c73f589a1c34771 (diff)
downloadscummvm-rg350-31a165c7006a548c5fc79837ba1854dd72d23087.tar.gz
scummvm-rg350-31a165c7006a548c5fc79837ba1854dd72d23087.tar.bz2
scummvm-rg350-31a165c7006a548c5fc79837ba1854dd72d23087.zip
AVALANCHE: Repair constants in Gyro, repair Lucerna::enterroom(), Trip::back_and_forth(), Trip::geida_procs(), Visa::talkto().
Diffstat (limited to 'engines/avalanche')
-rw-r--r--engines/avalanche/gyro2.h56
-rw-r--r--engines/avalanche/lucerna2.cpp4
-rw-r--r--engines/avalanche/trip6.cpp18
-rw-r--r--engines/avalanche/visa2.cpp4
4 files changed, 41 insertions, 41 deletions
diff --git a/engines/avalanche/gyro2.h b/engines/avalanche/gyro2.h
index 390011c41e..03c2ef4fa3 100644
--- a/engines/avalanche/gyro2.h
+++ b/engines/avalanche/gyro2.h
@@ -309,38 +309,38 @@ public:
static const char chastity = 5;
static const char bolt = 6;
static const char crossbow = 7;
- static const char lute = 10;
- static const char badge = 11;
- static const char mushroom = 12;
- static const char key = 13;
- static const char bell = 14;
- static const char prescription = 15;
- static const char pen = 16;
- static const char ink = 17;
- static const char clothes = 20;
- static const char habit = 21;
- static const char onion = 22;
+ static const char lute = 8;
+ static const char badge = 9;
+ static const char mushroom = 10;
+ static const char key = 11;
+ static const char bell = 12;
+ static const char prescription = 13;
+ static const char pen = 14;
+ static const char ink = 15;
+ static const char clothes = 16;
+ static const char habit = 17;
+ static const char onion = 18;
/* People who hang around this game. */
/* Boys: */
- static const uint16 pavalot = 226;
- static const uint16 pspludwick = 227;
- static const uint16 pcrapulus = 230;
- static const uint16 pdrduck = 231;
- static const uint16 pmalagauche = 232;
- static const uint16 pfriartuck = 233;
- static const uint16 probinhood = 234;
- static const uint16 pcwytalot = 235;
- static const uint16 pdulustie = 236;
- static const uint16 pduke = 237;
- static const uint16 pdogfood = 240;
- static const uint16 ptrader = 241;
- static const uint16 pibythneth = 242;
- static const uint16 payles = 243;
- static const uint16 pport = 244;
- static const uint16 pspurge = 245;
- static const uint16 pjacques = 246;
+ static const uint16 pavalot = 150;
+ static const uint16 pspludwick = 151;
+ static const uint16 pcrapulus = 152;
+ static const uint16 pdrduck = 153;
+ static const uint16 pmalagauche = 154;
+ static const uint16 pfriartuck = 155;
+ static const uint16 probinhood = 156;
+ static const uint16 pcwytalot = 157;
+ static const uint16 pdulustie = 158;
+ static const uint16 pduke = 159;
+ static const uint16 pdogfood = 160;
+ static const uint16 ptrader = 161;
+ static const uint16 pibythneth = 162;
+ static const uint16 payles = 163;
+ static const uint16 pport = 164;
+ static const uint16 pspurge = 165;
+ static const uint16 pjacques = 166;
/* Girls: */
static const uint16 parkata = 257;
diff --git a/engines/avalanche/lucerna2.cpp b/engines/avalanche/lucerna2.cpp
index e996d5706d..c8863b343b 100644
--- a/engines/avalanche/lucerna2.cpp
+++ b/engines/avalanche/lucerna2.cpp
@@ -442,8 +442,8 @@ void Lucerna::enterroom(byte x, byte ped) {
_vm->_trip->tr[1].face = 3;
}
- _vm->_trip->tr[2].call_eachstep = true;
- _vm->_trip->tr[2].eachstep = _vm->_trip->procface_avvy; /* He always faces Avvy. */
+ _vm->_trip->tr[1].call_eachstep = true;
+ _vm->_trip->tr[1].eachstep = _vm->_trip->procface_avvy; /* He always faces Avvy. */
} else _vm->_gyro->whereis[_vm->_gyro->pcrapulus] = r__nowhere;
diff --git a/engines/avalanche/trip6.cpp b/engines/avalanche/trip6.cpp
index 510d6e5b1f..dfcdd5ce20 100644
--- a/engines/avalanche/trip6.cpp
+++ b/engines/avalanche/trip6.cpp
@@ -1192,7 +1192,7 @@ void Trip::back_and_forth(byte tripnum) {
void Trip::face_avvy(byte tripnum) {
if (!tr[tripnum].homing) {
- if (tr[1].x >= tr[tripnum].x)
+ if (tr[0].x >= tr[tripnum].x)
tr[tripnum].face = right;
else
tr[tripnum].face = left;
@@ -1306,19 +1306,19 @@ void Trip::spin(byte whichway, byte &tripnum) {
void Trip::geida_procs(byte tripnum) {
if (_vm->_gyro->dna.geida_time > 0) {
- _vm->_gyro->dna.geida_time -= 1;
+ _vm->_gyro->dna.geida_time --;
if (_vm->_gyro->dna.geida_time == 0)
_vm->_gyro->dna.geida_spin = 0;
}
- if (tr[tripnum].y < (tr[1].y - 2)) {
+ if (tr[tripnum].y < (tr[0].y - 2)) {
/* Geida is further from the screen than Avvy. */
spin(down, tripnum);
tr[tripnum].iy = 1;
tr[tripnum].ix = 0;
take_a_step(tripnum);
return;
- } else if (tr[tripnum].y > (tr[1].y + 2)) {
+ } else if (tr[tripnum].y > (tr[0].y + 2)) {
/* Avvy is further from the screen than Geida. */
spin(up, tripnum);
tr[tripnum].iy = -1;
@@ -1328,12 +1328,14 @@ void Trip::geida_procs(byte tripnum) {
}
tr[tripnum].iy = 0;
- if (tr[tripnum].x < tr[1].x - tr[1].xs * 8) {
- tr[tripnum].ix = tr[1].xs;
+ // These 12-s are not in the original, I added them to make the following method more "smooth".
+ // Now the NPC which is following Avvy won't block his way and will walk next to him properly.
+ if (tr[tripnum].x < tr[0].x - tr[0].xs * 8 - 12) {
+ tr[tripnum].ix = tr[0].xs;
spin(right, tripnum);
take_a_step(tripnum);
- } else if (tr[tripnum].x > tr[1].x + tr[1].xs * 8) {
- tr[tripnum].ix = -tr[1].xs;
+ } else if (tr[tripnum].x > tr[0].x + tr[0].xs * 8 + 12) {
+ tr[tripnum].ix = -tr[0].xs;
spin(left, tripnum);
take_a_step(tripnum);
} else
diff --git a/engines/avalanche/visa2.cpp b/engines/avalanche/visa2.cpp
index 082b07a7b6..4a6fbc7159 100644
--- a/engines/avalanche/visa2.cpp
+++ b/engines/avalanche/visa2.cpp
@@ -172,7 +172,6 @@ void Visa::talkto(byte whom) {
if (_vm->_gyro->subjnumber == 0)
switch (whom) {
case _vm->_gyro->pspludwick:
-
if ((_vm->_gyro->dna.lustie_is_asleep) & (!_vm->_gyro->dna.obj[_vm->_gyro->potion])) {
dixi('q', 68);
_vm->_gyro->dna.obj[_vm->_gyro->potion] = true;
@@ -202,7 +201,6 @@ void Visa::talkto(byte whom) {
}
}
break;
-
case _vm->_gyro->pibythneth:
if (_vm->_gyro->dna.givenbadgetoiby) {
dixi('q', 33); // Thanks a lot!
@@ -277,7 +275,7 @@ void Visa::talkto(byte whom) {
if (!went_ok)
dixi('n', whom); // File not found!
- if ((_vm->_gyro->subjnumber == 0) && ((whom + 227) == _vm->_gyro->pcrapulus)) { // Crapulus: get the badge - first time only
+ if ((_vm->_gyro->subjnumber == 0) && ((whom + 149) == _vm->_gyro->pcrapulus)) { // Crapulus: get the badge - first time only
_vm->_gyro->dna.obj[_vm->_gyro->badge] = true;
_vm->_lucerna->objectlist();
dixi('q', 1); // Circular from Cardiff.