shader_type spatial; render_mode blend_add,unshaded,depth_test_disabled; uniform sampler2D tex_main : source_color; uniform sampler2D tex_noise : source_color; uniform sampler2D tex_mask : source_color; uniform sampler2D tex_mask2 : source_color; uniform sampler2D screenTexture : hint_screen_texture; void fragment() { vec4 col_main = texture(tex_main, UV); vec4 col_noise = texture(tex_noise, UV - 0.5 * vec2(mod(TIME, 2.0) - 1.0, 0)); vec4 col_mask = texture(tex_mask, UV); vec4 col = col_mask * COLOR * 1.0 + (col_noise + col_main) * COLOR; vec4 col_mask2 = texture(tex_mask2, UV); float noiseValueX = col_noise.r; float noiseValueY = col_noise.r; vec2 noiseDistort = vec2(noiseValueX, noiseValueY) * 0.1 * col_mask2.r; vec3 distortedScreenTexture = vec3(texture(screenTexture, SCREEN_UV + noiseDistort).rgb); ALBEDO = (distortedScreenTexture *4.0 + col.rgb * col_mask.r) * COLOR.rgb; ALPHA = col_mask2.r * COLOR.a; }