To Offset Or Not To Offset
Looking into the parallax effect I want to create. I noticed that the offset needed to be used together with the position of the entity. The entity position is just a relative position to the center of the screen. So I quickly understood why that worked, but it was a bit weird to me how the base position of the entity also has a parallax effect. I would expect the entity to just stay in place with a depth of 0.

I already knew depth doesn’t have any effect at the moment. That needs to change. But first I want to understand how the entities are sliding around, while they should stay in one position. At least compared to the tiles beneath them. I noticed I was using the offset together with the transform position. Making a small change fixed the problem.

This now essentially has sparked the push to fix the coordinate system altogether. So currently nothing should have an offset. Everything should stay on their position and not slide around. Which is basically already working, however the tiles are rendering smaller. There are gaps between tiles and pretty significant ones. That’s something I do not understand why that changed with such small modifications. And it will be the next thing for me to look into.

Last modified: March 7, 2023