arkeus / Axel

An open source, hardware accelerated 2D flash game library
http://axgl.org
MIT License
77 stars 25 forks source link

AxTilemap.scale? #1

Closed Wiering closed 12 years ago

Wiering commented 12 years ago

Changing AxTilemap.scale doesn't seem to do anything, for example in the AxeliteBasic demo I'm trying:

        ...
        tilemap.scale.x = 4;
        tilemap.scale.y = 4;
        add (tilemap);
arkeus commented 12 years ago

Oh yes, currently tilemaps don't implement everything that drawables have (I don't think rotating them works either, for example). They might be something I will support, but it requires a bit extra (for example, to make collision work on a scaled tilemap). Typically, I don't see scaling tilemaps as a very common occurrence though, so it's lower on the priority list.

On Thu, Apr 19, 2012 at 6:50 PM, Wiering < reply@reply.github.com

wrote:

Changing AxTilemap.scale doesn't seem to do anything, for example in the AxeliteBasic demo I'm trying:

                   ...
                   tilemap.scale.x = 4;
                   tilemap.scale.y = 4;
                   add (tilemap);

Reply to this email directly or view it on GitHub: https://github.com/arkeus/Axel/issues/1

Wiering commented 12 years ago

I generally use it to have multiple background layers that use the same graphics but each one at a smaller size (and different shade).

arkeus commented 12 years ago

I'll look into supporting scale for tilemaps. However, unlike flixel where tilemaps are a single bitmap, here each tile is a separate quad, so scaling can get tricky (with zooming at non-integer scales, I had some issues). If I can support it, I'll get it in there. :)