Attention | Topic was automatically imported from the old Question2Answer platform. | |
Asked By | gtkampos | |
Old Version | Published before Godot 3 was released. |
When using camera in 2d projects that has smoothing enabled, sprites flicker (jitter) just before the camera settles.
The position of sprites is probably a non-integer, or the position of the camera.
The problem persists with or without pixel snap.
How can I solve this problem? Lets say, snap everything in pixels unit? Maybe with a script controlling the camera?
Couldn’t find any answer about this fact.
Thanks!!!
Are you using fixed processing?
avencherus | 2017-04-26 15:16
Tried with both process and fixed process. Same result.
It appears that, when I stop my character (2d platform game/pixel art style), the camera continue moving to settle its position. When this happen, the flickering/jittering happens on the caracter and in some parts of the scenary too. Maybe because its moving in a float speed, and the engine try to adapt the pixels to the render.
gtkampos | 2017-04-26 19:17
Is your problem similar to this one? https://forum.godotengine.org/6197/how-to-stop-camera-lag?show=6197#q6197
Zylann | 2017-04-26 19:23
I have jittering on my 2d pixel art game.
Tkaewkunha | 2017-11-27 16:49
@Zylann No, not this time, although that is a sneaky one. My camera doesn’t move in my test scene. The jitter is mostly caused by the objects being ejected from collision resolution. The best result I could get was by using a capsule with enough thickness.
For other problems I offset the slide angles on slopes and modified gravity, etc. Reduces a lot of the problems, but doesn’t entirely eliminate it. I’m thinking the RigidBody is not the way to go for characters in platformers, or maybe I’m missing out on some fundamental tricks.
avencherus | 2017-11-27 17:58