Files
project-thor/Shaders/outline.gdshader
Nikolai Fesenko c473c0a2fb new outline shader
2025-08-16 18:34:52 +02:00

26 lines
471 B
Plaintext

shader_type spatial;
render_mode cull_front, unshaded;
uniform bool is_active;
const vec3 color = vec3(0.95, 0.71, 0.01);
const float thickness = 0.1;
void vertex() {
if(is_active) {
VERTEX += NORMAL * thickness;
}
}
void fragment() {
if (is_active) {
ALBEDO = color;
ALPHA = 0.5;
}
}
//void light() {
// // Called for every pixel for every light affecting the material.
// // Uncomment to replace the default light processing function with this one.
//}