diff options
author | Travis Howell | 2003-12-14 14:19:43 +0000 |
---|---|---|
committer | Travis Howell | 2003-12-14 14:19:43 +0000 |
commit | 9d1f4842a59133a7f3be2e57b1c74d6e4ac1f86c (patch) | |
tree | a915cc788f4d02bc25413f4710bd3b70b0c4c048 /scumm | |
parent | 470ca24df565e97b201ae23cc92de14922fbe6a0 (diff) | |
download | scummvm-rg350-9d1f4842a59133a7f3be2e57b1c74d6e4ac1f86c.tar.gz scummvm-rg350-9d1f4842a59133a7f3be2e57b1c74d6e4ac1f86c.tar.bz2 scummvm-rg350-9d1f4842a59133a7f3be2e57b1c74d6e4ac1f86c.zip |
Reset actors in restart()
svn-id: r11632
Diffstat (limited to 'scumm')
-rw-r--r-- | scumm/scummvm.cpp | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/scumm/scummvm.cpp b/scumm/scummvm.cpp index aa51f04f31..44476cc6e4 100644 --- a/scumm/scummvm.cpp +++ b/scumm/scummvm.cpp @@ -2501,6 +2501,18 @@ void ScummEngine::restart() { for (i = 0; i < _numGlobalObjects; i++) clearOwnerOf(i); + // Reallocate and Reinitialize actors + Actor::initActorClass(this); + _actors = new Actor[_numActors]; + for (i = 0; i < _numActors; i++) { + _actors[i].number = i; + _actors[i].initActor(1); + + // this is from IDB + if (_version == 1) + _actors[i].setActorCostume(i); + } + // Reinit things allocateArrays(); // Reallocate arrays readIndexFile(); // Reread index (reset objectstate etc) |