PARALLAX & INFINITE BACKGROUND IN UNITY 🎮 | Create A Endless Background In Unity | Unity Tutorial

preview_player
Показать описание
In this Unity tutorial we will learn how to create a background with a parallax effect using two different methods, and learn how to make a endless background environment in Unity. 😊

➤ TIMESTAMPS

00:00:00 - What you learn in this video
00:01:10 - How to create your background!
00:03:12 - Import settings for your BG
00:04:35 - Setting up our BG in the Hierarchy
00:07:22 - The two ways to do Parallax!
00:07:58 - 1: Parallax using camera settings
00:10:29 - 2: Parallax using a C# script
00:18:00 - How to create a endless background

➤ GET ACCESS TO MY LESSON MATERIAL HERE!

First of all, thank you for all the support you have given me!

I am really glad to have such an awesome community on my channel. It motivates me to continue creating and uploading content! So thank you!

I am now using Patreon and YouTube Memberships to share improved and updated lesson material, and for a small fee you can access all the material either from my memberships or Patreon, depending on your preference. I have worked hard, and done my best to help you understand what I teach.

I hope you will find it helpful :)

Рекомендации по теме
Комментарии
Автор

I have to say I really enjoy the concept tidbits you throw in all over your videos. I'm a Java dev by trade but am just starting game dev as a hobby. The "concept space" stuff is really helpful for me to see what is possible.

deneb
Автор

Best video for that topic! Thank you very much. This a well made video and explanation for this effet and the code is as short and smart as it needs to be!

schurkino
Автор

I watched around 10 videos on this but only you explained it better with easy-to-follow working solution. I needed the same system for a vertical game, I tweaked your code easily because you explained it well. Thak you very much!

NishanCW
Автор

Thanks Dani a great tutorial, been looking at other parallax scrolling tutorials and yours explains it much better than the rest. I now have a decent background moving many thanks. onto the character controller now.

NinjaSamuraiJubei
Автор

Thanks for the informative lesson! Very helpful and easy to understand!

bumpleGrumpGames
Автор

Best parallax tutorial i've ever seen! Thank you mate.

eneseren
Автор

I gotta say, Thanks a ton for these videos!
I really appreciate you spending the time to sit down and help explain these things out in a simple to understand way.
It is really getting me back into my game design work again after a long break. (I'm more of an artist/musician than a programmer, so I need really need the explanations)
So again, Thanks a ton! I hope you keep it up. I would like to learn a lot more from you! ^_^

I ended up copying/changing this for both Y and X positions, and making to i can control each separately.
I'm not sure if what i ended up creating is any good in terms of clean code. but it looks good when the camera scrolls up/down.

BTW, the backgrounds seem to be a little bit jerky when the parallax effect happens (for both x or y position), is there a way to mack it smoother?.

WizeLoL
Автор

Small help: 1: first place the copied layers, then place them. 2. placing them seamless, is easier if you use 'v' and take the lower corner and snap them to the other one.

maddehaan
Автор

I don't know what to say! Thank you so much for making this series, you are a genius good sir 🥳😃❤! Also the amount of videos you have been putting out lately, make sure you don't forget to sleep haha😎👍

ludvigludvig
Автор

Glad I found you, keep inspiring dude!

adhityagunawan
Автор

Bro you are awesome with explaining ! ! !

canahmetdarama
Автор

You deserve a subscriber button shoot Nice video

scholars
Автор

I wonder is there a way to use perspective camera mode without having to scale the background up or making really huge assets?

Giedzilla
Автор

Awesome video! Its a big help. I do have one issue. I made different backgrounds for each layer for variety and they are stacking on top of each other when they spawn in. How do I fix that from happening? Any help is appreciated.

bwolf
Автор

Thanks for the video!
Everything is working perfectly as it should be, but background layers movement is visible in-game (I mean that background layers suddenly snaps forward). Any help?

chadfatlyf
Автор

I tried following this but when i go to the left they disappear one by one

ProbablyStraight
Автор

So, is there any way for you to explain the float temp variable? Like in even simpler terms. I understand what the code is there for when it gets compared to the startPos + length, but I don't understand why it's 1 - parallaxEffect. I know you said it gets us the position of the object at the given point in time....but I guess I don't understand how that is. I think this is more of me not getting the math behind it? I've been wrapping my head around this for a while now but it's just not clicking. I mean, the code works fine in my project, but I want to make sure that I understand every line.

stealthyshiroean
Автор

The parallax movement gets really choppy at higher speeds, how can I fix that?

michelcastilho
Автор

I'm using a confiner for cinemachine and when it reaches the end of that confiner in the x-axis the parallax effect still goes when the player moves even though the camera itself isn't moving. Is there a way to stop that effect from happening?

mkshadowzx
Автор

can you do a parallax effect without the camera moving?

Jubez