Fix Snap_zones not range grabbing
This commit is contained in:
@@ -1,12 +1,13 @@
|
||||
[gd_scene format=3 uid="uid://efaec6ymgabo"]
|
||||
|
||||
[ext_resource type="Script" uid="uid://cquqe4f1m1sw6" path="res://addons/godot-xr-tools/objects/snap_zone.gd" id="1_dlkho"]
|
||||
[ext_resource type="AudioStream" uid="uid://claw3d2wnyr6a" path="res://Sounds/220212__gameaudio__ping-bing.wav" id="2_0aadn"]
|
||||
|
||||
[sub_resource type="BoxShape3D" id="BoxShape3D_24d3s"]
|
||||
size = Vector3(1, 1, 1.0517578)
|
||||
|
||||
[sub_resource type="SphereShape3D" id="SphereShape3D_dlkho"]
|
||||
radius = 0.3
|
||||
[sub_resource type="BoxShape3D" id="BoxShape3D_1ntq7"]
|
||||
size = Vector3(0.6, 0.12802735, 0.6)
|
||||
|
||||
[sub_resource type="StandardMaterial3D" id="StandardMaterial3D_24d3s"]
|
||||
albedo_color = Color(0.49, 0.3854667, 0.29400003, 1)
|
||||
@@ -23,14 +24,15 @@ shape = SubResource("BoxShape3D_24d3s")
|
||||
[node name="XRToolsSnapZone" type="Area3D" parent="." unique_id=1647380272 groups=["station"]]
|
||||
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0.5608841, 0)
|
||||
collision_layer = 65536
|
||||
collision_mask = 65536
|
||||
collision_mask = 65540
|
||||
script = ExtResource("1_dlkho")
|
||||
stash_sound = ExtResource("2_0aadn")
|
||||
snap_mode = 1
|
||||
metadata/_custom_type_script = "uid://cquqe4f1m1sw6"
|
||||
|
||||
[node name="CollisionShape3D2" type="CollisionShape3D" parent="XRToolsSnapZone" unique_id=969340130]
|
||||
transform = Transform3D(0.5, 0, 0, 0, 0.5, 0, 0, 0, 0.5, 0, -0.000975132, 0)
|
||||
shape = SubResource("SphereShape3D_dlkho")
|
||||
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, -0.002, 0)
|
||||
shape = SubResource("BoxShape3D_1ntq7")
|
||||
|
||||
[node name="CSGCombiner3D" type="CSGCombiner3D" parent="." unique_id=451757283]
|
||||
use_collision = true
|
||||
|
||||
+5
-7
@@ -3,12 +3,11 @@
|
||||
[ext_resource type="Script" uid="uid://bsn8vhv5adxdo" path="res://Stations/hob.gd" id="1_7jc4g"]
|
||||
[ext_resource type="Script" uid="uid://cquqe4f1m1sw6" path="res://addons/godot-xr-tools/objects/snap_zone.gd" id="2_er1dp"]
|
||||
[ext_resource type="PackedScene" uid="uid://bxbocxdaayvwx" path="res://UI/progress_bar.tscn" id="3_7uuqv"]
|
||||
[ext_resource type="Script" uid="uid://bv7oracwmgre8" path="res://UI/progress_bar_3d.gd" id="3_zz9kp"]
|
||||
|
||||
[sub_resource type="BoxShape3D" id="BoxShape3D_kdxnr"]
|
||||
|
||||
[sub_resource type="SphereShape3D" id="SphereShape3D_vlqg6"]
|
||||
radius = 0.3
|
||||
[sub_resource type="BoxShape3D" id="BoxShape3D_7uuqv"]
|
||||
size = Vector3(0.6, 0.12802735, 0.6)
|
||||
|
||||
[sub_resource type="SceneReplicationConfig" id="SceneReplicationConfig_np_hob"]
|
||||
properties/0/path = NodePath(".:time_cooked")
|
||||
@@ -27,14 +26,14 @@ shape = SubResource("BoxShape3D_kdxnr")
|
||||
[node name="XRToolsSnapZone" type="Area3D" parent="." unique_id=538157739]
|
||||
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0.5270121, 0)
|
||||
collision_layer = 65536
|
||||
collision_mask = 65536
|
||||
collision_mask = 65540
|
||||
script = ExtResource("2_er1dp")
|
||||
snap_mode = 1
|
||||
metadata/_custom_type_script = "uid://cquqe4f1m1sw6"
|
||||
|
||||
[node name="CollisionShape3D2" type="CollisionShape3D" parent="XRToolsSnapZone" unique_id=370920392]
|
||||
transform = Transform3D(0.5, 0, 0, 0, 0.5, 0, 0, 0, 0.5, 0, -0.000975132, 0)
|
||||
shape = SubResource("SphereShape3D_vlqg6")
|
||||
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, -0.000975132, 0)
|
||||
shape = SubResource("BoxShape3D_7uuqv")
|
||||
|
||||
[node name="CSGCombiner3D" type="CSGCombiner3D" parent="." unique_id=70901698]
|
||||
|
||||
@@ -119,4 +118,3 @@ replication_config = SubResource("SceneReplicationConfig_np_hob")
|
||||
|
||||
[node name="ProgressBar3D" parent="." unique_id=654673176 instance=ExtResource("3_7uuqv")]
|
||||
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0.74736404, -0.09216304)
|
||||
script = ExtResource("3_zz9kp")
|
||||
|
||||
@@ -33,7 +33,7 @@ text = "Dirt"
|
||||
[node name="XRToolsSnapZone" type="Area3D" parent="." unique_id=333161027 groups=["station"]]
|
||||
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0.5270121, 0)
|
||||
collision_layer = 65536
|
||||
collision_mask = 65536
|
||||
collision_mask = 65540
|
||||
script = ExtResource("2_v0ytd")
|
||||
snap_mode = 1
|
||||
metadata/_custom_type_script = "uid://cquqe4f1m1sw6"
|
||||
|
||||
+7
-7
@@ -4,10 +4,10 @@
|
||||
[ext_resource type="Script" uid="uid://cquqe4f1m1sw6" path="res://addons/godot-xr-tools/objects/snap_zone.gd" id="2_3ocod"]
|
||||
[ext_resource type="PackedScene" uid="uid://bxbocxdaayvwx" path="res://UI/progress_bar.tscn" id="4_1pinr"]
|
||||
|
||||
[sub_resource type="BoxShape3D" id="BoxShape3D_24d3s"]
|
||||
[sub_resource type="BoxShape3D" id="BoxShape3D_l02yb"]
|
||||
|
||||
[sub_resource type="SphereShape3D" id="SphereShape3D_dlkho"]
|
||||
radius = 0.3
|
||||
[sub_resource type="BoxShape3D" id="BoxShape3D_ai6d4"]
|
||||
size = Vector3(0.6, 0.12802735, 0.6)
|
||||
|
||||
[sub_resource type="SceneReplicationConfig" id="SceneReplicationConfig_np_sink"]
|
||||
properties/0/path = NodePath(".:progress")
|
||||
@@ -18,19 +18,19 @@ properties/0/replication_mode = 1
|
||||
script = ExtResource("1_7hh4b")
|
||||
|
||||
[node name="CollisionShape3D" type="CollisionShape3D" parent="." unique_id=964735164]
|
||||
shape = SubResource("BoxShape3D_24d3s")
|
||||
shape = SubResource("BoxShape3D_l02yb")
|
||||
|
||||
[node name="XRToolsSnapZone" type="Area3D" parent="." unique_id=1762550988 groups=["station"]]
|
||||
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0.5163779, 0)
|
||||
collision_layer = 65536
|
||||
collision_mask = 65536
|
||||
collision_mask = 65540
|
||||
script = ExtResource("2_3ocod")
|
||||
snap_mode = 1
|
||||
metadata/_custom_type_script = "uid://cquqe4f1m1sw6"
|
||||
|
||||
[node name="CollisionShape3D2" type="CollisionShape3D" parent="XRToolsSnapZone" unique_id=860566355]
|
||||
transform = Transform3D(0.5, 0, 0, 0, 0.5, 0, 0, 0, 0.5, 0, -0.000975132, 0)
|
||||
shape = SubResource("SphereShape3D_dlkho")
|
||||
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, -0.000975132, 0)
|
||||
shape = SubResource("BoxShape3D_ai6d4")
|
||||
|
||||
[node name="CSGCombiner3D" type="CSGCombiner3D" parent="." unique_id=311064646]
|
||||
|
||||
|
||||
@@ -172,11 +172,9 @@ func _refresh_display() -> void:
|
||||
progress_bar.set_bar_visible(false)
|
||||
|
||||
label_3d_time.text = "%.1f" % _state_time
|
||||
print("_state_duration = ", _state_duration)
|
||||
progress_bar.set_progress(clampf(float(_state_time) / _state_duration, 0.0, 1.0))
|
||||
|
||||
|
||||
|
||||
func _set_state(value: TableState) -> void:
|
||||
_state = value
|
||||
_refresh_display()
|
||||
|
||||
+5
-5
@@ -7,7 +7,7 @@
|
||||
[sub_resource type="BoxShape3D" id="BoxShape3D_24d3s"]
|
||||
|
||||
[sub_resource type="SphereShape3D" id="SphereShape3D_dlkho"]
|
||||
radius = 0.3
|
||||
radius = 0.6
|
||||
|
||||
[sub_resource type="StandardMaterial3D" id="StandardMaterial3D_24d3s"]
|
||||
albedo_color = Color(0.31, 0.21576, 0.1333, 1)
|
||||
@@ -32,7 +32,7 @@ shape = SubResource("BoxShape3D_24d3s")
|
||||
[node name="XRToolsSnapZone" type="Area3D" parent="." unique_id=1947858647 groups=["station"]]
|
||||
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, -0.31874347, 0.5270121, 0)
|
||||
collision_layer = 65536
|
||||
collision_mask = 65536
|
||||
collision_mask = 65540
|
||||
script = ExtResource("1_8j1nt")
|
||||
snap_mode = 1
|
||||
metadata/_custom_type_script = "uid://cquqe4f1m1sw6"
|
||||
@@ -44,7 +44,7 @@ shape = SubResource("SphereShape3D_dlkho")
|
||||
[node name="XRToolsSnapZone2" type="Area3D" parent="." unique_id=694448387 groups=["station"]]
|
||||
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0.34755045, 0.5270121, 0)
|
||||
collision_layer = 65536
|
||||
collision_mask = 65536
|
||||
collision_mask = 65540
|
||||
script = ExtResource("1_8j1nt")
|
||||
snap_mode = 1
|
||||
metadata/_custom_type_script = "uid://cquqe4f1m1sw6"
|
||||
@@ -56,7 +56,7 @@ shape = SubResource("SphereShape3D_dlkho")
|
||||
[node name="XRToolsSnapZone3" type="Area3D" parent="." unique_id=1734026785 groups=["station"]]
|
||||
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, -0.012355864, 0.5270121, 0.33038777)
|
||||
collision_layer = 65536
|
||||
collision_mask = 65536
|
||||
collision_mask = 65540
|
||||
script = ExtResource("1_8j1nt")
|
||||
snap_mode = 1
|
||||
metadata/_custom_type_script = "uid://cquqe4f1m1sw6"
|
||||
@@ -68,7 +68,7 @@ shape = SubResource("SphereShape3D_dlkho")
|
||||
[node name="XRToolsSnapZone4" type="Area3D" parent="." unique_id=1358457948 groups=["station"]]
|
||||
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0.022546828, 0.5270121, -0.36528283)
|
||||
collision_layer = 65536
|
||||
collision_mask = 65536
|
||||
collision_mask = 65540
|
||||
script = ExtResource("1_8j1nt")
|
||||
snap_mode = 1
|
||||
metadata/_custom_type_script = "uid://cquqe4f1m1sw6"
|
||||
|
||||
Reference in New Issue
Block a user