Initial orbiting craft

This commit is contained in:
2024-11-06 22:16:43 +08:00
parent a6e116c77f
commit 518ee9d429
6 changed files with 194 additions and 2 deletions

View File

@@ -1,7 +1,8 @@
[gd_scene load_steps=12 format=3 uid="uid://tht1tf5iq6lw"]
[gd_scene load_steps=15 format=3 uid="uid://tht1tf5iq6lw"]
[ext_resource type="Script" path="res://src/Craft/Krakensbane.cs" id="1_ju4qj"]
[ext_resource type="Script" path="res://src/Testing/TestThruster.cs" id="2_1t1tx"]
[ext_resource type="Script" path="res://src/Testing/DebugUI.cs" id="3_gx3yn"]
[sub_resource type="PhysicalSkyMaterial" id="PhysicalSkyMaterial_uxbcq"]
@@ -16,6 +17,8 @@ sky = SubResource("Sky_iakm3")
[sub_resource type="Compositor" id="Compositor_tt8nt"]
[sub_resource type="PhysicsMaterial" id="PhysicsMaterial_sjyiu"]
[sub_resource type="BoxShape3D" id="BoxShape3D_8al46"]
[sub_resource type="BoxMesh" id="BoxMesh_jgj3c"]
@@ -26,6 +29,8 @@ size = Vector3(16.9697, 0.0310059, 15.6934)
[sub_resource type="PlaneMesh" id="PlaneMesh_xcndr"]
size = Vector2(20, 20)
[sub_resource type="LabelSettings" id="LabelSettings_v1h1b"]
[node name="root" type="Node3D"]
[node name="DirectionalLight3D" type="DirectionalLight3D" parent="."]
@@ -42,6 +47,7 @@ FocusedVessel = NodePath("test-rocket")
[node name="test-rocket" type="RigidBody3D" parent="FloatingOriginRoot"]
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0.815224, 0)
physics_material_override = SubResource("PhysicsMaterial_sjyiu")
script = ExtResource("2_1t1tx")
[node name="CollisionShape3D" type="CollisionShape3D" parent="FloatingOriginRoot/test-rocket"]
@@ -63,3 +69,52 @@ shape = SubResource("BoxShape3D_xxi7g")
[node name="MeshInstance3D" type="MeshInstance3D" parent="FloatingOriginRoot/ground"]
mesh = SubResource("PlaneMesh_xcndr")
[node name="DebugUI" type="Panel" parent="." node_paths=PackedStringArray("minimapContainer", "planetOutline", "vesselIndicator", "krakensbane", "displayLabel")]
offset_left = 1508.0
offset_top = 62.0
offset_right = 1868.0
offset_bottom = 542.0
script = ExtResource("3_gx3yn")
minimapContainer = NodePath("VBoxContainer/MinimapContainer")
planetOutline = NodePath("VBoxContainer/MinimapContainer/Polygon2D")
vesselIndicator = NodePath("VBoxContainer/MinimapContainer/ColorRect")
krakensbane = NodePath("../FloatingOriginRoot")
displayLabel = NodePath("VBoxContainer/Label")
[node name="VBoxContainer" type="VBoxContainer" parent="DebugUI"]
layout_mode = 1
anchors_preset = 15
anchor_right = 1.0
anchor_bottom = 1.0
grow_horizontal = 2
grow_vertical = 2
[node name="MinimapContainer" type="Control" parent="DebugUI/VBoxContainer"]
custom_minimum_size = Vector2(0, 360)
layout_mode = 2
[node name="Polygon2D" type="Polygon2D" parent="DebugUI/VBoxContainer/MinimapContainer"]
color = Color(0.287295, 0.287295, 0.287295, 1)
polygon = PackedVector2Array(116, 83, 96, 201, 274, 248, 289, 140, 119, 85)
[node name="y-axis" type="Line2D" parent="DebugUI/VBoxContainer/MinimapContainer"]
points = PackedVector2Array(180, 180, 180, 0)
width = 2.0
default_color = Color(0.286275, 0.290196, 1, 1)
[node name="x-axis" type="Line2D" parent="DebugUI/VBoxContainer/MinimapContainer"]
points = PackedVector2Array(180, 180, 360, 180)
width = 2.0
default_color = Color(0.671919, 0.312344, 0.0459558, 1)
[node name="ColorRect" type="ColorRect" parent="DebugUI/VBoxContainer/MinimapContainer"]
layout_mode = 0
offset_right = 10.0
offset_bottom = 10.0
pivot_offset = Vector2(5, 5)
[node name="Label" type="Label" parent="DebugUI/VBoxContainer"]
layout_mode = 2
text = "Position"
label_settings = SubResource("LabelSettings_v1h1b")