Isometric game, Camera movement breaks when fps drops.

I’m developing an isometric mobile game, and when fps drops below 60, any camera movements including zooming in and and out breaks completely, by breaking i mean it starts flickering in random directions.

this only happens when fps drops.


With the information available I could only presume that you have a problem in the scripts that control the camera.

Something like value change pass the value when elapsed time is greater than 1/60.

Try to print the amount of movement that it did in each frame see if do not keep switching into positive and negative numbers. For example:

desired = 3;
current = 1;
timeElapsed = 5;
speed = 1;

Frame 1;

current1 = current + timeElapsed * speed;
current1 == 6

Frame 2

current2 = current1 + timeElapsed * -speed;
current2 == 1

Frame 3

current3 = current2 + timeElapsed * speed;
current3 == 6