- Home /
How to use multiple Sprite Mask ?
Hi, I've never been able to mask ONE sprite in a single scene, if I click "use mask interaction" in different gameobjects all of them share all the masks even if they're in separate GO... :/
How to have specific masks for specific sprites ?
Thank you all :)
Answer by MatthewOCallaghan · Sep 16, 2018 at 12:05 PM
Two options:
Firstly, you could use a sorting group. If the sprite mask is on the same object as the sorting group or on one of its children, it will only apply to sprites that fall within the group (i.e. sprites on the gameobject that has the sorting group and its children).
Secondly, you could use a custom range in each sprite mask. Give each sprite renderer to be masked a unique sorting layer/order combination and then set each sprite mask's custom range to only affect the required sorting layer/order. Then each sprite renderer will only be masked by one sprite mask and not all of them.
Answer by finbogg · Oct 30, 2019 at 10:38 PM
Would it be possible to have a sprite visible inside of one sprite mask, but hidden behind another sprite mask?
Using just sprite masks, not that I'm aware of. Though would be very interested if I'm wrong
Your answer
Follow this Question
Related Questions
how do i mask a sprite against a canvas? 1 Answer
How to prevent transparent objects overlap 0 Answers
How would I create a mask based on my tilemap 2 Answers
Deform sprite using SkinnedMeshRenderer 0 Answers
Scroll View and Hiding Sprites 2 Answers