mirror of
https://github.com/libretro/scummvm.git
synced 2025-01-27 21:54:15 +00:00
NANCY: Show partner logo on game start
Games after nancy2 had a second logo that appeared on startup, which is now also shown.
This commit is contained in:
parent
53e548c818
commit
f3b5237a82
@ -418,12 +418,21 @@ void NancyEngine::bootGameEngine() {
|
||||
_imageChunks.setVal("FR0", boot->getChunkStream("FR0"));
|
||||
_imageChunks.setVal("LG0", boot->getChunkStream("LG0"));
|
||||
|
||||
auto *chunkStream = boot->getChunkStream("PLG0");
|
||||
if (!chunkStream) {
|
||||
chunkStream = boot->getChunkStream("PLGO"); // nancy4 and above use an O instead of a zero
|
||||
}
|
||||
|
||||
if (chunkStream) {
|
||||
_imageChunks.setVal("PLG0", chunkStream);
|
||||
}
|
||||
|
||||
_cursorManager->init(boot->getChunkStream("CURS"));
|
||||
|
||||
_graphicsManager->init();
|
||||
_graphicsManager->loadFonts(boot->getChunkStream("FONT"));
|
||||
|
||||
auto *chunkStream = boot->getChunkStream("MAP");
|
||||
chunkStream = boot->getChunkStream("MAP");
|
||||
if (chunkStream) {
|
||||
_mapData = new MAP(chunkStream);
|
||||
}
|
||||
|
@ -84,6 +84,11 @@ void Logo::init() {
|
||||
_logoImage.init(g_nancy->_imageChunks["LG0"].imageName);
|
||||
_logoImage.registerGraphics();
|
||||
|
||||
if (g_nancy->_imageChunks.contains("PLG0")) {
|
||||
_partnerLogoImage.init(g_nancy->_imageChunks["PLG0"].imageName);
|
||||
_partnerLogoImage.registerGraphics();
|
||||
}
|
||||
|
||||
if (g_nancy->getGameType() == kGameTypeVampire && _tvdVideoDecoder.loadFile("VAMPINTR.AVI")) {
|
||||
_tvdVideoDecoder.start();
|
||||
_videoObj.moveTo(Common::Rect(0, 0, 640, 480));
|
||||
@ -120,8 +125,18 @@ void Logo::startSound() {
|
||||
}
|
||||
|
||||
void Logo::run() {
|
||||
if ((g_nancy->getTotalPlayTime() - _startTicks >= g_nancy->getStaticData().logoEndAfter) ||
|
||||
(g_nancy->_input->getInput().input & NancyInput::kLeftMouseButtonDown)) {
|
||||
if (g_nancy->getTotalPlayTime() - _startTicks >= g_nancy->getStaticData().logoEndAfter) {
|
||||
// Display game logo after partner logo
|
||||
if (!_partnerLogoImage._drawSurface.empty() && _partnerLogoImage.isVisible()) {
|
||||
_logoImage.setVisible(true);
|
||||
_partnerLogoImage.setVisible(false);
|
||||
_startTicks = g_nancy->getTotalPlayTime();
|
||||
} else {
|
||||
_state = kStop;
|
||||
}
|
||||
}
|
||||
|
||||
if (g_nancy->_input->getInput().input & NancyInput::kLeftMouseButtonDown) {
|
||||
_state = kStop;
|
||||
}
|
||||
}
|
||||
|
@ -60,6 +60,7 @@ private:
|
||||
State _state;
|
||||
uint _startTicks;
|
||||
UI::FullScreenImage _logoImage;
|
||||
UI::FullScreenImage _partnerLogoImage;
|
||||
SoundDescription _msnd;
|
||||
Video::AVIDecoder _tvdVideoDecoder;
|
||||
RenderObject _videoObj;
|
||||
|
Loading…
x
Reference in New Issue
Block a user