X-Git-Url: https://git.artsoft.org/?a=blobdiff_plain;f=src%2Fanim.c;fp=src%2Fanim.c;h=3e2f1222ee1bc82b0ced39b0f20c0313cef0203a;hb=baed6f0a85ade21358cde876c3c044c34749c434;hp=14dccc69c46d25a34764b0cbdbf7e18bd2354ad3;hpb=d7c2e950f49481d2cff5657a53519535c24d1c24;p=rocksndiamonds.git diff --git a/src/anim.c b/src/anim.c index 14dccc69..3e2f1222 100644 --- a/src/anim.c +++ b/src/anim.c @@ -242,6 +242,9 @@ int getAnimationFrame(int num_frames, int delay, int mode, int start_frame, { int frame = 0; + if (delay < 1) // delay must be at least 1 + delay = 1; + sync_frame += start_frame * delay; if (mode & ANIM_LOOP) // looping animation