I want to know if there is a problem with the shader I made

I tried to make “Particle_Additive” and “Shader_Particle_Alpha Blend” with AmplifyShaderEditor. The texture uses 32 bits of TGA + Alpah channel.
Since I know very little about shaders, I would like to ask if there is anything wrong with the shader I made this way? Please let me know if there is a problem so that I can improve it, thank you

Hello !

You don’t have to make two similar shaders with two different blend modes, in Amplify you can expose floats and assign them to the left pannel properties; and change them directly in the inspector :

You need to create two floats like these, put them in property mode, also activate the Auto register checkbox (it will allow your property to be shown in the inspector even if it’s not linked to other nodes)
Next, you can configure your floats to behave like enumerator classes in the inspector by using the Enum checkbox and choose the “Blend Mode” engine class

Now, if you click on the little dot at the right of your blend modes, you will be able to choose your newly created floats

image

And now, in the inspector, you will have two properties that will drive your material blend mode

image

You can now have a single shader with multiple blend modes :smile:

Also, the blend mode for additive is One One :+1:

Don’t hesitate if you have any questions !

3 Likes

You could probably drop the precision to from Float to Half without any noticeable lowering of quality and gain an increase in performance. It’s quick to check and can be set back to Float if you feel you do need it.

If you’re targetting mobile devices then lowering Shader Model to 2.5 will increase device compatibility.

Thank you, this is useful.
My concern is whether the shader nodes are connected correctly.