[gd_resource type="ShaderMaterial" load_steps=2 format=2] [sub_resource type="Shader" id=1] code = "shader_type canvas_item; uniform float alphaChannel=1; void fragment() { //vec4 pixelColor = texture(TEXTURE, UV); COLOR = texture(TEXTURE, UV); //float newAlpha=(alphaChannel); //vec2 fromCenterVec=UV.xy-vec2(0.5,0.5); //if (newAlpha>=0f){ // COLOR.a=30.64*newAlpha*length(fromCenterVec); //} else COLOR.a=0f; COLOR.a=alphaChannel; }" [resource] shader = SubResource( 1 ) shader_param/alphaChannel = 0.2