There a reason for sprite coordinates to center and tile maps to start from corner?

Toying around with numbers and just figured out the thing that was driving me crazy earlier: Sprites and tile maps are working from entirely different reference points with regard to coordinates.

If I put in 0,0,0 for a sprite it centers it. This also works for the camera, so happily the camera is nicely centered on the sprites I made to see how big the screen is supposed to be for different resolutions.

But for the tile maps, if I put in 0,0,0, it puts the upper left corner there. So the camera catches only 1/4 of the picture.

It seems odd that I’d need to calculate nothing for sprites, but calculate where I want it to go for tile maps (instead of centered). I’m not saying it’s wrong, just odd, and I want to wrap my head around it.

Is there a good reason for the reference points to be different like this? Please help me understand.

That is because the tiles in the tilemap are arranged within the same UV space.
Its the same as with a flipbook texture.
If I take a 2x2 flipbook and supply 4x4 as row/column values, i will also only see the upper left quadrant of the frame.
Look into the implementation of the flipbook and see how they shift the UVs to their correct values.

Also look at the documentation for nodes like “TextureCropping”
https://docs.unrealengine.com/latest/INT/Engine/Rendering/Materials/Functions/Reference/Texturing/index.html#texturecropping

That should give you a pointer into the right direction :slight_smile: