Sprites offset upon booting up Godot project

:information_source: Attention Topic was automatically imported from the old Question2Answer platform.
:bust_in_silhouette: Asked By Ox0zOwra

My sprites would have no offsets whatsoever and would be positioned correctly, like so (note that the arrow sprite is being moved. The texturebutton’s textures aren’t):


But when I booted up Godot today, some of them mysteriously shifted a tiny bit to the side (the Y axis was affected in some other sprites aswell)


Furthermore, when I investigated the sprite’s positioning, there was no difference between yesterday’s and today’s positions and no floating points were involved. The offset property was also untouched.


I did not move the parent nodes. I did not, in fact, do anything with these sprites at all, except for moving them. This seemed to apply to a lot of sprites I manually positioned today, which were also slightly offset.

I remember having this issue in previous versions of Godot, but I thought I may have done something wrong for it to appear, so I looked for a solution, but I couldn’t really find one. After several days, said issue mysteriously disappeared on its own (and I had to remove the offsets from all my sprite nodes, which was painful and not fun).

And yes, this isn’t just an editor-only issue. The sprites are actually shifted like this when I play the game aswell.

What could’ve possibly caused this?

Addendum: Just noticed this issue occurs specifically on axes where the texture’s size is odd-numbered. Unaffected textures had even-numbered pixel widths and heights.

Think there’s somewhere in the docs that recommends you to use power-of-2 textures.

You know:
2, 4, 8, 16, 32, 64, 128, 256, 512
100x200, 10x40, 1080x1260

Could be wrong but if your problem persists try submitting a bug report

Wakatta | 2022-09-18 12:49

I’m using GLES3, so textures that don’t use powers of 2 should apparently be fine.
Not to mention it worked without any issues before aswell - the textures suddenly moving like this feels really strange, and I know for certain I’ve had that sort of problem before. And it went away on its own.

Ox0zOwra | 2022-09-18 12:52