Using shader in Godot 4
We gonna learn how to use shader to give a feedback of our enemy and our player getting hurt. We are going to create export color that we can set up in the inspector, and we gonna trigger the shader through the code. Like & Subscribe! :)
#godot4 #godotengine #godot #shaders #godotshaders #shadertutorial
Asset link is here: https://jeanmakesgames.itch.io/2d-rpg-asset
Godot shaders: https://godotshaders.com/
Wishlist my game "Lone Knight" here: https://store.steampowered.com/app/2211930/Lone_Knight/
**Udemy Course:**
For halloween I'm discounted my courses, valid until the 31st of October! :)
My godot engine 4 course is discounted here:
https://www.udemy.com/course/learn-godot-4-by-making-a-2d-game/?couponCode=HALLOWEENGODOT
Coupon Code: HALLOWEENGODOT
Create a 2d platformer / metroidvania in godot engine 3:
https://www.udemy.com/course/create-a-2d-platformer-game-with-godot-engine/?couponCode=HALLOWEENGODOT
coupon: HALLOWEENGODOT
Create a 2d rpg with godot engine 3:
https://www.udemy.com/course/create-a-2d-rpg-with-the-godot-engine/?couponCode=HALLOWEENGODOT
coupon: HALLOWEENGODOT
Learn C# in godot 3 by creating a 2d rpg:
https://www.udemy.com/course/learning-csharp-with-godot/?couponCode=HALLOWEENGODOT
coupon: HALLOWEENGODOT
Happy halloween to everyone!
Timeline:
00:00 Preview
00:09 Introduction
01:27 Opening the scene of our enemy
01:49 Creating the shader
03:30 Overview of the type of shader available in Godot
04:14 Starting to code the shader
07:20 Creating export variable for the color
01:19 Triggering the shader through code
12:37 Testing the code
13:30 Adding the shader to the player
14:40 Creating a hitbox to trigger the shader
15:55 Calling the shader function in the hitbox
18:27 Last fix on the hitbox collision