First commit of the starter kit.

This commit is contained in:
Zed A. Shaw 2025-05-16 12:00:32 -04:00
parent 20dc00e62f
commit 612ad717c0
42 changed files with 1853 additions and 0 deletions

Binary file not shown.

After

Width:  |  Height:  |  Size: 808 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 34 KiB

28
assets/config.json Normal file
View file

@ -0,0 +1,28 @@
{
"sounds": {
"ui_click": "assets/sounds/ui_click.ogg",
"ui_hover": "assets/sounds/ui_hover.ogg",
"clicker_bark": "assets/sounds/clicker_bark.ogg",
"blank": "assets/sounds/blank.ogg"
},
"sprites": {
"textures_test":
{"path": "assets/textures_test.png",
"frame_width": 53,
"frame_height": 34
},
"clicker_the_dog":
{"path": "assets/clicker_the_dog-1024.png",
"frame_width": 1024,
"frame_height": 1024
},
"clicker_treat_bone":
{"path": "assets/clicker_treat_bone.png",
"frame_width": 256,
"frame_height": 144
}
},
"graphics": {
"smooth_textures": false
}
}

10
assets/shaders.json Normal file
View file

@ -0,0 +1,10 @@
{
"ui_shader": {
"file_name": "assets/shaders/ui_shader.frag",
"type": "fragment"
},
"ERROR": {
"file_name": "assets/shaders/ui_error.frag",
"type": "fragment"
}
}

View file

@ -0,0 +1,18 @@
uniform vec2 u_resolution;
uniform vec2 u_mouse;
uniform float u_duration;
uniform float u_time;
uniform float u_time_end;
uniform sampler2D texture;
uniform bool is_shape;
void main() {
if(is_shape) {
vec4 color = vec4(1.0, 0.0, 0.0, 1.0);
gl_FragColor = gl_Color * color;
} else {
vec4 pixel = texture2D(texture, gl_TexCoord[0].xy);
vec4 color = vec4(1.0, 0.0, 0.0, 1.0);
gl_FragColor = gl_Color * color * pixel;
}
}

View file

@ -0,0 +1,29 @@
uniform vec2 u_resolution;
uniform vec2 u_mouse;
uniform float u_duration;
uniform float u_time;
uniform float u_time_end;
uniform sampler2D texture;
uniform bool is_shape;
uniform bool hover;
vec4 blink() {
if(hover) {
return vec4(0.95, 0.95, 1.0, 1.0);
} else {
float tick = (u_time_end - u_time) / u_duration;
float blink = mix(0.5, 1.0, tick);
return vec4(blink, blink, blink, 1.0);
}
}
void main() {
vec4 color = blink();
if(!is_shape) {
vec4 pixel = texture2D(texture, gl_TexCoord[0].xy);
color *= pixel;
}
gl_FragColor = gl_Color * color;
}

View file

@ -0,0 +1,12 @@
uniform vec2 u_resolution;
uniform vec2 u_mouse;
uniform float u_duration;
uniform float u_time;
uniform float u_time_end;
void main() {
float tick = (u_time_end - u_time) / u_duration;
float blink = smoothstep(1.0, 0.5, tick);
vec4 color = vec4(blink, blink, blink, 1.0);
gl_FragColor = gl_Color * color;
}

BIN
assets/sounds/blank.ogg Normal file

Binary file not shown.

Binary file not shown.

BIN
assets/sounds/ui_click.ogg Normal file

Binary file not shown.

BIN
assets/sounds/ui_hover.ogg Normal file

Binary file not shown.

BIN
assets/text.otf Normal file

Binary file not shown.

BIN
assets/textures_test.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 579 B