2D Lighting and Day&Night cycle in under 5 minutes! Godot 3.2 Tutorial

preview_player
Показать описание
In this Godot Engine tutorial, I show you how to set up 2D lighting, including advanced shadows and a simple Day&Night cycle mechanic!

⌚ Timestamps

0:00 Intro
0:27 Basic 2DLight setup
1:24 Ambient Lighting
1:44 Dynamic Shadows
2:35 Improved Shadows
3:06 Day&Night cycle

#gamedev #tutorial #godot #gamedevelopment #bitbrain #fast #quick #lighting #godot #godotengine #daynightcycle #dynamiclighting #2d

Music Credits

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

Thank you so much for watching my Godot tutorial series! Make sure to check out other Godot tutorials on my channel.

It would absolutely help me if you hit that subscribe button and also click the bell button to not miss out on future uploads.

EDIT: you can still see at 3:06 that wall shadows are shown on the player. The correct way to fix this is by setting the item cull mask on the Light2D and the light mask of the player sprite.


- Miguel

bitbraindev
Автор

This was an excellent tutorial, I learned a lot. My prototype day/night cycle was far, far more complex than it needed to be before watching this. Great job!

DevDuck
Автор

Thank you for this! The more I learn about Godot the more I realize how amazing this engine is.

dylzdesigns
Автор

Wow. That was really cool! The duplicate point lights...I would not have thought of that. Thanks for showing us this. Liked and subscribed.

scottisitt
Автор

For long days and nights use this function in GODOT 4: self.color = NIGHT_COLOR.lerp(DAY_COLOR, (sin((PI/2)*cos(time))+1)/2)

hoihoi
Автор

Fantastic format, lots of info, very quick explanations and a Github project to work with. Bravo.

bstar
Автор

I don't use Godot, but if I ever do, this looks amazing, and will definitely come back to this video! Good Job!!

VuVuuInc
Автор

is abs(sin(time)) really the way to go? That way the function is bumping back from the X axis and makes night (or day) way too short. Shouldn't it rather be (sin(time)+1)/2 in order to lift the whole function above the axis and make it scale between 0…1?

Alltagsabenteuer
Автор

This is exaclty what I needed for my game right now haha! Good timing!

gamedevel
Автор

Great tutorial. Straight to the point and very informative.

arkbjorn
Автор

Really nice results and explained in an effortless way. Thanks for sharing the source. So much to learn still...

salarycat
Автор

after finishing my own cycle i wanted to see how other people did it. i cant believe how much this tutorial taught me! now im going to rewrite my stuff tho :S

knuddlerinokripperino
Автор

I don't code, and I never imagined something that looked that simple could have so much going on! Everytime I see a tutorial like this, I gain some more respect for indie game devs out here :3

chaomatic
Автор

Really helpful and easy to understand! The editing was done really well so my attention was 100% focused on the right parts of the video

foofightfox
Автор

nice job! Nice usage of linear interpolate :)

RafaFiedo
Автор

abs(sin(time))) will make nights shorter than days, Instead do range_lerp(sin(time), -1, 1, 0, 1)

great content btw <3

potatolord
Автор

your content has always been my go to video when it comes to godot :D

arttriesgamedev
Автор

Cool stuff bbrain! 2D lighting is something that looks pretty cool! Nice job!

malimakes
Автор

Could you put your layout files in the description? I really like the code font and colors :)
Nice vid!

ilayws
Автор

thanks for the tutorial. where is the tilemap occlusion option in godot 4.3?

secroit