small racing game im working on
render thumbnails in own world [skip ci]
| -rw-r--r-- | scenes/track.tscn | 8 | ||||
| -rw-r--r-- | ui/track_button.tscn | 6 | ||||
| -rw-r--r-- | ui/tracks.gd | 2 |
3 files changed, 8 insertions, 8 deletions
diff --git a/scenes/track.tscn b/scenes/track.tscn index fa4442a..4c47171 100644 --- a/scenes/track.tscn +++ b/scenes/track.tscn @@ -1,9 +1,7 @@ -[gd_scene load_steps=9 format=3 uid="uid://ep3a5q3nkb7m"] +[gd_scene load_steps=7 format=3 uid="uid://ep3a5q3nkb7m"] [ext_resource type="Script" path="res://scenes/track-base.gd" id="1_ke7nx"] -[ext_resource type="Curve3D" uid="uid://u2f56xx8h2re" path="res://tracks/multilap_test_curve.tres" id="1_ktkvl"] [ext_resource type="Material" uid="uid://be8pta62kxd2j" path="res://assets/mats/road.tres" id="2_2nntu"] -[ext_resource type="Resource" uid="uid://dwojilpcrv8me" path="res://tracks/multilap_test.tres" id="3_uxk1w"] [ext_resource type="Material" path="res://assets/mats/wall.tres" id="5_8gm6o"] [ext_resource type="PackedScene" uid="uid://cd4a5y0hi58ks" path="res://scenes/floor.tscn" id="7_fidh3"] [ext_resource type="Environment" uid="uid://biwshm46yl62v" path="res://default_env.tres" id="8_2nyv3"] @@ -11,9 +9,7 @@ [node name="TrackLoader" type="Path3D"] transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0.00882721, 0, -0.103973) -curve = ExtResource("1_ktkvl") script = ExtResource("1_ke7nx") -track = ExtResource("3_uxk1w") metadata/_edit_group_ = true [node name="Road" type="CSGPolygon3D" parent="."] @@ -93,6 +89,6 @@ path_u_distance = 1.0 path_joined = true [node name="Ground" parent="." instance=ExtResource("7_fidh3")] -transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, -2, 0) +transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, -0.00882721, -2, 0.103973) [connection signal="curve_changed" from="." to="." method="_on_curve_changed"] diff --git a/ui/track_button.tscn b/ui/track_button.tscn index b33c7ca..4e25103 100644 --- a/ui/track_button.tscn +++ b/ui/track_button.tscn @@ -1,4 +1,4 @@ -[gd_scene load_steps=8 format=3 uid="uid://dfvtugujgcjcw"] +[gd_scene load_steps=9 format=3 uid="uid://dfvtugujgcjcw"] [ext_resource type="Theme" uid="uid://cru1d7n2ftrfm" path="res://ui/theme.tres" id="1_noykn"] [ext_resource type="Script" path="res://ui/trackbutton.gd" id="2_bcpuy"] @@ -8,6 +8,8 @@ [sub_resource type="StyleBoxFlat" id="StyleBoxFlat_fymg3"] bg_color = Color(0.137255, 0.137255, 0.137255, 1) +[sub_resource type="World3D" id="World3D_vgauv"] + [sub_resource type="LabelSettings" id="LabelSettings_sa0e6"] font = ExtResource("2_gctvu") font_size = 25 @@ -29,6 +31,8 @@ button = NodePath("h2/play") [node name="port" type="SubViewport" parent="."] unique_name_in_owner = true +own_world_3d = true +world_3d = SubResource("World3D_vgauv") msaa_3d = 3 screen_space_aa = 1 size = Vector2i(450, 200) diff --git a/ui/tracks.gd b/ui/tracks.gd index 68f0700..0686727 100644 --- a/ui/tracks.gd +++ b/ui/tracks.gd @@ -10,7 +10,7 @@ func _ready() -> void: var button: TrackButton = trackbutton.instantiate() add_child(button) var ghost := GhostData._load(Globals.SAVES % track.name) - await button.init(track, ghost) + button.init(track, ghost) button.play.connect(play.bind(track, ghost)) button.watch.connect(watch.bind(track, ghost)) (get_child(0) as TrackButton).button.grab_focus() |