Godot: The open source game engine

21 readers
1 users here now

A community for discussion and support in development with the Godot game engine.

founded 2 years ago
MODERATORS
101
 
 
This is an automated archive made by the Lemmit Bot.

The original was posted on /r/godot by /u/snkot on 2025-01-26 18:39:24+00:00.

102
 
 
This is an automated archive made by the Lemmit Bot.

The original was posted on /r/godot by /u/Relink07 on 2025-01-26 18:00:27+00:00.

103
 
 
This is an automated archive made by the Lemmit Bot.

The original was posted on /r/godot by /u/RadicalRaid on 2025-01-26 17:03:26+00:00.

104
 
 
This is an automated archive made by the Lemmit Bot.

The original was posted on /r/godot by /u/spicedruid on 2025-01-26 17:36:01+00:00.

105
 
 
This is an automated archive made by the Lemmit Bot.

The original was posted on /r/godot by /u/Earthian10 on 2025-01-26 15:19:02+00:00.

106
 
 
This is an automated archive made by the Lemmit Bot.

The original was posted on /r/godot by /u/QuirkyDutchmanGaming on 2025-01-26 13:57:45+00:00.

107
 
 
This is an automated archive made by the Lemmit Bot.

The original was posted on /r/godot by /u/Nepacka on 2025-01-26 13:54:35+00:00.

108
 
 
This is an automated archive made by the Lemmit Bot.

The original was posted on /r/godot by /u/HexagonNico_ on 2025-01-26 13:16:03+00:00.

109
 
 
This is an automated archive made by the Lemmit Bot.

The original was posted on /r/godot by /u/WestZookeepergame954 on 2025-01-26 12:27:41+00:00.


Hi guys!

A few months ago, we released Prickle on Steam. We thought it might be useful to share some of our knowledge and give back to the Godot community.

So here are two simple shaders we've used:

  1. Dark mode + contrast adjust.
  2. Water ripples shader (for the water reflection).

I'll leave a comment with a full-length video tutorial for each shader.

(But you can also simply copy the shader code below)

If you have any questions, feel free to ask. Enjoy!

A short demonstration of both shaders

Dark mode shader code:

shader_type canvas_item;

uniform sampler2D SCREEN_TEXTURE : hint_screen_texture, filter_linear_mipmap;

uniform bool invert = false;
uniform float contrast : hint_range(0.0, 1.0, 0.1);

void fragment(){
  const vec4 grey = vec4(0.5, 0.5, 0.5, 1.0);
  float actual_contrast = (contrast * 0.8) + 0.2;
  vec4 relative = (texture(SCREEN_TEXTURE, SCREEN_UV) - grey) * actual_contrast;

  if (invert) {
    COLOR = grey - relative;
  } else {
    COLOR = grey + relative;
  }
}

Water ripples shader code:

shader_type canvas_item;

uniform sampler2D SCREEN_TEXTURE : hint_screen_texture, filter_linear_mipmap;
uniform sampler2D noise : repeat_enable;
uniform float speed : hint_range(0.0, 500.0, 0.5);
uniform float amount : hint_range(0.0, 0.5, 0.01);
uniform float x_amount : hint_range(0.0, 1.0, 0.1);
uniform float y_amount : hint_range(0.0, 1.0, 0.1);
uniform vec4 tint : source_color;
uniform vec2 scale;
uniform vec2 zoom;

void fragment() {
float white_value = texture(noise, UV*scale*0.5 + vec2(TIME*speed/200.0, 0.0)).r;
float offset = white_value*amount - amount/2.0;
vec2 offset_vector = vec2(offset*x_amount, offset*y_amount);
COLOR = texture(SCREEN_TEXTURE, SCREEN_UV + offset_vector*zoom.y);
COLOR = mix(COLOR, tint, 0.5);
}

110
 
 
This is an automated archive made by the Lemmit Bot.

The original was posted on /r/godot by /u/catsoft on 2025-01-26 11:20:51+00:00.

111
 
 
This is an automated archive made by the Lemmit Bot.

The original was posted on /r/godot by /u/CastersTheOneAndOnly on 2025-01-26 10:09:56+00:00.

112
 
 
This is an automated archive made by the Lemmit Bot.

The original was posted on /r/godot by /u/iy4halt on 2025-01-26 09:14:02+00:00.

113
 
 
This is an automated archive made by the Lemmit Bot.

The original was posted on /r/godot by /u/DangerousAnimal5167 on 2025-01-26 08:54:53+00:00.

114
 
 
This is an automated archive made by the Lemmit Bot.

The original was posted on /r/godot by /u/Deputy_McNuggets on 2025-01-26 08:10:47+00:00.

115
 
 
This is an automated archive made by the Lemmit Bot.

The original was posted on /r/godot by /u/KeiMuriKoe on 2025-01-26 04:00:20+00:00.

Original Title: My GF VS ME

116
 
 
This is an automated archive made by the Lemmit Bot.

The original was posted on /r/godot by /u/Oblongjapanda on 2025-01-26 03:36:02+00:00.


Hey there, I actually made a game and wanted to show a little bit of it to those of you who helped me when I had questions, felt totally lost and wasn't confident in my abilities! Thank you so much. This subreddit is a very nurturing environment where it seems people want to pass on their knowledge and help them succeed. The game is far from done, but I have a playable build of the game I had in my head now turned into a video game. It's been a wild ride and to those who are not confident or hit a big snag, keep moving! and ask questions!

117
 
 
This is an automated archive made by the Lemmit Bot.

The original was posted on /r/godot by /u/michugrypl on 2025-01-26 00:09:50+00:00.

118
 
 
This is an automated archive made by the Lemmit Bot.

The original was posted on /r/godot by /u/cikirie on 2025-01-25 23:20:29+00:00.

119
 
 
This is an automated archive made by the Lemmit Bot.

The original was posted on /r/godot by /u/mustydev on 2025-01-25 21:46:15+00:00.


Here is the repository for open-source Godot games on GitHub that might help you create games:

For now, the list is very small. But I'll definitely update it time to time!

Before making a pull request of your project make sure that it has a license, a gameplay video or some photos of it with a description on its readme file.

120
 
 
This is an automated archive made by the Lemmit Bot.

The original was posted on /r/godot by /u/ElementLGames on 2025-01-25 20:53:07+00:00.

121
 
 
This is an automated archive made by the Lemmit Bot.

The original was posted on /r/godot by /u/Pizza_Doggy on 2025-01-25 20:52:06+00:00.

122
 
 
This is an automated archive made by the Lemmit Bot.

The original was posted on /r/godot by /u/xan-1027 on 2025-01-25 18:34:50+00:00.

123
 
 
This is an automated archive made by the Lemmit Bot.

The original was posted on /r/godot by /u/totallydontslay on 2025-01-25 18:10:50+00:00.

124
 
 
This is an automated archive made by the Lemmit Bot.

The original was posted on /r/godot by /u/awaistt on 2025-01-25 17:10:35+00:00.

125
 
 
This is an automated archive made by the Lemmit Bot.

The original was posted on /r/godot by /u/TheDahoom on 2025-01-25 16:34:45+00:00.

view more: โ€น prev next โ€บ