GithubHelp home page GithubHelp logo

Animated Tiles about tiled HOT 82 CLOSED

stefanbeller avatar stefanbeller commented on May 5, 2024
Animated Tiles

from tiled.

Comments (82)

bjorn avatar bjorn commented on May 5, 2024 2

As far as I am aware, nobody uses animated gifs for animated tiles, apart maybe from some really rare browser games (that don't use canvas but some HTML table or CSS to lay out gifs on a grid?).

So while that may be a nice gimmick, the primary goal of this feature would be to find a good way to define an animation as a sequence of tiles from a tileset and a way to store that in the TMX format.

from tiled.

Storyyeller avatar Storyyeller commented on May 5, 2024

Do you need the animations to appear inside the editor? Otherwise you can just add them automatically while doing the map format conversion to your game.

from tiled.

bjorn avatar bjorn commented on May 5, 2024

@Storyyeller I think this feature is mainly about having a convenient user interface that allows you to define and preview the animation. Actually showing them while editing would also be nice, but that could also be annoying so then there needs to be a pause button or something. :-)

from tiled.

 avatar commented on May 5, 2024

I guess an animation should be simply a sequence of tiles picked by the user, cycled in a millisecond interval specified by the user.

Probably one could choose specific tiles in a tileset that make up an animation, and they would disappear as separate tiles from the tile picker, and just merge to one single animated tile.

This could be done by having a "compose animation" button which then allows to select multiple tiles in the tile picker, and having a "complete animation" button which then removes all those selected tiles (they could simply become blank/unselectable) and leaves only the first, displaying it now animated with the given settings. If the new animated tile is selected, another "dissolve animation" button could allow to expand the tiles again to their individual original tiles.

All of those buttons would be part of the "Tilesets" window and become greyed out when not applicable.

This approach would not allow tile animations with varying speed transitions between frames, frames from multiple different tilesets or using the same tile for multiple animations. But on the other hand, it would be relatively easy to implement, so I believe (and would also be easy to use).

from tiled.

 avatar commented on May 5, 2024

Well and there should be an animation speed input (text box or slider or something) which shows up during the compose animation step or when an animated tile is selected.

from tiled.

mtwilliams avatar mtwilliams commented on May 5, 2024

Probably one could choose specific tiles in a tileset that make up an animation, and they would disappear as separate tiles from the tile picker, and just merge to one single animated tile.

Full control with sensible defaults would be preferred (at least by me) thus a new window would be the best bet. As for tile removal: tiles shouldn't be removed from the tile picker unless the user wants them to.

from tiled.

stefanbeller avatar stefanbeller commented on May 5, 2024

I started implementing this feature.
For a proof of concept I implemented it as the mana project designed it.
In the mana project the animations are defined by tile properties, which define the frame and the duration of the frame.
So there are properties
animation-frame0 = tileid in current tileset
animation-frame1 = tileid in current tileset
animation-frame2 = tileid in current tileset
animation-frame3 = tileid in current tileset
and the durations by
animation-duration1 = multiples of 10ms
animation-duration2 = multiples of 10ms
animation-duration3 = multiples of 10ms
animation-duration4 = multiples of 10ms

This is generic, but not very usable. (Or a good properties editor would be needded)
@Yarcanox I wonder if the animation editor should be inside tiled, or if there should be an extra tool, which could produce tsx files?

from tiled.

 avatar commented on May 5, 2024

