Quantcast
Channel: Cocos Forums - Latest topics
Viewing all articles
Browse latest Browse all 17076

Issue with tiles jumping around after resizing a TMXTiledMap?

$
0
0

@TripleOne wrote:

I'm running into a problem after resizing a tile map when moving it across the screen. The tiles seem to jump around, and I assume it's because their positions aren't an integer causing them to either be drawn 1 pixel to the left or right depending on it's position double. I'm thinking I can solve this problem by rounding their position coordinates down. however I can't seem to access their world space coordinates. I tried this:

for (const auto& child : tileMap1->getChildren())
{
child->setPositionX(floor(child->getPositionX());
}

Is this even possible?

Posts: 1

Participants: 1

Read full topic


Viewing all articles
Browse latest Browse all 17076

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>