aboutsummaryrefslogtreecommitdiff
path: root/client/player/interact_marker.gdshader
diff options
context:
space:
mode:
authormetamuffin <metamuffin@disroot.org>2024-07-18 12:39:48 +0200
committermetamuffin <metamuffin@disroot.org>2024-07-18 12:39:48 +0200
commitefc29c03f7be043ae8d037a93efce8cfa7c384cc (patch)
tree243d0b1895d9b98c1273cd4df1821b54222b690f /client/player/interact_marker.gdshader
parent2a31d26fca33789ccf8ea28cdb214d20dd29f85d (diff)
parent0b67eafb3b4942ed511c802fa6289634c414af30 (diff)
downloadhurrycurry-efc29c03f7be043ae8d037a93efce8cfa7c384cc.tar
hurrycurry-efc29c03f7be043ae8d037a93efce8cfa7c384cc.tar.bz2
hurrycurry-efc29c03f7be043ae8d037a93efce8cfa7c384cc.tar.zst
Merge branch 'master' of https://codeberg.org/hurrycurry/hurrycurry
Diffstat (limited to 'client/player/interact_marker.gdshader')
-rw-r--r--client/player/interact_marker.gdshader7
1 files changed, 5 insertions, 2 deletions
diff --git a/client/player/interact_marker.gdshader b/client/player/interact_marker.gdshader
index eee76270..3720290f 100644
--- a/client/player/interact_marker.gdshader
+++ b/client/player/interact_marker.gdshader
@@ -21,9 +21,12 @@ uniform float max_width = .1;
uniform float marker_length = .5;
uniform float pulse_speed = 4.;
uniform bool interactive = false;
+uniform bool interacting = false;
void fragment() {
- if (interactive) {
+ if (interacting) {
+ ALBEDO = vec3(0., 0., 15.);
+ } else if (interactive) {
ALBEDO = vec3(15., 0., 0.);
} else {
ALBEDO = vec3(.1, .1, .1);
@@ -31,7 +34,7 @@ void fragment() {
vec2 uv = abs(2. * UV.xy - 1.);
float m_length = marker_length / max_width;
float anim;
- if (interactive) {
+ if (interactive || interacting) {
anim = sin(TIME * pulse_speed) * .5 + 1.;
} else {
anim = .5;