Asset - Scripts Grid Auto Tile 47 [GMS2]

NazGhuL

NazTaiL
This scripts help you auto-tile directly in game. Perfect for procedurally generated levels. It uses a tileset of 47 images placed in the same order as in the IDE of GMS2. It auto-tiles on a ds_grid but it can be easily changed for arrays.
Note that GMS is still in beta and asset will be updated if bugs occur.

Marketplace: https://marketplace.yoyogames.com/assets/5055/grid-auto-tile-47

Screenshots:


 
Last edited:

NazGhuL

NazTaiL
There is an issue with the 2.0 IDE importing asset(included file). It's reported and will be fixed in a future release of GMS2. That's bad but don't worry, send me a mail and I'll send the file manually. The rest of the project is intact!
 

c023-DeV

Member
Heya!
I'm tinkering with the code and am wondering how to make the script ignore the room edges?

I changed line 19 and others to:

Code:
//LINE 19 ...
if (!scr_onGrid(grid, xx-1, yy-1))//up_left
...

and it works for 'closed' areas but at the 'openings' i get this:
edges.gif

The green is what I want ant at the top you see what I mean... (on the right side the screen is cut off, that is why it looks good there, but its the same on all 4 room edges)
 

NazGhuL

NazTaiL
Hi. Look on the resource Ide, double click on your tileset, go to Auto-Tiling section, there is a small icon for OPEN or CLOSED EDGES. Should fix the problem.
 

c023-DeV

Member
Sorry, I'm confused.
Your script checks on a ds_grid and returns a tilemap index... I don't see how the IDE setting should effect that?
(I tried, it has no effect)
 

NazGhuL

NazTaiL
ok, I thought it was the problem. Let me dive in it again later. Perhaps i'm sot sure what you are looking for. I don't get the problem looking at your picture.
-edit-
I don't get it! :/
 
Last edited:

c023-DeV

Member
I'm trying to get open edges like this:
OPENEDGE.gif
With your script. (Not with the IDE)

I got half way but can't wrap my head around it :/
 
Top