mirror of
https://github.com/libretro/scummvm.git
synced 2024-12-14 05:38:56 +00:00
MM: MM1: Disable mapping in desert without in-game map
This commit is contained in:
parent
bbe41fab0f
commit
9841e90372
@ -587,6 +587,7 @@ enhdialogs:
|
||||
south: "South"
|
||||
east: "East"
|
||||
west: "West"
|
||||
disabled: "Mapping is currently unavailable here"
|
||||
market:
|
||||
title: "Market"
|
||||
buy_food: "Buy food"
|
||||
|
@ -79,13 +79,6 @@ public:
|
||||
* Handles all special stuff that happens on the map
|
||||
*/
|
||||
void special() override;
|
||||
|
||||
/**
|
||||
* This map has some random spinners, so we want to
|
||||
* disable mapping in enhanced mode to avoid spoiling
|
||||
* the surprise
|
||||
*/
|
||||
bool mappingAllowed() const override { return false; }
|
||||
};
|
||||
|
||||
} // namespace Maps
|
||||
|
@ -76,7 +76,10 @@ bool Game::msgAction(const ActionMessage &msg) {
|
||||
send("Bash", GameMessage("SHOW"));
|
||||
break;
|
||||
case KEYBIND_MAP:
|
||||
addView("MapPopup");
|
||||
if (g_maps->_currentMap->mappingAllowed())
|
||||
addView("MapPopup");
|
||||
else
|
||||
send(InfoMessage(STRING["enhdialogs.map.disabled"]));
|
||||
return true;
|
||||
case KEYBIND_MENU:
|
||||
g_engine->openMainMenuDialog();
|
||||
|
@ -67,6 +67,11 @@ bool GameCommands::msgAction(const ActionMessage & msg) {
|
||||
return false;
|
||||
}
|
||||
|
||||
void GameCommands::Minimap::draw() {
|
||||
if (_minimapOn && g_maps->_currentMap->mappingAllowed())
|
||||
Map::draw();
|
||||
}
|
||||
|
||||
} // namespace ViewsEnh
|
||||
} // namespace MM1
|
||||
} // namespace MM
|
||||
|
@ -42,10 +42,7 @@ class GameCommands : public ButtonContainer {
|
||||
_minimapOn = !_minimapOn;
|
||||
g_events->redraw();
|
||||
}
|
||||
void draw() override {
|
||||
if (_minimapOn)
|
||||
Map::draw();
|
||||
}
|
||||
void draw() override;
|
||||
};
|
||||
|
||||
private:
|
||||
|
Loading…
Reference in New Issue
Block a user