mirror of
https://github.com/libretro/scummvm.git
synced 2025-01-24 19:45:07 +00:00
DRASCULA: Fix animations speed
To time animations the original engine uses interrupt to get the Real Time Clock and divides the number of clock ticks by 0.182. Since there is approximately 18.2 ticks per second, this means it uses values in 1/100th of a second. In ScummVM we were using getMillis() / 20, so the animations was two times slower than in the original. This might fix bug #7115 Drascula: FPS are incorrect or some frames are dropped. Note that for the walk animation we are still not exactly using the timing of the original. The original engines keeps each walk frames for 5.7 times 1/100th of a second (i.e. 17.54 FPS). In ScummVM getTime returns an integer value and as a result each walk frame is now kept for 6 times 1/100th of a second (i.e. 16.67 FPS, which i better than the 8.33 FPS we were getting before this commit). as our getTime returns integer values and thus we use frames for 6 of 1/100th of a second while the original is slightly faster as it kept frames for 5.7 times 1/100th of a second.
This commit is contained in:
parent
eef8371432
commit
6dcaef191c
@ -891,7 +891,7 @@ void DrasculaEngine::pause(int duration) {
|
||||
}
|
||||
|
||||
int DrasculaEngine::getTime() {
|
||||
return _system->getMillis() / 20; // originally was 1
|
||||
return _system->getMillis() / 10;
|
||||
}
|
||||
|
||||
void DrasculaEngine::reduce_hare_chico(int xx1, int yy1, int xx2, int yy2, int width, int height, int factor, byte *dir_inicio, byte *dir_fin) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user