new eye damage effect (#10728)

This commit is contained in:
Nemanja
2022-08-20 16:17:58 -04:00
committed by GitHub
parent d67669ad34
commit 512e96eed4
3 changed files with 26 additions and 12 deletions

View File

@@ -0,0 +1,12 @@
uniform highp float DAMAGE_AMOUNT;
void fragment() {
// Higher exponent -> stronger blinding effect
// Gradually mixes between the texture mix and a full-white texture, causing the "blinding" effect
highp vec4 mixed = mix(vec4(1.0, 1.0, 1.0, 1.0), vec4(1.0, 1.0, 1.0, 1.0), DAMAGE_AMOUNT);
COLOR = vec4(mixed.rgb, DAMAGE_AMOUNT);
}