Started on platforms. Updated player movement.
Before Width: | Height: | Size: 418 KiB After Width: | Height: | Size: 21 KiB |
BIN
res/img/player/player_effect.png
Normal file
After Width: | Height: | Size: 15 KiB |
Before Width: | Height: | Size: 341 KiB |
Before Width: | Height: | Size: 289 KiB After Width: | Height: | Size: 9.6 KiB |
Before Width: | Height: | Size: 470 KiB After Width: | Height: | Size: 25 KiB |
|
@ -1,19 +0,0 @@
|
|||
#version 330 core
|
||||
|
||||
uniform sampler2D layer0;
|
||||
uniform sampler2D layer1;
|
||||
|
||||
uniform float offset0 = 1;
|
||||
uniform float offset1 = 1;
|
||||
|
||||
in vec2 texCoords;
|
||||
|
||||
out vec4 color;
|
||||
|
||||
void main() {
|
||||
vec4 color0 = texture(layer0, texCoords + vec2(0, offset0));
|
||||
vec4 color1 = texture(layer1, texCoords + vec2(0, offset1));
|
||||
color = mix(color0, color1, 1 - color0.a);
|
||||
if (color.a == 0)
|
||||
discard;
|
||||
}
|
13
res/shaders/s2e/frag.gls
Normal file
|
@ -0,0 +1,13 @@
|
|||
#version 330 core
|
||||
|
||||
uniform sampler2D sampler;
|
||||
|
||||
in vec2 texCoords;
|
||||
|
||||
out vec4 color;
|
||||
|
||||
void main() {
|
||||
color = texture(sampler, texCoords);
|
||||
if (color.a == 0)
|
||||
discard;
|
||||
}
|
|
@ -1,5 +1,6 @@
|
|||
#version 330 core
|
||||
|
||||
uniform vec4 subtexture = vec4(0, 0, 1, 1);
|
||||
uniform mat4 mvp;
|
||||
|
||||
layout (location = 0) in vec3 vertices;
|
||||
|
@ -8,6 +9,6 @@ layout (location = 1) in vec2 itexCoords;
|
|||
out vec2 texCoords;
|
||||
|
||||
void main() {
|
||||
texCoords = itexCoords;
|
||||
texCoords = itexCoords * subtexture.zw + subtexture.xy;
|
||||
gl_Position = mvp * vec4(vertices, 1);
|
||||
}
|
|
@ -1,5 +1,6 @@
|
|||
#version 330 core
|
||||
|
||||
uniform vec4 subtexture = vec4(0, 0, 1, 1);
|
||||
uniform mat4 mvp;
|
||||
|
||||
layout (location = 0) in vec3 vertices;
|
||||
|
@ -8,6 +9,6 @@ layout (location = 1) in vec2 itexCoords;
|
|||
out vec2 texCoords;
|
||||
|
||||
void main() {
|
||||
texCoords = itexCoords;
|
||||
texCoords = itexCoords * subtexture.zw + subtexture.xy;
|
||||
gl_Position = mvp * vec4(vertices, 1);
|
||||
}
|