I would prefer inside tiled for the sake of simplicity (wouldn't need another tool to be located, installed etc). But it doesn't really matter.

from tiled.

 avatar commented on May 5, 2024

Since gif is color limited, I created a specific animation format for 2d games: http://devnewton.bci.im/projects/nanim

The tools I wrote are in java, but the format specification is made with protobuf so a C++ parser can be generated with zero development.

Note, that it is not a simple apng/mng/fli/flc alternative: it is made for being used with texture packing, so it could also be usefull for #286

from tiled.

MichaelAquilina avatar MichaelAquilina commented on May 5, 2024

Stefanbeller its nice to see someone has already given this feature some attention i was recently trying to find a way of specifying animations in Tiled in a simple manner. Currently, the only way i see fit is to specify a number of properties as you have pointed out yourself - but this is far from ideal. Bjorn, do you think this could possibly be included in the next release?

from tiled.

stefanbeller avatar stefanbeller commented on May 5, 2024

I rebased my attempt to the latest tiled version of bjorn.

from tiled.

Bertram25 avatar Bertram25 commented on May 5, 2024

Couldn't animations be integrated into the tmx format in some way? Using properties is a bit heavy, even if working, isn't it? (Yes, I'm also interested by that feature ;D)

from tiled.

bjorn avatar bjorn commented on May 5, 2024

Well, the main goal of @stefanbeller was to support the animation properties used by The Mana World. Of coure I agree that a better integrated solution would be nicer.

from tiled.

Bertram25 avatar Bertram25 commented on May 5, 2024

@bjorn I'll join you on this point, even thinking that if a common and official format for animated tiles could be integrated in the tmx format specifications, it would be TMW to adapt itself to those, along with other projects (such as mine ;]). I could almost bet on it.

from tiled.

Bertram25 avatar Bertram25 commented on May 5, 2024

@stefanbeller @bjorn Do you think we could define a common spec for animated tiles here?

Maybe you even got something done?

from tiled.

Disk1of5 avatar Disk1of5 commented on May 5, 2024

If tiled implemented sprite sheet animations could be defined based off of the animation sequence in the sprite sheet.
additionally if properly integrated into tiled you can choose what sequence of animation to start from.. and if the animation loops..

these are all idea's but if you look at other software that does similar functions as tiled allot of them are using common sprite sheets.

from tiled.

bjorn avatar bjorn commented on May 5, 2024

@Disk1of5 Could you refer to those tools so that we may have a look at them? Also what is a "common sprite sheet"? I've seen sprite sheets take on many different forms, both regarding how to store the images (individually, on a regular grid like a tileset or on a packed texture) and how to store its animation (in the code or with XML files in various formats and with various different features).

from tiled.

bjorn avatar bjorn commented on May 5, 2024

This feature can be very simple and it can be very complicated, depending on how far we want to take it.

  • The system implemented by @stefanbeller allows declaring existing tiles as animated, and to build an animation consisting of tiles from the same tileset with individual frame durations. If that is enough then figuring out how to store it is a simple matter of translating the custom tile properties to appropriate XML elements, for example:
<tile id="...">
    <animation>
        <frame tileid="..." duration="..."/>
        <frame tileid="..." duration="..."/>
        ...
    </animation>
</tile>
  • On the other hand, @Disk1of5 suggested one might be able to define multiple animations and declaring whether animations loop. I can see this is useful even in the context of animated tiles, for example if you got a door tile that has "open" and "close" animations that do not loop. Usually in this case you don't need Tiled to play the animation on the map. On the XML side, it's easy to add support for this by giving the animation element a name, a loop property and allowing multiple of them.
  • If we allow defining sprite animations, for example to be used for tile objects, there's actually a lot of features that could still be added that exist in for example The Mana World:
    • Grouping animations by action and defining the direction for each. This could of course also be done using either special animation names or by allowing custom properties on animations.
    • Specifying pixel offsets per animation frame. Not hard to support.
    • Allowing the frames to be based on tiles from multiple tilesets. This would be a little tricky with the way Tiled is set up.
    • Other fancy stuff like storing the most common sequences (incremental tile ids with same duration) in a shorthand format or picking random frames.

We can't implement all these features immediately, but ideally we should make sure that such extensions could in theory be made later without breaking backwards compatibility.

And btw, most of the effort here will probably be in the UI, allowing the animations to be set up and changed, all with full undo/redo support of course. Saving/loading and animating a bunch of tiles is peanuts compared to that.

from tiled.

Disk1of5 avatar Disk1of5 commented on May 5, 2024

Hey @bjorn
http://tide.codeplex.com/
http://dambots.com/dame-editor/
is an example of a tile editor utilizing a sprite sheet
as for standardizing a sprite sheet i have been using a commercial solution that outputs to a open source standard. http://www.codeandweb.com/texturepacker

But your right there are MANY formats.. i'm gonna say my 2 cents would be to adopt LibGDX's format of sprite sheet handling for the following reasons

  1. Opens source
  2. a GUI has been developed for it https://code.google.com/p/libgdx-texturepacker-gui/
  3. its Java so it works on All Platforms.
  4. there is a alternative robust solution (as mention above) if required.

A idea would be that a TMX tile set would be loaded from a sprite sheet, animated TMX tiles are detected as an array of animations.. the editor could define the animation properties (speed, looping, starting frame etc)..

not something easy to incorporate but these are features that would help tiled grow.

My current project is using Spine for player character animation and objects, and Tiled for mapping, my method of animating my tiled map is having a pace holder tile and in the properties defining that its an animation and a link to the sprite sheet at render time.. also i use tiled objects as place holders for parallax layers This works at run time good.. but isn't the most ideal solution for artists and mappers to see what the finish product looks like just in tiled..

i wish i knew more about QT to help contribute :(

Thanks!

from tiled.

bjorn avatar bjorn commented on May 5, 2024

@Disk1of5 Hmm, as I see it TexturePacker and libgdx-texturepacker-gui have very little to do with sprite animation. All they do it stick individual images onto a single texture. It is not very interesting to support their output directly in Tiled, because the output is very dynamic (the images may need to be split over multiple textures and their arrangement and order can change completely when one of your images changes size a little). In combination with such tools, I think it would be much more useful for Tiled to refer to the individual images that these tools are packing together. Then in your engine/game you have those file names and should be able to map that to whichever texture atlas the packing tools have decided to put them.

I will have a look at how tIDE and DAME support animation.

Btw, the main thing holding back Tiled development currently is that I have very little time for it. If you want to help with that you can sponsor me a little each week and help towards my goal of getting enough money to compensate for giving up one day a week at my current full time job. See https://www.gittip.com/bjorn

from tiled.

Bertram25 avatar Bertram25 commented on May 5, 2024

Hi,

So finally, and as for the TMX specs, are we ok with:

<tile id="...">
    <animation>
        <frame tileid="..." duration="..."/>
        <frame tileid="..." duration="..."/>
        ...
    </animation>
</tile>

as for the looping, we could even add:

<tile id="...">
    <animation loop="true">
        <frame tileid="..." duration="..."/>
        <frame tileid="..." duration="..."/>
        ...
    </animation>
</tile>

Regards,

from tiled.

englercj avatar englercj commented on May 5, 2024

Was this issue ever revisited? I am currently setting a properties on a tile to describe the animation, but there isn't a good way to get the id of a tile easily (in large tilesets), so this process is non-trivial. Some solution that allowed me to easily build an animated tile based on a tileset would be fantastic.

from tiled.

johnfn avatar johnfn commented on May 5, 2024

+1 Would love this feature. Just finished Ludum Dare and Tiled was generally a joy to work with, but this was the one feature I was wishing Tiled had.

from tiled.

englercj avatar englercj commented on May 5, 2024

Right now I'm naming objects, and then creating an animated sprite based on the name and a map of tiles that it should use as frames. Would be so much better to just do that in tiled.

from tiled.

Bertram25 avatar Bertram25 commented on May 5, 2024

Let's make things advance ;) How much for the first version of this feature? Animated tiles with optional loop support (viewable in the editor)

from tiled.

bjorn avatar bjorn commented on May 5, 2024

@Bertram25 Are you asking people how much they are willing to pay or are you asking me to name a price?

from tiled.

Bertram25 avatar Bertram25 commented on May 5, 2024

@bjorn I'd rather say name your price. :) If it's too high for me alone, then I'll ask the others how much they are ready to bring so we can divide it.
It's a key feature for everyone including myself, and you deserve it, that's why I'm ready to commission it.

from tiled.

bjorn avatar bjorn commented on May 5, 2024

Ok, one issue is that I will not have time for this before November unless I am allowed to take days off before that. Other than that, I think I will need at least two days of work to do it properly, so 400 € would be my goal for this feature. This may seem a little much but note that it includes VAT and income tax.

To allow everybody who is interested to contribute to getting this feature sponsored, I would suggest using BountySource to add your contribution: https://www.bountysource.com/issues/128179-animated-tiles. BountySource will take your money up front, but it will only be paid out to me (or whoever else decides to implement this feature) when this feature is available in Tiled.

from tiled.

Bertram25 avatar Bertram25 commented on May 5, 2024

Ok, Paypal is currently reviewing my payment but I added 35€. Please everyone, even one count!

from tiled.

kheftel-old avatar kheftel-old commented on May 5, 2024

I chipped in $15 using paypal. Hope it helps. Paypal is reviewing my payment just like @Bertram25's

from tiled.

Syynth avatar Syynth commented on May 5, 2024

I sent $15 as well. I would happily pay more if I had it right now.

from tiled.

Bertram25 avatar Bertram25 commented on May 5, 2024

38 + 15 + 15 = 68. Yeah :)

from tiled.

rappo avatar rappo commented on May 5, 2024

Hey guys, I'm from Bountysource. I talked with @bjorn about this already in IRC (#Bountysource on freenode), but the hold up with Paypal processing is on Paypal's end. We talked with them on the phone and they're not sure what caused the delay, but they're looking into and they believe it's because of a recent change on their end. They'll keep us posted, so I'll let you guys know as soon as I do. Sorry about that!

from tiled.

bjorn avatar bjorn commented on May 5, 2024

Thanks a lot guys! All bounties so far are recognized by Bountysource now. Once I have some time I'll try to raise additional awareness to get more people to fund this feature. Please feel free to already make some publicity yourself!

from tiled.

Bertram25 avatar Bertram25 commented on May 5, 2024

Added something there, more specs related: :)
http://forums.themanaworld.org/viewtopic.php?f=4&t=17710

from tiled.

Bertram25 avatar Bertram25 commented on May 5, 2024

Added another $15. I hope this will start to tempt you. ;)

