Tilengine - The 2D retro graphics engine forum

Full Version: Tiled animation plays strange
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
[attachment=61][attachment=62]
Some animation frames are not displayed in Tilengine window.
Here is animation in Tiled and in TLN window.
Hi
I think this is due to a limitation present prior to current release 2.8.0: an animated tile couldn't have one of the frames being the tile itself, because that frame was overwritten and get lost. This limitation has been addressed in release 2.8.0. Can you test it with latest version and confirm that it doesn't happen anymore?
Thanks, it works!
[attachment=63]
Thanks for the feedback!
[attachment=64]
Hi. After newest update background layer animations are played on foreground layer, and I am getting smth like this after adding background animations.
Hi again,
Could you please upload the assets that are showing this problem?
Code:
void InitScrambledEgg()
{
    TLN_SetLoadPath("data/scrambledegg");
    TLN_SetRasterCallback(NULL);
    foreground_tilemap = TLN_LoadTilemap("scrambledegg.tmx",NULL);
    background_tilemap = TLN_LoadTilemap("scrambledegg_background.tmx",NULL);
    TLN_SetLayer(LAYER_FOREGROUND,NULL,foreground_tilemap);
    TLN_SetLayer(LAYER_BACKGROUND,NULL,background_tilemap);
    TLN_SetBGColor(0,0,0);
    TLN_SetLayerPosition(LAYER_FOREGROUND,0,HEIGHT*-1);
    TLN_SetLayerPosition(LAYER_BACKGROUND,0,HEIGHT*-1);
    sonic_xpos=65;
    sonic_ypos=193;
    SetSonicSpritePosition();
}

It doesn't happen on versions older than 2.8.0
Yes you're right. It seems that the animation in one layer (background) is being applied in another one (foreground). I'll debug this and publish a fix as soon as I can.
Thanks for pointing out this issue
Fixed. I pushed update 2.8.1 to GitHub with the fix. Here you can see an animated gif on how should look now your sample, both layers are showing correct animated tiles.