patch #689164 comi verb coin hack by erik, fixes the verb coin drawing behind the inventory

svn-id: r6642
This commit is contained in:
Jonathan Gray 2003-02-27 10:17:29 +00:00
parent 686ba621f7
commit af19cac738
3 changed files with 22 additions and 0 deletions

View File

@ -868,6 +868,8 @@ void Scumm::processActors()
// Make a list of all actors in this room
for (i = 1; i < NUM_ACTORS; i++) {
a = derefActor(i);
if ((_features & GF_AFTER_V8) && a->layer < 0)
continue;
if (a->isInCurrentRoom())
actors[numactors++] = a;
}
@ -903,6 +905,23 @@ void Scumm::processActors()
delete [] actors;
}
// Used in Scumm v8, to allow the verb coin to be drawn over the inventory
// chest. I'm assuming that draw order won't matter here.
void Scumm::processUpperActors()
{
Actor *a;
int i;
for (i = 1; i < NUM_ACTORS; i++) {
a = derefActor(i);
if (a->isInCurrentRoom() && a->costume && a->layer < 0) {
CHECK_HEAP getMaskFromBox(a->walkbox);
a->drawActorCostume();
CHECK_HEAP a->animateCostume();
}
}
}
void Actor::drawActorCostume()
{
if (!needRedraw)

View File

@ -673,6 +673,7 @@ public:
void setActorRedrawFlags(bool fg, bool bg);
void resetActorBgs();
void processActors();
void processUpperActors();
int getActorFromPos(int x, int y);
void actorFollowCamera(int act);

View File

@ -562,6 +562,8 @@ int Scumm::scummLoop(int delta)
}
drawBlastObjects();
if (_features & GF_AFTER_V8)
processUpperActors();
drawBlastTexts();
drawDirtyScreenParts();
removeBlastObjects();