How to mark a region with a blank tile?

I have a map for a platformer, with either a blank tile for air or a tile for ground in every spot. Now I’m trying to make it so that it connects every tile with every other tile according to this tileset: (note that the blank tile is not the tile in the bottom left corner, in the actual tile set I filled that up with another tile. When I say a blank tile, I mean a tile with no data on it.)


Now I’ve got a rule file with four layers:

  • regions_input: A layer filled with “blobs” of a tile I chose to be the “selector tile”
  • regions_output: A layer filled with the same selector tile, but only in the middle of those blobs, so that a change only affects the tile in question, being the middle tile
    -input_ground: A layer filled with formations of the same ground tile, with blank tiles above regions_input to mark that a blank tile was expected
    -output_level: A layer with every tile from the tileset above, in the spots where it would need to be filled in when one of the formations of input_ground is discovered.

Now here’s my problem: It only works when the surrounding blocks are equal to the selector tile! My aim is that e.g. it detects a blank tile above, it makes sure that it has grass on it. Now what happens, is that I need to fill the whole level with the selector tile to get it to work, which is not what I want!
Is there a property I can set to get the intended behaviour, or is this not possible and do I need to choose another path?

EDIT: I’ve encountered another issue, the edges of the map have the same problem, but I can’t put any selector tiles there. Is there a way to make that register as well?

I think I can safely bump this after two days

Can someone respond? anyone?

Sorry @Basseyh, bumping doesn’t really help. I try to answer everyone, but it takes time. Today there were several other posts that were quicker to answer and there’s a few older questions still waiting for answers as well.

Part of your issue seems similar to something discussed below. Does that help?

I’ll try to answer more complete later, but it will take a few days.

Yeah, that certainly is part of the issue, as seen in my edit, but I think I can work around that, even though it is a mild inconvenience. The problem that I’m having is that the tiles I use to mark the region with in regions_input (like the red checkerboard tiles in the link you posted) are the tiles that the rule expects, instead of the blank space on top of the regions. I’ll whip up an image to describe better what the problem is, because I’m bad at putting this in words.

Hmm, what about the “StrictEmpty” layer property? That should allow your example to work, since it will change the meaning of the empty tile in “input_ground” from “any tile that isn’t empty or a block with grass” to “an empty tile”.

The main inconvenience with “StrictEmpty”, is that it also no longer allows any other tile to sit on top…

That sounds like it might be it! I’ll try it out as soon as I can!

I’ve already circumvented that inconvenience by having the ground layer output to the level layer, which is the only one my program reads. Thank you so much!