from tiled.

bjorn avatar bjorn commented on May 5, 2024

Thanks @Bertram25, though as I previously said I will not have time to start on this before next month. The amount is also still far away from the goal I set, but there may be a bigger sponsor coming up for this feature.

from tiled.

Bertram25 avatar Bertram25 commented on May 5, 2024

Hi @bjorn,

I hope you're going well, btw.

Sure. Don't worry, I didn't forget about your availability, and I'm not the kind pushing people to do things quicker as I know the involvement needed in front of the few dev spare time we both may have.
I just wanted to raise the interest again (for you but also for others). ;)

Best regards,

from tiled.

Bertram25 avatar Bertram25 commented on May 5, 2024

Hi @bjorn ,

I've seen you've set a goal of $550 for this feature. While I've got no problem with this, could you describe a bit more specifically what we would get for such a goal. I'm sure this would help the feature overall interest, and help me and others advertise it.

Regards,

from tiled.

bjorn avatar bjorn commented on May 5, 2024

@Bertram25 I just noticed they added that goal feature and $550 reflects the original target I had stated here (400 euro). What I would implement for this would be support for single animations to be associated with tiles with per-frame duration, including an editor for selecting the tiles and setting the durations and the live previewing of animated tiles on the map.

I should note though that there is already a sponsor that plans to cover the remaining amount of this feature! I plan to work on this over my Christmas holiday (probably starting around the 16th of December).

