Hello, I have a big jittering issue on my player character in my pixel art game when running it at 60FPS and moving my character in diagonal. I don't have the issue at 30 FPS.

When inspecting my framerate, there is no drop. My game is rendered on a 320*180 SubViewport. Player sprite is snapped to an integer value. Camera is also snapped to an integer value, and I use a shader on my SubViewportContainer to smooth its movement.

Do you have any idea what could cause this issue ?
I made a video comparison : first the 60FPS jittered version, and then the 30FPS nice version.

Also, after further testing, I don't have jittering at 35 FPS, and I have jittering at 45 FPS or more.

Thanks !

are you might be processing your movement with two different time source at the same time like move_and_slide and delta together ?

    EGNR I don't use move_and_slide, I only set the global_position using delta.

    • EGNR replied to this.

      Do you update in _process() or _physics_process()? I've found _process() to work better for smoothness.

      I'm moving my player character in _physics_process, however I tried _process as you suggested but I still have the same issue.

      5 days later
      18 days later

      Are you properly according for _delta? Frame rate should not matter unless it is frame rate dependent (when not adjusting movement for delta time).

        5 days later

        cybereality I use a smoothed camera which lerps towards the player based on delta time, as shown in this video : Also, now I'm using move_and_slide instead of directly setting the player's global_position.

        Calinou Thanks.

        • Setting the SubViewportContainer.stretch to true didn't solve the diagonal jittering issue at 60 FPS.
        • The last message in the issue you're referencing has a video that describes exactly what I'm trying to do (https://github.com/godotengine/godot-proposals/issues/6389#issuecomment-1525376438). While this setup was working well in Godot 3.5, now I have these jittering issues. Would it be possible to create some guidelines/tutorial to obtain the same setup as shown in the video in Godot 4 ?