MOHAWK: Stub off Riven transition speed code

This commit is contained in:
Matthew Hoops 2011-08-15 22:53:02 -04:00
parent 6f83052b40
commit fcd84f67c8
5 changed files with 15 additions and 1 deletions

View File

@ -921,7 +921,8 @@ void RivenGraphics::clearMainScreen() {
}
void RivenGraphics::fadeToBlack() {
// Self-explanatory
// The transition speed is forced to best here
setTransitionSpeed(kRivenTransitionSpeedBest);
scheduleTransition(16);
clearMainScreen();
runScheduledTransition();

View File

@ -196,6 +196,7 @@ public:
void scheduleTransition(uint16 id, Common::Rect rect = Common::Rect(0, 0, 608, 392));
void runScheduledTransition();
void fadeToBlack();
void setTransitionSpeed(uint32 speed) { _transitionSpeed = speed; }
// Inventory
void showInventory();
@ -231,6 +232,7 @@ private:
// Transitions
int16 _scheduledTransition;
Common::Rect _transitionRect;
uint32 _transitionSpeed;
// Inventory
void clearInventoryArea();

View File

@ -150,6 +150,9 @@ Common::Error MohawkEngine_Riven::run() {
return Common::kNoGameDataFoundError;
}
// Set the transition speed
_gfx->setTransitionSpeed(_vars["transitionmode"]);
// Start at main cursor
_cursor->setCursor(kRivenMainCursor);
_cursor->showCursor();

View File

@ -67,6 +67,13 @@ enum {
StackNames = 5
};
enum RivenTransitionSpeed {
kRivenTransitionSpeedNone = 5000,
kRivenTransitionSpeedFastest = 5001,
kRivenTransitionSpeedNormal = 5002,
kRivenTransitionSpeedBest = 5003
};
// Rects for the inventory object positions (initialized in
// MohawkEngine_Riven's constructor).
extern Common::Rect *g_atrusJournalRect1;

View File

@ -304,6 +304,7 @@ void MohawkEngine_Riven::initVars() {
_vars["bmagcar"] = 1;
_vars["gnmagcar"] = 1;
_vars["omusicplayer"] = 1;
_vars["transitionmode"] = kRivenTransitionSpeedFastest;
// Randomize the telescope combination
uint32 &teleCombo = _vars["tcorrectorder"];