Silhouette when behind an object

0 favourites
  • 3 posts
From the Asset Store
This is a single chapter from the "Construct Starter Kit Collection". It is the Student Workbook for its Workshop.
  • Hello!

    Glad to see there is a Construct 3 forum here, now!

    I'm making a top-down action game, with a camera similar to a Zelda.

    What I want to do is, when the player (the red fruit behind the tree) and other moving objects like enemies (those ladybugs behind the other tree) are behind an object (here, trees), to display their silhouette like in many games with that sort of problematic.

    Something like this.

    Now I'm sure this is doable with some clever tricks, masks, and blend modes; but I didn't find those tricks. What I'm thinking is a separate layer with plain color tiled backgrounds, and a masking system that only allows part where there is the tree AND the player/object to be visible. Or maybe, a more simple masking system with a clever blend mode/webgl effect.

    What do you think?

    Thanks a lot for your help!

  • Do a search on the c2 forum for Silhouette, there are examples.

    You can either set a layer to "force own texture" and then put a duplicate of the object tree on it to act as a mask, then on the same layer a duplicate of the character with blend mode "source atop" or "destination out", can't remember which, then when it overlaps the mask it should work as you want. The mask colour will determin the colour of the silhoutte of the character duplicate which will be invisible until it overlaps the mask.

    The other option i used for a game was simply to have a duplicate of the character set to something like 40% opacity and always have it on top of the layer so when it overlaps something you can still see the image rather than a dark shade.

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • I'll try that, thanks.

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)