from tiled.

Bertram25 avatar Bertram25 commented on May 5, 2024

I should note though that there is already a sponsor that plans to cover the remaining amount of this feature! I plan to work on this over my Christmas holiday (probably starting around the 16th of December).

OMG, this is great!! :D

Thanks for the explanation of the planned feature. This will be a nice Christmas present for everybody involved here! :)
I hope you and your family are going well in those winter and Christmas times.

Best regards,

from tiled.

englercj avatar englercj commented on May 5, 2024

@bjorn Fantastic! I am really looking forward to it!

from tiled.

bjorn avatar bjorn commented on May 5, 2024

Sorry for the delay after announcing that I planned to start on this around the 16th of December. Due to the work on #552 taking longer than expected and then hitting the family visiting part of the holiday it's now two weeks later.

I'll start on this feature now, but I have only the weekend left of the holidays so I'll have to make the best of the evenings and weekends.

from tiled.

Bertram25 avatar Bertram25 commented on May 5, 2024

@bjorn It's good to see you working on key features, whatever they are. Take the time needed. Happy New Year!

from tiled.

bjorn avatar bjorn commented on May 5, 2024

Thanks @Bertram25, and a Happy New Year to you too!

from tiled.

bjorn avatar bjorn commented on May 5, 2024

So, the progress so far is that the core classes have been adapted to store the animation data, saving and loading has been implemented for the TMX format and Tiled is rendering the animations on the map view (currently updating the entire view when a frame changes, so that tile layers, brush preview and tile objects all update correctly).

