Search Unity

Resolved Mask an gameobject with Image component with a Particle component

Discussion in 'General Graphics' started by khrysller, May 22, 2021.

  1. khrysller

    khrysller

    Joined:
    Mar 14, 2019
    Posts:
    125
    Hello. Hope this is the best place to ask this question. I am trying to achieve a result but without success. So here is the case. I have visually, the following layer layout:

    Background Layer 1 - Dark color (most behind)
    Background Layer 2 - Bright color (middle layer)
    Particle Layer - random 2d squares moving from bottom to top (most top layer)

    The situation I am trying to create is:

    - The Background Layer 1 - Dark color will be always visible
    - When the squares from the Particle Layer start to go from Bottom to top will will reveal the Background Layer 2 inside of the squares (like a mask effect or maybe a Chroma Key?)

    Is that possible to do in Unity? I am pretty lost here any help would be great.

    Thanks.