For starters, I needed a temporary wall to experiment with and see what would look best for the game. I drew up a very simple and fairly terrible pipe in Photoshop, for what was intended it was fine!

Firstly, I decided to have a look at how I would detect the players proximity to the wall rather than the effect that was going to indicate the secret. Thankfully there is a great function of 'Vector2' called 'Distance'! Using this, all I had to do was specify what distance between the two objects would trigger the effect.
I tried out a couple of different effects on the wall, such as a pulsating effect and one that grows the pipe temporarily. But we settled with what we thought looked best, which is a fading effect on the pipe. For this effect I needed a few new fields, such as an alpha value and a speed at which to fade.
After trying out different speeds and different levels of opacity, I settled with a slow(ish) fade to half opacity when the player is within a certain distance of the pipe.

(You can ignore the end of the relentless enemy in that last picture!)
terrible terrible pipe!
ReplyDelete