I've also made it support the TMW way described by @stefanbeller at #57 (comment) to make it easy for people who were using that style to switch to the new format.

The changes have been pushed to the master branch, so daily builds are made. The Windows one is already updated and Max OS X will follow soon.

Next I plan to start working on an editor window where you can define the animations. I will try to make this work based on drag and drop. I expect progress on this to be slow since I only have the evenings to work on it, but I'll do my best to finish it next weekend.

from tiled.

Bertram25 avatar Bertram25 commented on May 5, 2024

Hi @bjorn,

Thanks for all the work done on this already!
It's not urgent at all, and maybe it's already done, but maybe you should add an animation to the example map so people can easily get what it looks like?

Best regards!

from tiled.

bjorn avatar bjorn commented on May 5, 2024

@Bertram25 It would certainly be nice to add an example, and in fact the examples need to be extended a lot since they don't use any of the new features added in the last years. However, I don't have some nice tile animation ready so for now you can check it out with the Evol Online repository for example:

https://gitorious.org/evol/clientdata

Just open maps/000-1.tmx which has animated wave movements or maps/000-2-1.tmx which has some subtly animated candles. You can save the files to have those animations stored in the TMX format.

from tiled.

bjorn avatar bjorn commented on May 5, 2024

Just a quick screenshot showing the progress so far with the tile animation editor, using the Evol Online map as example:

screenshot - 01092014 - 10 20 26 pm

The idea is that you would be able to drag tiles into the list of frames, and drag frames around within the list, but that's still to be done. I think it may be a little confusing that there's two times the same tileset, once for selecting which tile to edit the animation of and one for selecting frames for in the animation. But at the moment I wouldn't know how else to do it. Hopefully it's not confusing at all.

from tiled.

Bertram25 avatar Bertram25 commented on May 5, 2024

@bjorn Great screenie. :D

I can understand why you "duplicated" the tileset view as it must simplify a lot the drag'n'drop code. (And personnally, I don't mind. The animation editor is only there when you're animating, so it's a different workflow.)

Now I've got several questions (I didn't try the master version, yet):

  • Is the "preview" text a placeholder to tell "You'll be able to see the resulting animation live here."?
  • Once you've animated certain tiles on your tileset, how do you know which one is corresponding to an animation?
  • Have you implemented an option to enable/disable the animations in the main view?

Thanks a lot for the hard work on it. I know many, many people will like it. :) 👍

from tiled.

bjorn avatar bjorn commented on May 5, 2024

@Bertram25 Actually the reason the tileset view is duplicated is not primarily to simplify things, but rather because of conflicting behavior when both "selecting the tile to animate" and "selecting the frames to put in the animation" would happen in the same view.

The "Preview" text is indeed a placeholder where I would put an actual preview on the animation. For recognizing tiles that are animated, I am considering to make it look like a piece of film. And, of course there will be an option to turn off animations in the main view, but it's not implemented yet.

from tiled.

bjorn avatar bjorn commented on May 5, 2024

Due to Qt only drawing the drop indicator in list mode and not in icon mode, I've rearranged the layout as follows:

screenshot - 01122014 - 10 24 57 pm

