From 15f7d7c8be89cc8f9deb86764384bd4699b159bb Mon Sep 17 00:00:00 2001 From: Jamie Greunbaum Date: Wed, 19 Jun 2024 16:57:27 -0400 Subject: [PATCH] Altered input wheel colours, and made the custom material for the wheels accept the colours of the `ColorRect` they're applied to. --- UI/ControllerInput/circle_backing.gdshader | 2 +- UI/ControllerInput/circle_backing.material | Bin 240 -> 228 bytes .../controller_input_select_wheel.tscn | 1 + .../controller_input_symbol_wheel.tscn | 1 + 4 files changed, 3 insertions(+), 1 deletion(-) diff --git a/UI/ControllerInput/circle_backing.gdshader b/UI/ControllerInput/circle_backing.gdshader index 76372a1..8814164 100644 --- a/UI/ControllerInput/circle_backing.gdshader +++ b/UI/ControllerInput/circle_backing.gdshader @@ -3,5 +3,5 @@ shader_type canvas_item; void fragment() { float dist = 1.0f - (distance(vec2(0.5f, 0.5f), UV.xy) * 2.0); float value = smoothstep(0.0f, 0.01, dist); - COLOR = vec4(1.0, 1.0, 1.0, value); + COLOR = vec4(COLOR.xyz, value); } diff --git a/UI/ControllerInput/circle_backing.material b/UI/ControllerInput/circle_backing.material index ff59ff18edd8225caed08c573ec62c477117953a..4e8a792d0423e810951207300fbef7449605a98d 100644 GIT binary patch literal 228 zcmVy|@#`BqR;fl7z9fmC^yiUpyhVO#TDwvmn6=l}Qz+dW*%Ulx-BH?thFN z0U_ZG9)9Du-0EBkt8Fzff59*C1N;FW6aZ7pbdM0*0FG7yFpy;lz7%I&Sb@7+U~o_? eMv<8y^PXz}!d$2yb`e_u!2H2;7{CHjQ$s^_&tLHX literal 240 zcmVHbdLbq07_N@{6YjP q2giiE5CG4&z>uNVfg&?O<~`Q{gt<^Z>>{=Rfcb;xFn|S8Q$s@vF=ko- diff --git a/UI/ControllerInput/controller_input_select_wheel.tscn b/UI/ControllerInput/controller_input_select_wheel.tscn index ccaadc9..e30672d 100644 --- a/UI/ControllerInput/controller_input_select_wheel.tscn +++ b/UI/ControllerInput/controller_input_select_wheel.tscn @@ -101,6 +101,7 @@ grow_vertical = 2 [node name="ColorRect" type="ColorRect" parent="AspectRatioContainer"] material = ExtResource("5_bebuy") layout_mode = 2 +color = Color(0.233925, 0.233925, 0.233925, 1) [node name="CaretHorizontalMoveTimer" type="Timer" parent="."] one_shot = true diff --git a/UI/ControllerInput/controller_input_symbol_wheel.tscn b/UI/ControllerInput/controller_input_symbol_wheel.tscn index 40302fb..0b6fb4e 100644 --- a/UI/ControllerInput/controller_input_symbol_wheel.tscn +++ b/UI/ControllerInput/controller_input_symbol_wheel.tscn @@ -52,3 +52,4 @@ grow_horizontal = 2 grow_vertical = 2 scale = Vector2(0.85, 0.85) pivot_offset = Vector2(175, 175) +color = Color(0.303233, 0.303233, 0.303233, 1)