- fixed bug #880415 (only setup bam scene after all _vm->update() calls)
- constness svn-id: r12564
This commit is contained in:
parent
d26fd46cd0
commit
ff43b1f8d5
5 changed files with 14 additions and 9 deletions
|
@ -200,7 +200,7 @@ void Graphics::setupMouseCursor() {
|
|||
_vm->display()->setMouseCursor(bf->data, bf->width, bf->height);
|
||||
}
|
||||
|
||||
void Graphics::drawBob(const BobSlot *bs, BobFrame *bf, int16 x, int16 y) {
|
||||
void Graphics::drawBob(const BobSlot *bs, const BobFrame *bf, int16 x, int16 y) {
|
||||
debug(9, "Graphics::drawBob(%d, %d, %d)", bs->frameNum, x, y);
|
||||
|
||||
uint16 w, h;
|
||||
|
@ -410,7 +410,7 @@ BobSlot *Graphics::bob(int index) {
|
|||
}
|
||||
|
||||
void Graphics::setBobText(
|
||||
BobSlot *pbs,
|
||||
const BobSlot *pbs,
|
||||
const char *text,
|
||||
int textX, int textY,
|
||||
int color, int flags) {
|
||||
|
|
|
@ -95,7 +95,7 @@ public:
|
|||
void unpackControlBank();
|
||||
void setupMouseCursor();
|
||||
|
||||
void drawBob(const BobSlot *bs, BobFrame *bf, int16 x, int16 y);
|
||||
void drawBob(const BobSlot *bs, const BobFrame *bf, int16 x, int16 y);
|
||||
void drawInventoryItem(uint32 frameNum, uint16 x, uint16 y);
|
||||
void pasteBob(uint16 objNum, uint16 image);
|
||||
void shrinkFrame(const BobFrame *bf, uint16 percentage);
|
||||
|
@ -105,7 +105,7 @@ public:
|
|||
void clearBobs();
|
||||
void stopBobs();
|
||||
BobSlot *bob(int index);
|
||||
void setBobText(BobSlot *bob, const char *text, int textX, int textY, int color, int flags);
|
||||
void setBobText(const BobSlot *bob, const char *text, int textX, int textY, int color, int flags);
|
||||
|
||||
void handleParallax(uint16 roomNum);
|
||||
|
||||
|
|
|
@ -282,6 +282,7 @@ void Journal::handleYesNoMode(int16 zoneNum) {
|
|||
switch (_prevZoneNum) {
|
||||
case ZN_REVIEW_ENTRY:
|
||||
if (_saveDescriptions[currentSlot][0]) {
|
||||
_vm->graphics()->clearBobs();
|
||||
_vm->display()->palFadeOut(0, 223, JOURNAL_ROOM);
|
||||
_vm->loadGameState(currentSlot);
|
||||
_vm->display()->clearTexts(0, GAME_SCREEN_HEIGHT - 1);
|
||||
|
|
|
@ -529,7 +529,7 @@ void Logic::displayRoom(uint16 room, RoomDisplayMode mode, uint16 scale, int com
|
|||
}
|
||||
}
|
||||
|
||||
ActorData *Logic::findActor(uint16 noun, const char *name) {
|
||||
ActorData *Logic::findActor(uint16 noun, const char *name) const {
|
||||
uint16 obj = currentRoomData() + noun;
|
||||
int16 img = objectData(obj)->image;
|
||||
if (img != -3 && img != -4) {
|
||||
|
@ -1362,9 +1362,8 @@ void Logic::loadState(uint32 ver, byte *&ptr) {
|
|||
}
|
||||
|
||||
void Logic::setupRestoredGame() {
|
||||
if (_vm->bam()->_flag != BamScene::F_STOP) {
|
||||
_vm->bam()->prepareAnimation();
|
||||
}
|
||||
uint16 flag = _vm->bam()->_flag;
|
||||
_vm->bam()->_flag = BamScene::F_STOP;
|
||||
|
||||
_vm->sound()->playSong(_vm->sound()->lastOverride());
|
||||
|
||||
|
@ -1391,6 +1390,11 @@ void Logic::setupRestoredGame() {
|
|||
_entryObj = 0;
|
||||
|
||||
inventoryRefresh();
|
||||
|
||||
if (flag != BamScene::F_STOP) {
|
||||
_vm->bam()->_flag = flag;
|
||||
_vm->bam()->prepareAnimation();
|
||||
}
|
||||
}
|
||||
|
||||
void Logic::sceneStart() {
|
||||
|
|
|
@ -128,7 +128,7 @@ public:
|
|||
int16 entryObj() const { return _entryObj; }
|
||||
void entryObj(int16 obj) { _entryObj = obj; }
|
||||
|
||||
ActorData *findActor(uint16 noun, const char *name = NULL);
|
||||
ActorData *findActor(uint16 noun, const char *name = NULL) const;
|
||||
bool initPerson(uint16 noun, const char *actorName, bool loadBank, Person *pp);
|
||||
uint16 findPersonNumber(uint16 obj) const;
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue