Three solutions to solve the black line/white line gap on the map when following the character camera

There are three solutions below. Here I recommend the second solution because it is fast and simple enough.

Phenomenon :
Please add a picture description
Solution 1 :

Refer to [Unity2D] Remove the black line in the map_unity is selected and wired_Mushroom CST blog-CSDN blog , the blogger explained that the problem is caused by anti-aliasing sampling.

Specifically for this game, there are two steps:

Please add a picture description
Yes Tile Set.png, modify pixel per unit, if the original ratio is 16, reduce it to 15.9
Please add a picture description
and then use the tiles as in Part1, just re-pave it again, the white line gap is unity2022unique, I have tested that 2021版本only the black line appears.

Solution two :

Refer to the "line" problem between the video content of Part3 and the tiles in Unity 2d game development - Yuluo Jiangzhou - Blog Garden (cnblogs.com) This article content, change the default material.

Add a new material
Please add a picture description
, check the pixel capture
Please add a picture description
, and then attach this material to the material properties of the tile map rendering.
Please add a picture description
Solution 3 (I have not verified it) :

Refer to Solve the Tilemap Gap Problem in Unity | I am a monster ~ Liao Yulei (dualface.github.io) This article can be dealt with.

Guess you like

Origin blog.csdn.net/kokool/article/details/132414376