diff --git a/app/content/entities/camera/settings.tscn b/app/content/entities/camera/settings.tscn index c4cbac9..3b147bd 100644 --- a/app/content/entities/camera/settings.tscn +++ b/app/content/entities/camera/settings.tscn @@ -7,7 +7,7 @@ [ext_resource type="PackedScene" uid="uid://pk5k1q8bx0rj" path="res://content/ui/components/slider/slider.tscn" id="4_t8xp5"] [ext_resource type="PackedScene" uid="uid://bsjqdvkt0u87c" path="res://content/ui/components/button/button.tscn" id="5_opf0y"] -[sub_resource type="ShaderMaterial" id="ShaderMaterial_p3rs7"] +[sub_resource type="ShaderMaterial" id="ShaderMaterial_ikxbe"] resource_local_to_scene = true render_priority = 10 shader = ExtResource("2_wwobq") @@ -22,7 +22,7 @@ shader_parameter/corner_radius = 0.2 shader_parameter/roughness = 0.3 shader_parameter/grain_amount = 0.02 -[sub_resource type="QuadMesh" id="QuadMesh_nlygn"] +[sub_resource type="QuadMesh" id="QuadMesh_qfg01"] size = Vector2(0.3, 0.2) [sub_resource type="BoxShape3D" id="BoxShape3D_ctomk"] @@ -34,8 +34,8 @@ collision_mask = 0 script = ExtResource("1_1ixy6") [node name="Panel" parent="." instance=ExtResource("1_myvk1")] -material_override = SubResource("ShaderMaterial_p3rs7") -mesh = SubResource("QuadMesh_nlygn") +material_override = SubResource("ShaderMaterial_ikxbe") +mesh = SubResource("QuadMesh_qfg01") skeleton = NodePath("../..") size = Vector2(0.3, 0.2) diff --git a/app/content/entities/light/settings.tscn b/app/content/entities/light/settings.tscn index 3b6892f..d6aa753 100644 --- a/app/content/entities/light/settings.tscn +++ b/app/content/entities/light/settings.tscn @@ -6,7 +6,7 @@ [ext_resource type="PackedScene" uid="uid://bsjqdvkt0u87c" path="res://content/ui/components/button/button.tscn" id="3_2gpr3"] [ext_resource type="PackedScene" uid="uid://blrhy2uccrdn4" path="res://content/ui/components/input/input.tscn" id="4_upyp3"] -[sub_resource type="ShaderMaterial" id="ShaderMaterial_e3jsi"] +[sub_resource type="ShaderMaterial" id="ShaderMaterial_00j7x"] resource_local_to_scene = true render_priority = 10 shader = ExtResource("2_m4moa") @@ -21,7 +21,7 @@ shader_parameter/corner_radius = 0.2 shader_parameter/roughness = 0.3 shader_parameter/grain_amount = 0.02 -[sub_resource type="QuadMesh" id="QuadMesh_bmhxb"] +[sub_resource type="QuadMesh" id="QuadMesh_3236q"] size = Vector2(0.3, 0.25) [sub_resource type="BoxShape3D" id="BoxShape3D_bu024"] @@ -34,8 +34,8 @@ script = ExtResource("1_gw2gi") [node name="Panel" parent="." instance=ExtResource("1_78ups")] transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, -7.45058e-09, 0) -material_override = SubResource("ShaderMaterial_e3jsi") -mesh = SubResource("QuadMesh_bmhxb") +material_override = SubResource("ShaderMaterial_00j7x") +mesh = SubResource("QuadMesh_3236q") skeleton = NodePath("../..") size = Vector2(0.3, 0.25) diff --git a/app/content/entities/line_chart/settings.tscn b/app/content/entities/line_chart/settings.tscn index e00a5a0..d0c3579 100644 --- a/app/content/entities/line_chart/settings.tscn +++ b/app/content/entities/line_chart/settings.tscn @@ -7,7 +7,7 @@ [ext_resource type="PackedScene" uid="uid://blrhy2uccrdn4" path="res://content/ui/components/input/input.tscn" id="5_ecnnd"] [ext_resource type="PackedScene" uid="uid://wgnowarejk5y" path="res://content/ui/components/select/select.tscn" id="6_egqee"] -[sub_resource type="ShaderMaterial" id="ShaderMaterial_s8u61"] +[sub_resource type="ShaderMaterial" id="ShaderMaterial_pqb3y"] resource_local_to_scene = true render_priority = 10 shader = ExtResource("3_vjmg5") @@ -22,7 +22,7 @@ shader_parameter/corner_radius = 0.2 shader_parameter/roughness = 0.3 shader_parameter/grain_amount = 0.02 -[sub_resource type="QuadMesh" id="QuadMesh_4hbc0"] +[sub_resource type="QuadMesh" id="QuadMesh_b6qk4"] size = Vector2(0.3, 0.2) [sub_resource type="BoxShape3D" id="BoxShape3D_53oq0"] @@ -34,8 +34,8 @@ collision_mask = 0 script = ExtResource("1_xxfkt") [node name="Panel" parent="." instance=ExtResource("2_4g761")] -material_override = SubResource("ShaderMaterial_s8u61") -mesh = SubResource("QuadMesh_4hbc0") +material_override = SubResource("ShaderMaterial_pqb3y") +mesh = SubResource("QuadMesh_b6qk4") skeleton = NodePath("../..") size = Vector2(0.3, 0.2) diff --git a/app/content/entities/media_player/settings.tscn b/app/content/entities/media_player/settings.tscn index a75520c..cca973d 100644 --- a/app/content/entities/media_player/settings.tscn +++ b/app/content/entities/media_player/settings.tscn @@ -6,7 +6,7 @@ [ext_resource type="PackedScene" uid="uid://bsjqdvkt0u87c" path="res://content/ui/components/button/button.tscn" id="4_u2igx"] [ext_resource type="PackedScene" uid="uid://blrhy2uccrdn4" path="res://content/ui/components/input/input.tscn" id="5_1jm5m"] -[sub_resource type="ShaderMaterial" id="ShaderMaterial_j16so"] +[sub_resource type="ShaderMaterial" id="ShaderMaterial_ncmoa"] resource_local_to_scene = true render_priority = 10 shader = ExtResource("3_abcrk") @@ -21,7 +21,7 @@ shader_parameter/corner_radius = 0.2 shader_parameter/roughness = 0.3 shader_parameter/grain_amount = 0.02 -[sub_resource type="QuadMesh" id="QuadMesh_48hjm"] +[sub_resource type="QuadMesh" id="QuadMesh_qm2qb"] size = Vector2(0.3, 0.2) [sub_resource type="BoxShape3D" id="BoxShape3D_53oq0"] @@ -31,8 +31,8 @@ size = Vector3(0.3, 0.2, 0.02) script = ExtResource("1_03bil") [node name="Panel" parent="." instance=ExtResource("2_kt6qc")] -material_override = SubResource("ShaderMaterial_j16so") -mesh = SubResource("QuadMesh_48hjm") +material_override = SubResource("ShaderMaterial_ncmoa") +mesh = SubResource("QuadMesh_qm2qb") skeleton = NodePath("../..") size = Vector2(0.3, 0.2) diff --git a/app/content/system/controller_left/controller_left.gd b/app/content/system/controller_left/controller_left.gd index 5e97648..f6b336e 100644 --- a/app/content/system/controller_left/controller_left.gd +++ b/app/content/system/controller_left/controller_left.gd @@ -125,9 +125,9 @@ func _setup_hand(): auto_hand.hand_active_changed.connect(func(hand: int, active: bool): if hand != 0: return - hand_active=active + hand_active=active&&_is_hand_simulated() == false - $IndexTip/TouchArea/CollisionShape3D.disabled=!active + $IndexTip/TouchArea/CollisionShape3D.disabled=!hand_active hand_mesh.visible=active ) @@ -155,6 +155,17 @@ func _setup_hand(): pointer = Pointer.new(initiator, ray) add_child(pointer) +func _is_hand_simulated(): + var hand_trackers = XRServer.get_trackers(XRServer.TRACKER_HAND) + + for tracker in hand_trackers.values(): + if tracker.hand != XRPositionalTracker.TrackerHand.TRACKER_HAND_LEFT: + continue + + return tracker.hand_tracking_source == XRHandTracker.HAND_TRACKING_SOURCE_CONTROLLER + + return false + func _get_entity(node: Node): if node is Entity: return node diff --git a/app/content/system/controller_right/controller_right.gd b/app/content/system/controller_right/controller_right.gd index 5a839f7..848ab18 100644 --- a/app/content/system/controller_right/controller_right.gd +++ b/app/content/system/controller_right/controller_right.gd @@ -56,9 +56,9 @@ func _setup_hand(): auto_hand.hand_active_changed.connect(func(hand: int, active: bool): if hand != 1: return - hand_active=active + hand_active=active&&_is_hand_simulated() == false - $IndexTip/TouchArea/CollisionShape3D.disabled=!active + $IndexTip/TouchArea/CollisionShape3D.disabled=!hand_active hand_mesh.visible=active ) @@ -83,4 +83,15 @@ func _physics_process(_delta): grabbed = true elif !grab_close&&grabbed: pointer.released(Initiator.EventType.GRIP) - grabbed = false \ No newline at end of file + grabbed = false + +func _is_hand_simulated(): + var hand_trackers = XRServer.get_trackers(XRServer.TRACKER_HAND) + + for tracker in hand_trackers.values(): + if tracker.hand != XRPositionalTracker.TrackerHand.TRACKER_HAND_RIGHT: + continue + + return tracker.hand_tracking_source == XRHandTracker.HAND_TRACKING_SOURCE_CONTROLLER + + return false \ No newline at end of file diff --git a/app/content/system/controller_right/controller_right.tscn b/app/content/system/controller_right/controller_right.tscn index 7704fe2..1bd3bb4 100644 --- a/app/content/system/controller_right/controller_right.tscn +++ b/app/content/system/controller_right/controller_right.tscn @@ -29,6 +29,9 @@ mesh = SubResource("BoxMesh_ir3co") [node name="AutoHandtracker" parent="." instance=ExtResource("3_pjmb2")] visible = false +applymiddlefingerfix = null +applyscaling = null +coincidewristorknuckle = null visiblehandtrackskeleton = false enableautotracker = false diff --git a/app/content/system/miniature/mini_wall_shader.gdshader b/app/content/system/miniature/mini_wall_shader.gdshader index 9a3c220..807ff24 100644 --- a/app/content/system/miniature/mini_wall_shader.gdshader +++ b/app/content/system/miniature/mini_wall_shader.gdshader @@ -63,22 +63,22 @@ void fragment() { ROUGHNESS = roughness; DEPTH = FRAGCOORD.z + 0.0001; ALBEDO = vec3(color.xyz); - + vec2 pos = vec2(UV.x * aspect_ratio.x, UV.y * aspect_ratio.y); float border = 0.05; - + if (pos.x <= border) { ALBEDO = mix(vec3(0.0), ALBEDO, pos.x / border); } - + if (pos.x >= aspect_ratio.x - border) { ALBEDO = mix(vec3(0.0), ALBEDO, 1.0 - (pos.x - (aspect_ratio.x - border)) / border); } - + if (pos.y <= border) { ALBEDO = mix(vec3(0.0), ALBEDO, pos.y / border); } - + if (pos.y >= aspect_ratio.y - border) { ALBEDO = mix(vec3(0.0), ALBEDO, 1.0 - (pos.y - (aspect_ratio.y - border)) / border); }