Maybe this looks better anyway. Unfortunately, I wasn't able to finish it this weekend since I basically had only today to work on it. However, I made some good progress:

  • It is now possible to drag & drop tiles from the tileset view to the list of frames, of course also multiple at the same time.
  • Frames can be reordered by drag & drop within the list of frames.
  • The frame duration can be edited.

What's left to do is:

  • Allowing removal of frames
  • Applying the changed animation to the tile (with undo/redo support)
  • The tile animation preview
  • The ability to turn off live animations in the map view
  • Storing tile animations also in the JSON and Lua formats
  • Marking animated tiles differently in the tileset view

from tiled.

Bertram25 avatar Bertram25 commented on May 5, 2024

@bjorn Hi again, I took a few sec to try it but I couldn't find how you open it. Can you hint me? (using master branch of tiled here.)

from tiled.

bjorn avatar bjorn commented on May 5, 2024

@Bertram25 Sorry, while the animation support itself was pushed to master this new dialog is still work in progress and I will only push it to master once it is actually working. But, I will try to remember to update the wip/animation branch this evening so you can try it out.

from tiled.

Bertram25 avatar Bertram25 commented on May 5, 2024

@bjorn Np, take the time needed. I was just asking as I saw a few commits about it in master. ;)
I'd rather not interrupt your momentum now and try it out when you consider this feature "in RC".

from tiled.

bjorn avatar bjorn commented on May 5, 2024

I didn't have much time this weekend so I only fixed a crash, fixed compile with Qt 5.2 and then fixed compile again with Qt 5.2 / VS 2012 on Windows. Fortunately most of the big things are done (checked them away above) and the only remaining parts are displaying animated tiles differently, a tile animation preview and the JSON format (and Lua too, actually). Should be able to round that off over the coming days.

from tiled.

bjorn avatar bjorn commented on May 5, 2024

Animated tiles are now marked in the tileset view:

screenshot - 01202014 - 10 39 00 pm

from tiled.

MichaelAquilina avatar MichaelAquilina commented on May 5, 2024

Things are moving along it seems. I look forward to using this long awaited
feature!

On Mon, Jan 20, 2014 at 9:40 PM, Thorbjørn Lindeijer <
[email protected]> wrote:

Animated tiles are now marked in the tileset view:

[image: screenshot - 01202014 - 10 39 00 pm]https://f.cloud.github.com/assets/531764/1958536/5a5edaee-821b-11e3-9fb8-cdc848e28f37.png


Reply to this email directly or view it on GitHubhttps://github.com//issues/57#issuecomment-32799695
.

Michael Aquilina

from tiled.

Bertram25 avatar Bertram25 commented on May 5, 2024

Hi @bjorn :D
Great to see such improvements becoming real.
I have two suggestions:
First of all, I wondered whether you woul consider making the animated marker less intrusive, something like this:
movie_proposal
(The animated tag is less present, and I also set its opacity to 60%).

If you want to keep it that way, you might need to know there is a pixel offset on the bottom of the tile:
pix_offset

Best regards,

from tiled.

bjorn avatar bjorn commented on May 5, 2024

@Bertram25 I can't believe I missed that pixel offset! Anyway I really like your suggestion so I'll change this overlay accordingly once I have the other missing parts done.

from tiled.

bjorn avatar bjorn commented on May 5, 2024

I've pushed the work so far to the master branch and updated the Windows and Mac OS X daily builds. Other daily builds should update automatically soon. The only thing still missing is the preview in the tile animation editor, and of course there can always be further improvements like the one suggested by @Bertram25 above.

I'll be gone over the next 4 days, but meanwhile feedback is welcome!

from tiled.

bjorn avatar bjorn commented on May 5, 2024

Is there nobody with feedback? Did anybody try it out?

from tiled.

Bertram25 avatar Bertram25 commented on May 5, 2024

@bjorn Hi :)
I did. But I'll do it more thoroughly by the end of the week. Anybody else has tried it?

from tiled.

Bertram25 avatar Bertram25 commented on May 5, 2024

