# Scrolling in 3d Shmup with 32Bit era effects

How can I create a scrolling effect like in Ikaruga, where the background is on Rails and the foreground is fixed with the player in Unity?

Some more features would be:

• Hi Vicky, usually questions that do not have one specific answer (like brainstorming, asking opinions or asking for material to read online) tend to be off-topic here. If you start working on the game you are describing, and have difficulty creating an effect that you saw on another game, that would be more on-topic. – TomTsagk Jan 8 at 16:35
• Oh Sorry bout that. Yeah i had teh feeling the question is a bit too general. I change my question from brainstorming. – Greencurbwalker Jan 8 at 17:20
• Generally all you need to do to make these sorts of things on-topic here is, instead of asking for resources about "doing thing X" just ask "how do I do thing X?" – Josh Jan 8 at 17:26
• Ok guys I edited and shortened my question. Thanks for the clarifications. – Greencurbwalker Jan 8 at 17:47
• You've asked at least five different questions here. In future, if you feel the need to add a bulleted list of "more features..." or "my questions are..." try asking just the first one, then see if the answer leads to you a solution for the others. If not, post a new question about the next bullet point you need help with. Keeping a question narrowly focused helps get detailed, in-depth answers faster. – DMGregory Jan 11 at 13:15

I would actually do this with two separate cameras rendering objects with two different culling masks.

• One camera which moves through a 3d scene controlled by a Timeline - Unity's new recommended way of doing cinematic cutscenes.
• One non-moving camera which shows the actual gameplay. This camera would be set to Clear flag: Depth only and Depth higher than the previous camera. This makes the render output of the first camera the background of the second.

This would allow me to implement the gameplay just like the official space shooter tutorial while I have the freedom to create the background scene in any way I want.

Another option: I suspect that some of these games might actually just play a pre-rendered movie in the background. If you want to go that way, you can use a Movie Texture to play videos created with a 3d animation software of your choice.

• Thanks for the interesting suggestion Philipp. I really dont have much experience with the unity cameras and its capabilities. So thats definetly a good "recipee". I worked through the spaceshooter tutorial of unity which got me started in the first place. Do you have any suggestions how to create the 3d level environment? E.g if i want to have mountains the player needs to avoid while flying near ground using meshscrolling together with Rock-gameobjects is difficult because i need to match the scrolling of the mesh to the speed of the gameobject coming towards the player. – Greencurbwalker Jan 8 at 20:35
• Sorry need to add something. ... Terrains on teh other hand cannot be scrolled very fast using translation.and if they have different heightlevels aligning them with the translation technique is impossible as there are gaps between the heights as well. I can provide screenshots from my game if necessary. – Greencurbwalker Jan 8 at 20:37
• @Greencurbwalker Terrains are not supposed to be translated. If you want to create a camera flight through a terrain you should rather move the camera instead. – Philipp Jan 8 at 22:16
• @Greencurbwalker Terrain collisions are not really in the scope of this questions, so you should post this as a new question. – Philipp Jan 8 at 22:20
• ok. I am marking this answer as accepted. As I will test it out by creating a small demo. Thanks dude! – Greencurbwalker Jan 9 at 12:48