shader_type canvas_item; uniform float threshold: hint_range(0.0, 1.0) = 0.3; uniform float speed = 0.5; uniform vec4 color_hi : source_color = vec4(1.0, 1.0, 1.0, 1.0); uniform vec4 color_low : source_color = vec4(0.0, 0.0, 0.0, 1.0); uniform sampler3D base_noise: repeat_enable; void fragment() { vec4 noise_color = texture(base_noise, vec3(UV.x, UV.y, TIME * speed)).rgba; COLOR.rgba = noise_color.r > threshold ? color_hi : color_low; }