2.5D parallax effect in GODOT 2D engine. Similar to the background parallax in Hollow knight!

preview_player
Показать описание
This video outlines a good method to create a pseudo 3D or 2.5D parallax effect in the GODOT 2d game engine. This parallax is different from the one you often see in endless scroller games, and does not use the ParallaxBackground node. Hollow knight implements its parallax using the 3D engine, which has some advantages in regards to lighting. However, the parallax effect will function the same way using this method and it is better for anyone preferring to work in the 2d-engine.

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

In regards to the method of darkening the foreground, the method given is not the best. What is probably better is to nest all sprites under a Node2D (so that you can toggle and untoggle visibility). And on top of that use canvasmodulate to darken all the sprites on that canvaslayer.

NonsensicalD
Автор

In case anyone looked for Godot 4 shader, I found that this shader script works just like in the video:
shader_type canvas_item;

uniform float lod: hint_range(0.0, 5.0) = 0.0;
uniform sampler2D SCREEN_TEXTURE: hint_screen_texture, filter_linear_mipmap;

void fragment() {
vec4 color = texture(SCREEN_TEXTURE, SCREEN_UV, lod);
COLOR = vec4(color.rgb, 1.0);
}

karlas
Автор

This. Precisely this video is what I was looking for. Thank you so much for an awesome vid!

bluekitty
Автор

the problem here comes when you put an object that's far away in the level, and by the time you go to it, the parallax objects you set are also moved way beyond that level. For example, if you have a house and a parallax tree behind it, if it's really far, when you get to the house, the tree basically has now moved far away from the house. in an actual 3D environment, this wouldn't be the case, the tree will still be beside the house because how parallax works there is that the farther away an object is, the slower it's parallax movement, and when you get closer, the parallax inversely gets faster

OzzbitGames
Автор

I'm so glad I decided to try Godot, I spent an unreasonable amount of time trying to get this effect to work in UE4 with no luck.

Hafgren
Автор

Thank you for this. The best 2.5D example I've seen.

strider
Автор

Amazing, dude! Greetings from Brazil!

robertofauri
Автор

I just wanna say thank you for showing this tutorial I've tried it on my little point and click game, it's perfect TwT

bluespider
Автор

your vids are so good, you got a new sub

morganp
Автор

This is ageing extremely gracefuly with the recent unity fiasco. I came back to this video because i remembered that you are also developing in godot. Potential idea for a video, how to setup a hollow knight like camera in godot, with the resolution size, edge pannings, secret room panning etc

LANMEE
Автор

Fantastic video my guy, been enjoying your stuff! You deserve more recognition :D

sabotagethefool
Автор

Great video, I am just start to learing game development and this technique what i want to use in my future game. thanks.

vkronik
Автор

Had no idea this was so simple to implement in Love your art style and how you’re focusing on beautiful platformer games! You should totally do a Godot course on this! I’m almost finished with another Blackthornprod Unity course and kind of wish more tutorial creators adopted their format - you provide solid code and a simple solid game, but really encourage the viewer to make their own game art. It’s such a simple concept I seriously wonder why there aren’t more courses like this. I’m mentioning this here because if you were interested I could totally see your teaching+ art style creating something in this format. Regardless, thanks for this video!

pianoatthirty
Автор

I love this short no-nonsense tutorial like this. Straight to the point.
Can you make the fireflies tutorial next?

HamdiRizal
Автор

Perfect !!! Thanks ! Thanks ! Thanks !

felipefacundes
Автор

Do you always use a tilemap for the level blocking? Or sometimes static bodies? Or a mix? I was using a tilemap but once I got a lot of tiles in it it started to slow down. And I didn't really consider my level that big. Great video, btw!

JasonLothamer
Автор

By far the best channel for 2D game development... the way you explain things is so simple & easy to understand! Do you think you could do a version of this tutorial for Unity? 😅 Or do you exclusively use Godot?
Edit: I see now the thing I'm thinking of is the 2.5D layering... a video on that would be great too!!

Abby-ugxc
Автор

You are the best, thank u very much for this guide, i catched it and then im going to watch other your videos
Is it possible to make in godot such a visualization in a 2d platformer with a 3d object: the character stands to the left of the object and sees the front side and the left side of the object, similarly to the right side?
sorry if the question is stupid, I've only been in game development for a couple of days and I don't know much yet

rakhmanovtr
Автор

Have you made a vid on the fireflies background? That would be great. It's a beautiful effect.

morganp
Автор

thanks for showing this! I hope to someday make a game with sprites I have drawn. Do you have other videos on how to get your drawings into unity without issues? I’m guessing make sure that the background is transparent. And it has to be a PNG file, correct? I don’t know if sizing matters when being drawn or anything.
If you ever want to go more into details over this sort of thing for complete noobs like myself that would be amazing! Thanks for showing how you create tiles for your playable area first! Is it coding you put in to make it solid? I still have so much to learn but I’m trying!!!
Thanks for your time 😊

wells