diff --git a/engines/grim/emi/costume/emichore.cpp b/engines/grim/emi/costume/emichore.cpp index c127742a9e2..52de82dfeff 100644 --- a/engines/grim/emi/costume/emichore.cpp +++ b/engines/grim/emi/costume/emichore.cpp @@ -70,7 +70,7 @@ void EMIChore::update(uint time) { setKeys(_currTime, newTime); - if (newTime > _length) { + if (_length >= 0.0f && newTime > _length) { if (!_looping && _fadeMode != Animation::FadeOut) { stop(0); } diff --git a/engines/grim/emi/costumeemi.cpp b/engines/grim/emi/costumeemi.cpp index 9058e92fdec..76a1001dc04 100644 --- a/engines/grim/emi/costumeemi.cpp +++ b/engines/grim/emi/costumeemi.cpp @@ -61,7 +61,9 @@ void EMICostume::load(Common::SeekableReadStream *data) { float length = get_float(f); int numTracks = data->readUint32LE(); - if (length < 1000) + if (length == 1000) + length = -1.0f; + else length *= 1000; EMIChore *chore = new EMIChore(name, i, this, (int)length, numTracks); @@ -114,10 +116,6 @@ void EMICostume::load(Common::SeekableReadStream *data) { } delete[] componentName; } - - // Some chores report duration 1000 while they have components with - // keyframes after 1000. See elaine_wedding/take_contract, for example. - chore->_length = ceil(length); } _numComponents = components.size();