car_base.tscn 6.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188
  1. [gd_scene load_steps=19 format=3 uid="uid://c1uai3rvx8hul"]
  2. [ext_resource type="Script" path="res://vehicles/vehicle.gd" id="1_r806m"]
  3. [ext_resource type="Texture2D" uid="uid://d4ostmqwgytk" path="res://vehicles/particle_smoke.png" id="2_1gkvk"]
  4. [ext_resource type="ArrayMesh" uid="uid://bqrwin8ccgptt" path="res://vehicles/meshes/wheel.res" id="2_3cqaw"]
  5. [ext_resource type="ArrayMesh" uid="uid://b2xi556mwp7ue" path="res://vehicles/meshes/minivan.res" id="3_cqia8"]
  6. [ext_resource type="Script" path="res://vehicles/follow_camera.gd" id="4_6igu8"]
  7. [ext_resource type="AudioStream" uid="uid://cb7wvsd6vygd3" path="res://vehicles/engine.wav" id="5_m8g7o"]
  8. [ext_resource type="AudioStream" uid="uid://sy2li7u35867" path="res://vehicles/impact_1.wav" id="6_kq567"]
  9. [ext_resource type="AudioStream" uid="uid://bf0h7s81yr8nj" path="res://vehicles/impact_2.wav" id="7_e8n8v"]
  10. [ext_resource type="AudioStream" uid="uid://sun2n8a4xapl" path="res://vehicles/impact_3.wav" id="8_mh5uv"]
  11. [ext_resource type="AudioStream" uid="uid://dpbayeeufya21" path="res://vehicles/impact_4.wav" id="9_bomp1"]
  12. [ext_resource type="Texture2D" uid="uid://bju75l2w3r7vq" path="res://vehicles/blob_shadow.png" id="11_3ryw5"]
  13. [sub_resource type="PhysicsMaterial" id="PhysicsMaterial_l7i2k"]
  14. friction = 0.5
  15. [sub_resource type="BoxShape3D" id="BoxShape3D_x74tc"]
  16. size = Vector3(0.954078, 1, 2.32662)
  17. [sub_resource type="AudioStreamRandomizer" id="AudioStreamRandomizer_bpr2q"]
  18. random_pitch = 1.05
  19. random_volume_offset_db = 2.0
  20. streams_count = 4
  21. stream_0/stream = ExtResource("6_kq567")
  22. stream_1/stream = ExtResource("7_e8n8v")
  23. stream_2/stream = ExtResource("8_mh5uv")
  24. stream_3/stream = ExtResource("9_bomp1")
  25. [sub_resource type="StandardMaterial3D" id="StandardMaterial3D_fuuj3"]
  26. transparency = 1
  27. shading_mode = 0
  28. vertex_color_use_as_albedo = true
  29. albedo_color = Color(0.462745, 0.462745, 0.462745, 0.501961)
  30. albedo_texture = ExtResource("2_1gkvk")
  31. billboard_mode = 3
  32. billboard_keep_scale = true
  33. particles_anim_h_frames = 1
  34. particles_anim_v_frames = 1
  35. particles_anim_loop = false
  36. proximity_fade_enabled = true
  37. proximity_fade_distance = 0.5
  38. [sub_resource type="QuadMesh" id="QuadMesh_30wks"]
  39. material = SubResource("StandardMaterial3D_fuuj3")
  40. [sub_resource type="Curve" id="Curve_4j5vd"]
  41. _data = [Vector2(0, 0), 0.0, 0.0, 0, 0, Vector2(1, 1), 0.0, 0.0, 0, 0]
  42. point_count = 2
  43. [sub_resource type="Gradient" id="Gradient_p5xtl"]
  44. colors = PackedColorArray(1, 1, 1, 1, 1, 1, 1, 0)
  45. [node name="CarBase" type="Node3D"]
  46. [node name="Body" type="VehicleBody3D" parent="."]
  47. transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, -0.00169557, 0.222867, -0.0955184)
  48. physics_material_override = SubResource("PhysicsMaterial_l7i2k")
  49. center_of_mass_mode = 1
  50. script = ExtResource("1_r806m")
  51. [node name="Wheel1" type="VehicleWheel3D" parent="Body"]
  52. transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0.573678, 0.115169, 1.10416)
  53. use_as_traction = true
  54. use_as_steering = true
  55. wheel_roll_influence = 0.4
  56. wheel_radius = 0.25
  57. wheel_friction_slip = 1.0
  58. suspension_travel = 2.0
  59. suspension_stiffness = 40.0
  60. damping_compression = 0.88
  61. [node name="Wheel1" type="MeshInstance3D" parent="Body/Wheel1"]
  62. layers = 2
  63. gi_mode = 2
  64. mesh = ExtResource("2_3cqaw")
  65. [node name="Wheel2" type="VehicleWheel3D" parent="Body"]
  66. transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0.573678, 0.115169, -0.783403)
  67. use_as_traction = true
  68. wheel_roll_influence = 0.4
  69. wheel_radius = 0.25
  70. wheel_friction_slip = 1.0
  71. suspension_travel = 2.0
  72. suspension_stiffness = 40.0
  73. damping_compression = 0.88
  74. [node name="Wheel2" type="MeshInstance3D" parent="Body/Wheel2"]
  75. layers = 2
  76. gi_mode = 2
  77. mesh = ExtResource("2_3cqaw")
  78. [node name="Wheel3" type="VehicleWheel3D" parent="Body"]
  79. transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, -0.573678, 0.115169, 1.10416)
  80. use_as_traction = true
  81. use_as_steering = true
  82. wheel_roll_influence = 0.4
  83. wheel_radius = 0.25
  84. wheel_friction_slip = 1.0
  85. suspension_travel = 2.0
  86. suspension_stiffness = 40.0
  87. damping_compression = 0.88
  88. [node name="Wheel3" type="MeshInstance3D" parent="Body/Wheel3"]
  89. layers = 2
  90. gi_mode = 2
  91. mesh = ExtResource("2_3cqaw")
  92. [node name="Wheel4" type="VehicleWheel3D" parent="Body"]
  93. transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, -0.573678, 0.115169, -0.783403)
  94. use_as_traction = true
  95. wheel_roll_influence = 0.4
  96. wheel_radius = 0.25
  97. wheel_friction_slip = 1.0
  98. suspension_travel = 2.0
  99. suspension_stiffness = 40.0
  100. damping_compression = 0.88
  101. [node name="Wheel4" type="MeshInstance3D" parent="Body/Wheel4"]
  102. layers = 2
  103. gi_mode = 2
  104. mesh = ExtResource("2_3cqaw")
  105. [node name="Body" type="MeshInstance3D" parent="Body"]
  106. layers = 2
  107. gi_mode = 2
  108. mesh = ExtResource("3_cqia8")
  109. [node name="CollisionShape3D" type="CollisionShape3D" parent="Body"]
  110. transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0.588269, 0.0774262)
  111. shape = SubResource("BoxShape3D_x74tc")
  112. [node name="CameraBase" type="Node3D" parent="Body"]
  113. transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 1.97449, 0)
  114. [node name="Camera3D" type="Camera3D" parent="Body/CameraBase"]
  115. transform = Transform3D(-1, 2.11495e-08, -8.48259e-08, 0, 0.970296, 0.241922, 8.74228e-08, 0.241922, -0.970296, 0, 2.032, -4.394)
  116. fov = 74.0
  117. near = 0.1
  118. script = ExtResource("4_6igu8")
  119. min_distance = 4.0
  120. max_distance = 5.0
  121. height = 1.25
  122. [node name="EngineSound" type="AudioStreamPlayer3D" parent="Body"]
  123. stream = ExtResource("5_m8g7o")
  124. pitch_scale = 0.05
  125. autoplay = true
  126. attenuation_filter_cutoff_hz = 20500.0
  127. [node name="ImpactSound" type="AudioStreamPlayer3D" parent="Body"]
  128. stream = SubResource("AudioStreamRandomizer_bpr2q")
  129. volume_db = -10.0
  130. max_polyphony = 3
  131. attenuation_filter_cutoff_hz = 20500.0
  132. [node name="CPUParticles3D" type="CPUParticles3D" parent="Body"]
  133. transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0.201696, -0.022867, -1.10448)
  134. amount = 125
  135. lifetime = 1.25
  136. mesh = SubResource("QuadMesh_30wks")
  137. direction = Vector3(0, 1, -0.5)
  138. gravity = Vector3(0, 0, 0)
  139. initial_velocity_min = 1.0
  140. initial_velocity_max = 1.0
  141. damping_min = 0.05
  142. damping_max = 0.05
  143. angle_max = 360.0
  144. scale_amount_curve = SubResource("Curve_4j5vd")
  145. color_ramp = SubResource("Gradient_p5xtl")
  146. [node name="BlobShadow" type="Decal" parent="Body"]
  147. transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0.05)
  148. size = Vector3(1.6, 4, 3)
  149. texture_albedo = ExtResource("11_3ryw5")
  150. upper_fade = 2.0
  151. lower_fade = 1.0
  152. cull_mask = 1048573
  153. [node name="AudioListener3D" type="AudioListener3D" parent="Body"]
  154. current = true
  155. [node name="InteriorCameraPosition" type="Marker3D" parent="Body"]
  156. transform = Transform3D(-1, 0, -8.74228e-08, 0, 1, 0, 8.74228e-08, 0, -1, 0, 0.9, 0.3)
  157. [node name="TopDownCameraPosition" type="Marker3D" parent="Body"]
  158. transform = Transform3D(-1, 8.74228e-08, 0, 3.82137e-15, 4.37114e-08, 1, 8.74228e-08, 1, -4.37114e-08, 0.00169557, 15.7771, 0.0955178)