- Home /
Sprites keep overlapping
The tree sprites in my game key over lapping, I cant put them on different z because it would cause conflict at the joins of the individual road pieces, I've even tried rotating the trees so that the base is technically further back but it still wont work. Is there a method or option that i can use to fix this
ty is advance
Answer by Nodgez · Mar 12, 2014 at 11:49 AM
You can try setting the order in layer property of the sprite renderer
thanks it will take a long time to sort them all but it did the trick
I'm not sure if you have access to the order in layer property through code but what you could do is make a script that sets the order on layer based on the y value of the transform
Sorting Layer worked for me too. $$anonymous$$y first impulse was to set the Layer proper. Not sure what the difference is, but that didn't work.
Your answer

Follow this Question
Related Questions
Problem with a button made 2 Answers
A node in a childnode? 1 Answer
How to add event to an object 1 Answer
hit a marbel 2 Answers
Frozen camera following player 1 Answer