ive been having this problem where in the editor (and only the editor) i get these weird black horizontal lines on my tilemap, i had one project where i got rid of them but i cant duplicate it in this new project heres the settings i have and heres a close look, please help i cant find anything online
That's completely normal - they're just the grid lines, which aid you in positioning tiles. You can choose to switch them on and off in the Gizmos tab above the scene window.
It isnt, my grid is set to a gray color which you can see in the first picture, and these black lines are only going horizontal, i also know it isnt my grid because they dont cover the player sprite
Actually looking closely at the sprite, both the horizontal and vertical lines do appear to cover the sprite, they just change to reflect the sprite colour underneath. What happens when you switch off the grid lines? Do both the vertical/horizontal lines disappear?
like i said my grid is gray not black, when i turn off the grid it gets rid of the grays lines not the big black lines that are going horizontal
Okay, that's the first time you've mentioned the lines are still there with grid lines switched off. In that case I'm unsure why horizontal lines would be showing in the scene view. Perhaps could be worth looking at the tiles themselves - the spritesheet should be set to Point instead of Bilinear for example.
Sorry to bump this old thread but I am running into the exact issue you are. My in the Scene view, and only the scene view, are picking up a very small line (like way less than a pixel) at the bottom of each tile from the tile underneath it in the palette. It doesn't effect the actual game, but it is quite an eyesore and a pain when making new maps. It seems it's just a rendering issue with scene view or something, but I would really like to get this resolved so I don't have to use Tiled to make my maps and lose some functionality. I tried so much googling and only found this thread with the same issue. The rest were talking about the same issue, but in game, which is not the issue I'm having. Did you ever find a way to resolve this issue?
For me, originally no. I tried after adding them to the atlas and the same issue was still happening.
These are my current Atlas settings. I'm fairly new to Unity and never used the Atlas before so I could be doing something wrong. https://i.imgur.com/32q7s6d.png
In fact, I am running out of ideas... Your settings look OK to me. Just try to change Padding from 4 to something else, but this value should be OK. In most cases, that lines (bleeding) you see are because GPU takes from one position by. Also check if anti-aliasing is off in Editor -> Project Settings -> Quality and also on camera. Try placing something under grid to see if it is grey color on tile or gery color of background (= transparent line). If it is transparent, then try to split your atlas into two - one for transparent objects and second for non-transparent things.
Ive been through all that already haha. Its definitely a color from the tile below it in the tileset. Its just a rendering bug for the scene view I was hoping I could find a fix for. Thanks for the help though. I think I'm just going to have to used Tiled and lose some functionality with Unity sadly. I know the game view still looks fine, but the lines are really bothering me when designing maps.
After days of frustration I was finally able to find an answer from the Unity discord. Turns out I needed to turn off Pixel Snap in my shader on the tilemap object as seen here: https://i.imgur.com/td1AA6x.png Hope this helps someone else out in the future. No lines! https://i.imgur.com/sSpd8N5.png
I had issues with black lines appearing when I zoomed in/out in my 2d top down game. Turning on pixel snap in the shader the tilemap objects are using seems to have solved it.