Capped the max opacity allowed in the shader to an extremely high value (0.995) to stop a weird issue caused by alpha being set to 1.0
Capped the max opacity allowed in the shader to an extremely high value (0.995) to stop a weird issue caused by alpha being set to 1.0. Incorporated the suggestion on how to clean up shader code