reorder a bit to allow draw some debug stuff at actors update

This commit is contained in:
Pawel Kolodziejski 2008-09-26 11:57:56 +00:00
parent d5777f6764
commit f5d455b561

View file

@ -465,24 +465,10 @@ void Engine::updateDisplayScene() {
if (!_currScene) if (!_currScene)
return; return;
// Update actor costumes & sets g_driver->clearScreen();
for (ActorListType::iterator i = _actors.begin(); i != _actors.end(); i++) {
Actor *a = *i;
// Update the actor's costumes & chores
g_currentUpdatedActor = *i;
// Note that the actor need not be visible to update chores, for example:
// when Manny has just brought Meche back he is offscreen several times
// when he needs to perform certain chores
if (a->inSet(_currScene->name()))
a->update();
}
g_currentUpdatedActor = NULL;
_prevSmushFrame = 0; _prevSmushFrame = 0;
g_driver->clearScreen();
_currScene->drawBackground(); _currScene->drawBackground();
// Draw underlying scene components // Draw underlying scene components
@ -520,6 +506,20 @@ void Engine::updateDisplayScene() {
_currScene->setupLights(); _currScene->setupLights();
// Update actor costumes & sets
for (ActorListType::iterator i = _actors.begin(); i != _actors.end(); i++) {
Actor *a = *i;
// Update the actor's costumes & chores
g_currentUpdatedActor = *i;
// Note that the actor need not be visible to update chores, for example:
// when Manny has just brought Meche back he is offscreen several times
// when he needs to perform certain chores
if (a->inSet(_currScene->name()))
a->update();
}
g_currentUpdatedActor = NULL;
// Draw actors // Draw actors
for (ActorListType::iterator i = _actors.begin(); i != _actors.end(); i++) { for (ActorListType::iterator i = _actors.begin(); i != _actors.end(); i++) {
Actor *a = *i; Actor *a = *i;