Easy to use Parallax system for 2D games

I made a pretty simple parallax blueprint for 2D games.

It consist of three small functions and a collision box attached to the camera.

When the camera moves the collision box moves with it, hitting objects which you would like to parallax.

I would like to get this on the market as free. I see a lot of 2D content questions and hopefully someone will make use of it.

Unfortunately I do not have a mic to narrate the video so I’ll explain here.

http://youtu.be/ZZWwa1W6Pqs

Seconds 0 - 55 I am demonstrating the parallax and how the depth of an object affects it’s parallax speed, without any special adjustments.

Seconds 55 - End I am building a small layout in which the parallax may be used.

The only conditions is that the sprite(or whatever you use) must be moveable, and must accept overlap collisions from the camera’s collision box.

How it works:
The original actor location of the sprite is stored when the camera collider overlaps the sprite. From there the functions performs a calculation of the camera current position vs the original location of the sprite. As camera moves closer to the sprite, the sprite moves against the camera.

In addition the further the sprite is on the Y (depth) axis the less it moves against the camera. This is a scaling function so no manual work has to be done other than moving the sprite further back.

Le me know if you have any thoughts or ideas.