Tomcat wrote:Adding an optional ”Conditional” layer only for maps that need it might be relatively simple. This layer would contain just the tiles that change, to be displayed over the existing Object and/or Ground layer when a condition is met. Set an event in the Key layer over the changing tile(s) whose attributes define the condition.
Good idea, Tomcat! We've been wanting to do this for a long time. In order to make it easy for map creators, I think it's crucial that using conditionals on maps is easy and that it's obvious how it works.
There are two things I think we need to define before we can start adding something like a new tile layer:
- Do we always want to add tiles to the new layer, or would we also need to remove tiles from "objects" layer?
- Should it only affect the "objects" layer, or also the "above" layer?
Adding just another layer is easy, but I'm thinking that might not always be sufficient. For example, check out
blackwater_mountain5.tmx , where we'd want to clear that rubble after some quest thing has happened. That particular map also has some stuff in the "above" layer, which is just a trick to make it look like there's more rubble there than what we can place in the "objects" layer. We'd have to have some strategy on how to handle both removing those things from the "objects" and "above" -layers, and how to handle adding new tiles to each layer.
Anyone up for doing an example of a TMX file for blackwater_mountain5.tmx with some new layer or some other representation of "objects"&"above" where the rubble can be conditionally removed?