[gd_scene load_steps=10 format=3 uid="uid://ckau5s2tsb3oc"]

[ext_resource type="Script" path="res://src/game/player_controller.gd" id="1_g4ij8"]
[ext_resource type="Texture2D" uid="uid://dw4nlgwgbcs0y" path="res://assets/v_light3.png" id="2_b3d7c"]
[ext_resource type="Texture2D" uid="uid://bnyyk81dhy3h2" path="res://assets/vehicle.png" id="3_4a53i"]
[ext_resource type="Texture2D" uid="uid://ceqcsof04vhqs" path="res://assets/light.png" id="3_qosw5"]
[ext_resource type="AudioStream" uid="uid://cc4ffx6b0xjvk" path="res://assets/sounds/sfx/engine_loop.wav" id="4_4ajo8"]
[ext_resource type="AudioStream" uid="uid://c7laud048l1is" path="res://assets/sounds/sfx/damage.wav" id="5_rvolc"]
[ext_resource type="AudioStream" uid="uid://c6dy6nea6vaa4" path="res://assets/sounds/sfx/death_sound.wav" id="6_i0vg5"]
[ext_resource type="PackedScene" uid="uid://c15m0i1a07em4" path="res://src/game/trail_2d.tscn" id="8_shyhm"]

[sub_resource type="RectangleShape2D" id="RectangleShape2D_w2nj7"]
size = Vector2(36, 20)

[node name="player" type="StaticBody2D" node_paths=PackedStringArray("camera")]
script = ExtResource("1_g4ij8")
acc = 400.0
dec = 200.0
max_speed = 1800.0
turn_speed = 1.2
brake_strength = 1000.0
drift_factor = 1.2
camera_offset = 200.0
camera = NodePath("Camera2D")

[node name="player_bottom_light" type="PointLight2D" parent="."]
position = Vector2(0, 3.09944e-05)
rotation = 1.5708
scale = Vector2(0.1, 0.1)
energy = 2.0
blend_mode = 2
range_item_cull_mask = 7
texture = ExtResource("2_b3d7c")

[node name="Playermodel" type="Sprite2D" parent="."]
light_mask = 8
position = Vector2(0, 3.09944e-05)
rotation = 1.5708
scale = Vector2(0.1, 0.1)
texture = ExtResource("3_4a53i")

[node name="player_light" type="PointLight2D" parent="."]
rotation = -3.14159
range_item_cull_mask = 8
texture = ExtResource("3_qosw5")
texture_scale = 3.5

[node name="vignette_light" type="PointLight2D" parent="."]
rotation = 1.5708
energy = 2.0
range_item_cull_mask = 7
texture = ExtResource("3_qosw5")
texture_scale = 3.5

[node name="CollisionShape2D" type="CollisionShape2D" parent="."]
position = Vector2(-1, 0)
shape = SubResource("RectangleShape2D_w2nj7")

[node name="CanvasModulate" type="CanvasModulate" parent="."]
color = Color(0.0392157, 0.0392157, 0.0392157, 1)

[node name="Camera2D" type="Camera2D" parent="."]
rotation = 1.5708
ignore_rotation = false
rotation_smoothing_enabled = true
rotation_smoothing_speed = 10.0

[node name="engine_sounds" type="AudioStreamPlayer" parent="."]
stream = ExtResource("4_4ajo8")
volume_db = -30.204
autoplay = true
bus = &"Sfx"

[node name="damage_sounds" type="AudioStreamPlayer" parent="."]
stream = ExtResource("5_rvolc")
volume_db = -25.297
bus = &"Sfx"

[node name="death_sound" type="AudioStreamPlayer" parent="."]
stream = ExtResource("6_i0vg5")
volume_db = -25.297
bus = &"Sfx"

[node name="Trail2D" parent="." instance=ExtResource("8_shyhm")]
light_mask = 7
MAX_LENGTH = 40
