MYST3: Turn some platform checks into generic checks

This commit is contained in:
Bastien Bouclet 2014-09-14 13:51:45 +02:00
parent b900deb530
commit 402517fbee
2 changed files with 4 additions and 4 deletions

View File

@ -309,7 +309,7 @@ void Menu::goToNode(uint16 node) {
_vm->_state->setSoundScriptsSuspended(1);
}
if (_vm->getPlatform() != Common::kPlatformXbox) {
if (_vm->_state->hasVarMenuEscapePressed()) {
// This variable does not exist in the Xbox version
_vm->_state->setMenuEscapePressed(0);
}

View File

@ -427,7 +427,7 @@ void Myst3Engine::processInput(bool lookOnly) {
// Process events
Common::Event event;
if (getPlatform() == Common::kPlatformXbox) {
if (_state->hasVarGamePadUpPressed()) {
// Reset the gamepad directions once they had a chance to be read by the scripts
// This combined with keyboard repeat ensures the menu does not scroll too fast
_state->setGamePadUpPressed(false);
@ -437,7 +437,7 @@ void Myst3Engine::processInput(bool lookOnly) {
}
while (getEventManager()->pollEvent(event)) {
if (getPlatform() == Common::kPlatformXbox) {
if (_state->hasVarGamePadUpPressed()) {
processEventForGamepad(event);
}
@ -474,7 +474,7 @@ void Myst3Engine::processInput(bool lookOnly) {
_inputEscapePressed = true;
// Open main menu
if (getPlatform() != Common::kPlatformXbox) {
if (_state->hasVarMenuEscapePressed()) {
if (_cursor->isVisible()) {
if (_state->getLocationRoom() != 901)
_menu->goToNode(100);