Files
GameJam2023/Textures/Shaders/ScrollShader.gdshader
GameJammer 54b044142d fun stuff
2023-09-14 14:17:27 -07:00

14 lines
375 B
Plaintext

shader_type spatial;
render_mode blend_mul;
uniform vec2 direction_and_speed = vec2(0.25, 0.25);
uniform vec2 scale = vec2(1.0);
uniform bool flip = true;
uniform sampler2D albedo: hint_default_transparent;
uniform float alphaSet = 0.0;
void fragment() {
vec2 uv = UV * scale - direction_and_speed * TIME;
if (flip) { uv = 1.0 - uv; }
ALBEDO = texture(albedo, uv).rgb;
}