Godot TileMap Autotile Tutorial

Video Statistics and Information

Video
Captions Word Cloud
Reddit Comments

Thank you for making this tutorial! We definitely needed more Autotile tutorials that cover ignore bits (or wildcards as some contributors call them).

👍︎︎ 2 👤︎︎ u/golddotasksquestions 📅︎︎ Apr 06 2021 🗫︎ replies
Captions
so i often see people asking how do i make autotail bit bash for this tiles that i have auto tiles are confusing so let's make some auditile bitmaps first off let's get a free asset from itch.io now let's take a look at how bitmaps work goodell has three modes for autohal bitmas two times two three times three minimal and three times three two times two requires fifteen house and doesn't work for groups of tiles that are only one tile wide or one tile long three times three minimal requires 47th house and three times three requires 256 tiles usually it's not necessary to use the full c times three mode however for this tile set i recommend using three times three minimal since these tile sets come with one tile wide lines so a three times three bit mask is composed of nine bits in a three by three grid the center bit indicates that this tab will be used for the auto tiling always turn on the center bit for every tile you want to use the other bits indicate whether the tile has a neighbor in that direction or not for example the top edge bit being on means that this tile has a neighbor to the top of it the top left corner bit me being on means that this tile has a tile to the top left of it note that for three times too minimal you cannot have an edge bit off while either quarter bit is on this reduces the number of auto tiles needed to have a full set of 47. however if you look at our tile set you can see that it only has 22 tiles how can we make a bit mass with only 22. we can do this with the ignore bit use a shift left click to set an ignore bit ignore bits of what their name indicates the other higher will ignore them when matching tiles this means the tile can be used when you need a towel with a bit on or off at the position of the ignore bit additionally our towel set actually has three tiles with the same bit mask this is okay the dough will randomly tip from one of them to place you can also adjust the priority of the tile and make it hand more often so this means that we have twenty thousand total let's draw our bit mess first let's fill the tiles that will have neighbors in all edges and corners these are easy since they will be filled in red completely next these tiles only have neighbors on their inner edges so we only fill in the bits that are on the inside these tiles here are single tile lines let's only fill in the center bits for these finally these tiles are for concave inner corners they're only missing the quarter neighbor now let's add the ignore bits if we look the template provided on the using towel maps documentation page we can see that these tiles are missing we can make these tiles by setting orbits on these tiles and we can make the rest of the tiles by setting ignore bits on these tiles also let's increase the priority of this center tile so that it shows up more often than two other tiles with the same bit mask now let's use our new auto title set to draw some shapes if you take a look at the cross hair you'll notice that it doesn't look quite right this is because we don't actually have a towel drawn for the center for cross shape so godot just takes the icon down applies it there if you want godot to use another towel you'll need to change the icon tile i tried drawing a bit mask with a cross shape but since ignore bits take priority over exact matches it messed with some other bit masks so if you want every combination of house look good you'll need to draw all 47 tiles that's it if you have any questions don't hesitate to ask
Info
Channel: Emily Yi
Views: 1,315
Rating: undefined out of 5
Keywords:
Id: ZNExTqswbCY
Channel Id: undefined
Length: 3min 28sec (208 seconds)
Published: Sun Apr 04 2021
Related Videos
Note
Please note that this website is currently a work in progress! Lots of interesting data and statistics to come.