Skip to content

Commit

Permalink
DREAMWEB: 'realcredits' ported to C++
Browse files Browse the repository at this point in the history
  • Loading branch information
digitall committed Dec 5, 2011
1 parent 90861ce commit 78c0d07
Show file tree
Hide file tree
Showing 5 changed files with 159 additions and 142 deletions.
1 change: 1 addition & 0 deletions devtools/tasmrecover/tasm-recover
Expand Up @@ -408,6 +408,7 @@ generator = cpp(context, "DreamGen", blacklist = [
'readmouse4',
'readoneblock',
'readsetdata',
'realcredits',
'reconstruct',
'reelsonscreen',
'removeemm',
Expand Down
141 changes: 0 additions & 141 deletions engines/dreamweb/dreamgen.cpp
Expand Up @@ -2523,147 +2523,6 @@ void DreamGenContext::loadIntroRoom() {
workToScreen();
}

void DreamGenContext::realCredits() {
STACK_CHECK;
data.byte(kRoomssample) = 33;
loadRoomsSample();
data.byte(kVolume) = 0;
mode640x480();
cx = 35;
hangOn();
dx = 1113;
showPCX();
al = 12;
ah = 0;
playChannel0();
cx = 2;
hangOne();
_cmp(data.byte(kLasthardkey), 1);
if (flags.z())
goto realcreditsearly;
allPalette();
cx = 80;
hangOne();
_cmp(data.byte(kLasthardkey), 1);
if (flags.z())
goto realcreditsearly;
fadeScreenDowns();
cx = 256;
hangOne();
_cmp(data.byte(kLasthardkey), 1);
if (flags.z())
goto realcreditsearly;
dx = 1126;
showPCX();
al = 12;
ah = 0;
playChannel0();
cx = 2;
hangOne();
_cmp(data.byte(kLasthardkey), 1);
if (flags.z())
goto realcreditsearly;
allPalette();
cx = 80;
hangOne();
_cmp(data.byte(kLasthardkey), 1);
if (flags.z())
goto realcreditsearly;
fadeScreenDowns();
cx = 256;
hangOne();
_cmp(data.byte(kLasthardkey), 1);
if (flags.z())
goto realcreditsearly;
dx = 1139;
showPCX();
al = 12;
ah = 0;
playChannel0();
cx = 2;
hangOne();
_cmp(data.byte(kLasthardkey), 1);
if (flags.z())
goto realcreditsearly;
allPalette();
cx = 80;
hangOne();
_cmp(data.byte(kLasthardkey), 1);
if (flags.z())
goto realcreditsearly;
fadeScreenDowns();
cx = 256;
hangOne();
_cmp(data.byte(kLasthardkey), 1);
if (flags.z())
goto realcreditsearly;
dx = 1152;
showPCX();
al = 12;
ah = 0;
playChannel0();
cx = 2;
hangOne();
_cmp(data.byte(kLasthardkey), 1);
if (flags.z())
goto realcreditsearly;
allPalette();
cx = 80;
hangOne();
_cmp(data.byte(kLasthardkey), 1);
if (flags.z())
goto realcreditsearly;
fadeScreenDowns();
cx = 256;
hangOne();
_cmp(data.byte(kLasthardkey), 1);
if (flags.z())
goto realcreditsearly;
dx = 1165;
showPCX();
al = 12;
ah = 0;
playChannel0();
cx = 2;
hangOne();
_cmp(data.byte(kLasthardkey), 1);
if (flags.z())
goto realcreditsearly;
allPalette();
cx = 80;
hangOne();
_cmp(data.byte(kLasthardkey), 1);
if (flags.z())
goto realcreditsearly;
fadeScreenDowns();
cx = 256;
hangOne();
_cmp(data.byte(kLasthardkey), 1);
if (flags.z())
goto realcreditsearly;
dx = 1178;
showPCX();
fadeScreenUps();
cx = 60;
hangOne();
_cmp(data.byte(kLasthardkey), 1);
if (flags.z())
goto realcreditsearly;
al = 13;
ah = 0;
playChannel0();
cx = 350;
hangOne();
_cmp(data.byte(kLasthardkey), 1);
if (flags.z())
goto realcreditsearly;
fadeScreenDowns();
cx = 256;
hangOne();
realcreditsearly:
data.byte(kLasthardkey) = 0;
}

void DreamGenContext::fillOpen() {
STACK_CHECK;
delTextLine();
Expand Down
1 change: 0 additions & 1 deletion engines/dreamweb/dreamgen.h
Expand Up @@ -757,7 +757,6 @@ class DreamGenContext : public Context {
void useElvDoor();
void putBackObStuff();
void useLadder();
void realCredits();
void handClap();
void afterIntroRoom();
void findAllOpen();
Expand Down
157 changes: 157 additions & 0 deletions engines/dreamweb/stubs.cpp
Expand Up @@ -3179,5 +3179,162 @@ void DreamGenContext::bibleQuote() {
data.byte(kLasthardkey) = 0;
}

void DreamGenContext::realCredits() {
data.byte(kRoomssample) = 33;
loadRoomsSample();
data.byte(kVolume) = 0;

mode640x480();
hangOn(35);

showPCX("DREAMWEB.I01");
playChannel0(12, 0);

hangOne(2);

if (data.byte(kLasthardkey) == 1) {
data.byte(kLasthardkey) = 0;
return; // "realcreditsearly"
}

allPalette();
hangOne(80);

if (data.byte(kLasthardkey) == 1) {
data.byte(kLasthardkey) = 0;
return; // "realcreditsearly"
}

fadeScreenDowns();
hangOne(256);

if (data.byte(kLasthardkey) == 1) {
data.byte(kLasthardkey) = 0;
return; // "realcreditsearly"
}

showPCX("DREAMWEB.I02");
playChannel0(12, 0);
hangOne(2);

if (data.byte(kLasthardkey) == 1) {
data.byte(kLasthardkey) = 0;
return; // "realcreditsearly"
}

allPalette();
hangOne(80);

if (data.byte(kLasthardkey) == 1) {
data.byte(kLasthardkey) = 0;
return; // "realcreditsearly"
}

fadeScreenDowns();
hangOne(256);

if (data.byte(kLasthardkey) == 1) {
data.byte(kLasthardkey) = 0;
return; // "realcreditsearly"
}

showPCX("DREAMWEB.I03");
playChannel0(12, 0);
hangOne(2);

if (data.byte(kLasthardkey) == 1) {
data.byte(kLasthardkey) = 0;
return; // "realcreditsearly"
}

allPalette();
hangOne(80);

if (data.byte(kLasthardkey) == 1) {
data.byte(kLasthardkey) = 0;
return; // "realcreditsearly"
}

fadeScreenDowns();
hangOne(256);

if (data.byte(kLasthardkey) == 1) {
data.byte(kLasthardkey) = 0;
return; // "realcreditsearly"
}

showPCX("DREAMWEB.I04");
playChannel0(12, 0);
hangOne(2);

if (data.byte(kLasthardkey) == 1) {
data.byte(kLasthardkey) = 0;
return; // "realcreditsearly"
}

allPalette();
hangOne(80);

if (data.byte(kLasthardkey) == 1) {
data.byte(kLasthardkey) = 0;
return; // "realcreditsearly"
}

fadeScreenDowns();
hangOne(256);

if (data.byte(kLasthardkey) == 1) {
data.byte(kLasthardkey) = 0;
return; // "realcreditsearly"
}

showPCX("DREAMWEB.I05");
playChannel0(12, 0);
hangOne(2);

if (data.byte(kLasthardkey) == 1) {
data.byte(kLasthardkey) = 0;
return; // "realcreditsearly"
}

allPalette();
hangOne(80);

if (data.byte(kLasthardkey) == 1) {
data.byte(kLasthardkey) = 0;
return; // "realcreditsearly"
}

fadeScreenDowns();
hangOne(256);

if (data.byte(kLasthardkey) == 1) {
data.byte(kLasthardkey) = 0;
return; // "realcreditsearly"
}

showPCX("DREAMWEB.I06");
fadeScreenUps();
hangOne(60);

if (data.byte(kLasthardkey) == 1) {
data.byte(kLasthardkey) = 0;
return; // "realcreditsearly"
}

playChannel0(13, 0);
hangOne(350);

if (data.byte(kLasthardkey) == 1) {
data.byte(kLasthardkey) = 0;
return; // "realcreditsearly"
}

fadeScreenDowns();
hangOne(256);

data.byte(kLasthardkey) = 0;
}

} /*namespace dreamgen */

1 change: 1 addition & 0 deletions engines/dreamweb/stubs.h
Expand Up @@ -452,5 +452,6 @@
void showPCX(const ::Common::String &name);
void showPCX();
void bibleQuote();
void realCredits();

#endif

0 comments on commit 78c0d07

Please sign in to comment.