@bjorn Well, I tried it. Loading/sabing tmw files with animated data is just here and done. :)
Now, can you tell from a new map how I add an animation linked to a tile?
I was unable to find that.

Best regards,

from tiled.

bjorn avatar bjorn commented on May 5, 2024

@Bertram25 Right, sorry I should have written a little manual. Here comes the tiny manual:

  • Go to View -> Tile Animation Editor. This opens the animation editing window.
  • Select a tile from the Tilesets view (in the Tiled main window).
  • In the Tile Animation Editor window, drag & drop the tiles you want to use in the animation into the frame list, which is the area on the left. You can drag multiple at the same time.
  • Double click a frame entry to edit its duration.
  • You can use drag & drop to rearrange frames or select and press Delete to get rid of them.

If you have placed the tile you're editing the animation of on the map, you should see the animation playing there automatically and it will update as you change it.

from tiled.

Bertram25 avatar Bertram25 commented on May 5, 2024

@bjorn My bad, I should have seen it. It was rather obvious after all. :)

Tried it, and it's working great so far. (I didn't try exporting animated tiles data in something other than the tmx format yet.)

If you wanted feedback basically, here is some:

  • When you open the tile animator view and forgot to select a tile, or didn't select the right one, when you click on the wanted tile, the animator view goes behind the main tiled window. I wondered whether a 'stay on top' option could be used in the dialog flags, for instance.
  • When you select the tiles, you're able to select several of them. It seems Tiled is using the first one for animation, but maybe the tile selection should be reset to one tile to properly show which tile is being edited? Or maybe it's a feature?
  • As a wish: Adding a right-click on tile shortcut could be nice. Same for the collision editor.
  • When using a 16x16 tileset, the movie icon upon the tile isn't always shown after linking an animation to it. I didn't find a precise way to reproduce that so far, unfortunately.

Best regards,

from tiled.

Clean3d avatar Clean3d commented on May 5, 2024

@Bertram25 If you're using Linux, depending on your desktop environment you might be able to right-click the window and select "always on top".

@bjorn Everything seems to work well for me so far! I know I'm testing this pretty late, so I hope my input is useful somehow anyway.

The animated tiles get out of sync for me while I'm editing. I suppose this is inevitable if you have animations whose durations never align, but it might be nice to have some sort of "reset timing" option. I guess an example of where this might be useful would be if you have a terrain that's an animated shoreline, and the various tide frames need to sync up.

from tiled.

Bertram25 avatar Bertram25 commented on May 5, 2024

@Bertram25 If you're using Linux, depending on your desktop environment you might be able to right-click the window and select "always on top".

Already did. :) Yet, I am sure there is an OS independant solution to this.

from tiled.

englercj avatar englercj commented on May 5, 2024

Excited for this feature! Notice it was added to the 0.10 milestone, is there any ETA for v0.10.0?

from tiled.

bjorn avatar bjorn commented on May 5, 2024

@englercj The milestone is just for organizing the release, and there's some smaller things still to do on this feature before the release hence I added it there. However, this feature is already available on the master branch (and the daily builds), so please try it out!

I can't give ETA on things that rely on my spare time. My last goal was to get 0.10 out in August, but it's currently looking like I'm not going to make it.

from tiled.

bjorn avatar bjorn commented on May 5, 2024

Alright, animation preview pushed in 48fdd68. With that I'd like to close this task rather than keeping it open until it's perfect.

@Bertram25 I know I didn't get around to the "animated tile" marker change you suggested, but I hope you don't mind I'll keep that as a possible future enhancement and focus instead on getting 0.10 out.

@Clean3d Thanks for your feedback and indeed the thing with animations getting out of sync bothers me as well. I'll have to think of some solution for this later as well.

from tiled.

Bertram25 avatar Bertram25 commented on May 5, 2024

@Bertram25 I know I didn't get around to the "animated tile" marker change you suggested, but I hope you don't mind I'll keep that as a possible future enhancement and focus instead on getting 0.10 out.

Np. This isn't important.

from tiled.

sudhalucky avatar sudhalucky commented on May 5, 2024

Hi @bjorn ,

