• Hey Guest! Ever feel like entering a Game Jam, but the time limit is always too much pressure? We get it... You lead a hectic life and dedicating 3 whole days to make a game just doesn't work for you! So, why not enter the GMC SLOW JAM? Take your time! Kick back and make your game over 4 months! Interested? Then just click here!
  • Hello [name]! Thanks for joining the GMC. Before making any posts in the Tech Support forum, can we suggest you read the forum rules? These are simple guidelines that we ask you to follow so that you can get the best help possible for your issue.

Question - IDE [Solved] Tiles not respecting transparency.

F

FormalCloud

Guest
Hi!

My tiles do not respect transparency when I paint with them in the room. I have looked under the various tools and features and can't seem to find out why this is happening. Gif below:

1) Tile grid doesn't want to reach the entire image.
2) Tiles painted from this don't respect their transparency.

Is this a bug or am I just stupid?


 
The nature of tiles is that you can only have one tile in a particular place. The top left empty tiles over-write the tiles in the bottom left of the tiles you placed first.

For those purposes, I would recommend using asset layers (I think that's what they're called) if you want them overlapping. Otherwise re-draw your tiles so they fit together the way you want.

Alternatively you might be able to use multiple layers of tiles, but that will quickly get annoying if you have a lot of tiles.
 
F

FormalCloud

Guest
1) You can't access sprite assets depth so that isn't an option.
2) GMS: 1.x allows overlap tiles so this doesn't make sense to me at all. Requiring a new layer for each tile can not be correct, right?
3) Here are two tiles overlapped in GM:S 1.x - I do not believe GM: 2.x changed this. If it's not a bug then you'll have to pardon me for being really surprised.
4) "Redrawing" them doesn't allow my character to walk behind them when layered.

 
Last edited by a moderator:

Dog Slobber

Member
2) GMS: 1.x allows overlap tiles so this doesn't make sense to me at all. Requiring a new layer for each tile can not be correct, right?
3) Here are two tiles overlapped in GM:S 1.x - I do not believe GM: 2.x changed this. If it's not a bug then you'll have to pardon me for being really surprised.
GMS 2's tile system was completely rewritten and changed considerably.

In fact Mike doesn't consister GM:S 1 to be a true tile system, he refersto it as a graphical BLOB system, nasty and performed poorly.

GMS 2 is a proper tile map system. Because of the changes we lost some of the features such as different size and overlapping tiles (per layer), but gained a lot of other features and performance.
 
Last edited:

Nocturne

Friendly Tyrant
Forum Staff
Admin
3) Here are two tiles overlapped in GM:S 1.x - I do not believe GM: 2.x changed this. If it's not a bug then you'll have to pardon me for being really surprised.
Sorry, what you believe has no influence on the reality of things! :p

GMS tiles are on a fixed grid and can't be made to overlap, as it's one tile per grid cell. This is highly optimised and if you need anything other than this, then drop the images onto an Asset Layer, as that will be more like GMS1 tiles, and has about the same performance (actually slightly better iirc).
 
F

FormalCloud

Guest
Sorry, what you believe has no influence on the reality of things! :p

GMS tiles are on a fixed grid and can't be made to overlap, as it's one tile per grid cell. This is highly optimised and if you need anything other than this, then drop the images onto an Asset Layer, as that will be more like GMS1 tiles, and has about the same performance (actually slightly better iirc).
Ah, how silly for a customer to believe the software carried over over features they have been using for years. Thanks for that.... quip.

Per your suggestion; sprite layers were the first thing I tried but the manual doesn't list access to their depth. (x/y/angle/alpha) - but no depth. So, creating a simple depth based layer system is a bit more difficult now unless I use "tons of instances in the room" as everyone is suggesting.

I'll find my solution. Thank you.
 
F

FormalCloud

Guest
GMS 2's tile system was completely rewritten and changed considerably.

In fact Mike doesn't consister GM:S 1 to be a true tile system, he refersto it as a graphical BLOB system, nasty and performed poorly.

GMS 2 is a proper tile map system. Because of the changes we lost some of the features such as different size and overlapping tiles (per layer), but gained a lot of other features and performance.
Thank you for your answer.
 

ShaunJS

Just Another Dev
GMC Elder
Yeah 1.x "tiles" were effectively just sprite asset layers that let you place cut-up bits of your images around your room. Which you can still do now with sprite asset layers. Didn't you have to create different depths even in 1.x in order to overlap tiles? Could be forgetting something but you would definitely have to do this to make sure it stayed consistent across versions/patches.

Tilemaps are a wholly new thing that represent a grid of tile data (think of like, a ds_grid). So when you understand it this way, it's clear that there's no way to have more than one tile occupying one space of the grid, any more than it's possible to have two different values in one variable. So you accomplish the effect via layers instead.

This is more or less how tile systems work across more or less all map editors and tools (as far as I'm aware).
 
F

FormalCloud

Guest
Yeah, in GM:S 1.x I could just layer all over the place w/ transparency and it never had a problem. Even after youtube videos I didn't 'see' the change in GM:S 2 so I thought it was an error. Especially considering it's transparent in the editor, brush window, etc.

No worries! It just means that I have a bunch of layers now or use the slower "stack the room full of instances" effect.

Either way thanks for the feedback, Shaun!
 

ShaunJS

Just Another Dev
GMC Elder
Well If it helps at all, you totally should never have done that in GMS1.x without specifically setting a different depth/tile layer! It may have appeared fine in the room editor and even in game but the tiles will have been draw-ordered by a random internal system you have no control over and that is subject to change at any point throughout the software's version history. You should always have explicit draw ordering.

A lot of people got burned by this when using objects on the same depth with an order that "just worked" when they placed them, then later broke a few patches down when the internal system changed.
 

gnysek

Member
From the image above, I think you want to place sprite on asset layer instead of using tilesets. There's only one combination of this image possible, and you have a lot of same tile squares (exactly same pixels) in it, so it's not optimized too.
 
Y

yaragad

Guest
I had the same problem, but can't change the design :)

upload_2019-3-21_11-42-41.png

And its ok, its perfectly explained in this thread and understandable. Then, what is better in terms of performance?:
1. Multiple layers with few tiles.
2. One layer with multiple objects
3. ?

I think "1" is the answer, but just to be sure.

Thanks guys!! GMS2 is really improved from 1.4 and the option for 2D game creation (and 2.5). Sorry, I use Unreal for 3D lol
 
Y

yaragad

Guest
Ok, for me the solution is Assets. Nice performance, fast editing.
 

rIKmAN

Member
Ok, for me the solution is Assets. Nice performance, fast editing.
2017 is happy you found a solution.

In all seriousness though, you shouldn't necro bump posts that are this old, it's always better to create a new thread of your own with the question / issue and a nice descriptive thread title to make searching easier for others in the future.
 
Top