| 16618 | } |
| 16619 | |
| 16620 | int16 cFodder::intro_Play() { |
| 16621 | |
| 16622 | mGraphics->Load_Sprite_Font(); |
| 16623 | mGraphics->SetActiveSpriteSheet(eGFX_Types::eGFX_FONT); |
| 16624 | |
| 16625 | for (word_3B2CF = 1; mVersionCurrent->getIntroData()->at(word_3B2CF).mImageNumber != 0; ++word_3B2CF) { |
| 16626 | |
| 16627 | mIntro_PlayTextDuration = 0x12C; |
| 16628 | |
| 16629 | mSurface->palette_SetToBlack(); |
| 16630 | |
| 16631 | if (mVersionCurrent->getIntroData()->at(word_3B2CF).mImageNumber == 0 && mVersionCurrent->getIntroData()->at(word_3B2CF).mText == 0) |
| 16632 | break; |
| 16633 | |
| 16634 | if (mVersionCurrent->getIntroData()->at(word_3B2CF).mImageNumber != 0xFF) { |
| 16635 | |
| 16636 | std::stringstream ImageName; |
| 16637 | ImageName << (char)mVersionCurrent->getIntroData()->at(word_3B2CF).mImageNumber; |
| 16638 | |
| 16639 | mGraphics->Load_And_Draw_Image(ImageName.str(), 0xD0); |
| 16640 | } |
| 16641 | else { |
| 16642 | mIntro_PlayTextDuration = 0x96; |
| 16643 | mSurface->clearBuffer(); |
| 16644 | } |
| 16645 | |
| 16646 | mGraphics->PaletteSet(); |
| 16647 | const sIntroString* IntroString = mVersionCurrent->getIntroData()->at(word_3B2CF).mText; |
| 16648 | if (IntroString) { |
| 16649 | while (IntroString->mPosition) { |
| 16650 | |
| 16651 | Intro_Print_String(IntroString); |
| 16652 | ++IntroString; |
| 16653 | } |
| 16654 | } |
| 16655 | //loc_16710 |
| 16656 | |
| 16657 | int16 Duration = mIntro_PlayTextDuration; |
| 16658 | bool DoBreak = false; |
| 16659 | |
| 16660 | mSurface->Save(); |
| 16661 | |
| 16662 | while (mSurface->isPaletteAdjusting() || DoBreak == false) { |
| 16663 | |
| 16664 | if (mSurface->isPaletteAdjusting()) { |
| 16665 | mSurface->palette_FadeTowardNew(); |
| 16666 | if (!DoBreak) { |
| 16667 | Video_Sleep(); |
| 16668 | Video_Sleep(); |
| 16669 | Video_Sleep(); |
| 16670 | continue; |
| 16671 | } |
| 16672 | } |
| 16673 | |
| 16674 | if (Duration) { |
| 16675 | --Duration; |
| 16676 | if (mMouseButtonStatus) { |
| 16677 |
nothing calls this directly
no test coverage detected