I am very happy to see this feature rolled out in the last update.
I just wanted to know if the respective code to play the animation is available for Cocos 2d-x framework.
We are currently working on a tile map game which has lot of tile animations and I jumped out of joy when I saw the tile animation working perfectly.
May I please know the part of code to add in Cocos 2d-x v3.2 to make the tiles animate in my game.

Thanks a lot.
Sudhaker

from tiled.

bjorn avatar bjorn commented on May 5, 2024

@sudhalucky Sorry but I don't have time to help you with that. This is something you have to talk to the cocos2d-x developers about. The feature is very new so it is understandable that cocos2d-x does not support it yet, and since it's not based on custom properties but adds new XML tags to the TMX format, support for this will have to be coded explicitly.

from tiled.

sudhalucky avatar sudhalucky commented on May 5, 2024

@bjorn Thank you for your instant reply.
I have raised a feature request on Cocos2d-x forum and they did consider this for development.
For now I am writing my own code to parse the XML tags and play the animation.

However I observed one issue in the tool, once a tile is added to the animation list there is no way to remove the tile in the UI but to delete it from the XML by manually editing, I hope you are already working on this.

Sudhaker

from tiled.

bjorn avatar bjorn commented on May 5, 2024

@sudhalucky Hmm, you should be able to select frames in the list and press the Delete key to remove them. Is this not working for you? If not, on which platform?

from tiled.

alphaonex86 avatar alphaonex86 commented on May 5, 2024

Hello,

See my animation format: http://catchchallenger.first-world.info/wiki/Map_format in some case I need random offset to prevent all tile start at same animation level.
I plan update my format to your format into the next major version (into 2-5y).
Maybe can you think about animation + trigger, trigger declanched into menu on tile?

Cheers,

from tiled.

bjorn avatar bjorn commented on May 5, 2024

@alphaonex86 Well, trigger could already be done by a custom property, but at the moment you can define only a single animation per tile. So if you want separate animations for opening and closing, in Tiled you may define this as one animation and then use custom properties to indicate when to play back which part of the animation.

from tiled.

alphaonex86 avatar alphaonex86 commented on May 5, 2024
  1. Having random starting frame is useful to do lava animation. It's same animation but start at different frame to have random place bubble.
  2. My target is more have into tiled a generic way to visualize/edit multiple animation sequence on one tile. My idea it have multiple animation sequence, one without trigger (the default), other with trigger label, with repeat option.
    Why? Because like lot of game, I have implemented that's in my game via custom property, but a common way (but generic) to do that's and good support into the editor, will help the mapper to visualize better the map, and fire it self the trigger to visualizer it.
    Example:
    My door have one tile animation (then no animation), 2 trigger: open, close, each linked with opening/closing animation. After my application will fire it when it want. But if the editor will have menu to fire it too, it will be great.
    Maybe another issue?

from tiled.

Rialgar avatar Rialgar commented on May 5, 2024

I would really like to have multiple (named) animations on one tile, this is especially useful for objects, since these might change their animation during the game.
Some examples:

  • Collectibles that make a little splosh when collected
  • Enemies that can walk, stand, die, ...
  • A Goal that shows a nice animation when reached

It would be great to have all these animation specifications in a single place, and I think the Tiled file would be an excellent location.

For the time being I will probably create each animation on the starting tile and add the names as custom properties.

from tiled.

bjorn avatar bjorn commented on May 5, 2024

@Rialgar Yes, it's a feature that could be added. Maybe you could open a separate issue about it?

from tiled.

hoangbv15 avatar hoangbv15 commented on May 5, 2024

Hello, apologies on commenting on a very old and closed issue, but I am genuinely wondering if there's a more efficient way of defining tile animations, other than selecting a tile, choosing "tile animation editor" menu option, drag and drop tiles, repeat.

My tile set has above 100 tiles, with each tile has its own animation. It does become a bit tedious going through the GUI to do the animation for all tiles.

The frames are put vertically on top of each other in a sprite sheet, so potentially could I manually edit the .tmx file with a text editor to add the animation myself? Or is there a better way to do it?

from tiled.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.