Open DinoMC opened 3 months ago
Hello, thanks for using the plugin.
The borders in your example can be painted as a terrain, which would speed up the level design. You might need to add a transparent tile for the central cells.
Anything to do with placing tiles across layers is beyond scope of this plugin. I'm sure such a tool would be neat, but I want to keep Better Terrain simple and straightforward for the majority of users. Furthermore, the tilemap layer system is being removed in 4.3, so any layer-based system would be restricted to 4.2 or earlier.
However the plugin is also completely public domain, so you can tailor it to your specific needs as much as you want. Perhaps you could add a button or key combo to mark a background terrain type, and then write that into the background layer every time it paints a tile? That would suit your specific needs and probably wouldn't be too tricky to hack together.
I didn't think about just making a second terrain type with transparent tiles for the inside, nice, that solve 90% of my issue :)
I might look into modifying better-terrain it to solve the remaining 10% if it's not too hard!
PS. I'm actually using 4.3 in my example above. I said "upper layer" but I really meant upper TilemapLayer, I think the end result would be the same (?)
Glad to hear that helped.
Yes, anything you can do with layers in a TileMap, you can also do with TileMapLayers. However, TileMapLayer nodes are much more flexible, as you can arrange them throughout the scene tree.
I love the Decoration system in better-terrain, but I feel like it doesn't work well for top-down games (or I might not understand how to use it), or even side-view games in some use cases.
Rather than having decorations be added to the surrounding empty tiles, I'm looking for a way to add them to the same tile, but on an upper layer.
As an example use case, right now I'm trying to use a tileset with a lot of "Ground" tiles and a lot of "Border" tiles that go over the ground. If I create every combination in my spritesheet, I'd have hundreds, maybe thousands of different tiles. So rather than doing that, I'm trying to draw the ground, and then draw the borders on top. Like this ;
(If there's a way to do that already, OR a way to combine two tiles in Godot that I'm not aware off, you can stop reading here and please tell me about it :P)
Initially, I tried to add the border to an adjacent tile using Decorations, and then offset its rendering so that it draws over the ground. But I run into an issue with inner corners, where 3 different tiles would need to draw to the same adjacent tile. Couldn't figure out a way around that :
(shown here without the offset so the issue is more visible)
Using the decoration system, I guess a way to do it would be :
For tiles in "Decoration" in Better Terrain, allow the center bit to be painted when using "paint connecting type" from another terrain, indicating that this decoration is to be drawn over tiles of this terrain type.
If other bits are also painted, that would mean the decoration is still to be drawn on top, but only for tiles adjacent to other tiles of the same terrain in that direction (So eg. the borders would only be drawn at the edges of the terrain)
Since the only way I can think of to do this is to paint on an upper layer, it would also require a way to select the target layer. Maybe per terrain type, so it could be added as an additional property when creating/editing a terrain or category.