explosive car; dash no longer stuns or gives extra fire rate

This commit is contained in:
Michael Campbell 2026-03-18 18:18:37 -04:00
parent d0bfe8d1be
commit 5a7c93a573
7 changed files with 309 additions and 7 deletions

View file

@ -0,0 +1,189 @@
[gd_scene format=3 uid="uid://q5cxluytck2h"]
[ext_resource type="PackedScene" uid="uid://oyqyvj5xo5mf" path="res://enemies/base_enemy.tscn" id="1_jdkrm"]
[ext_resource type="Script" uid="uid://btrksi0vamvst" path="res://enemies/explosive_car/explosive_car_behavior.gd" id="2_ofstr"]
[sub_resource type="BoxShape3D" id="BoxShape3D_jdkrm"]
size = Vector3(1.7734375, 0.5839844, 1.1367188)
[sub_resource type="StandardMaterial3D" id="StandardMaterial3D_ofstr"]
resource_local_to_scene = true
albedo_color = Color(1, 0.22000003, 0.22000003, 1)
[sub_resource type="BoxMesh" id="BoxMesh_nf60p"]
size = Vector3(1, 0.25, 0.5)
[sub_resource type="BoxMesh" id="BoxMesh_vj2gi"]
size = Vector3(0.1, 0.05, 0.2)
[sub_resource type="StandardMaterial3D" id="StandardMaterial3D_1o86t"]
albedo_color = Color(1, 0.32, 0.32, 1)
[sub_resource type="StandardMaterial3D" id="StandardMaterial3D_q2pip"]
albedo_color = Color(0.26, 0.45733315, 1, 1)
[sub_resource type="CylinderMesh" id="CylinderMesh_6ocff"]
top_radius = 0.1
bottom_radius = 0.1
height = 0.5
[sub_resource type="BoxShape3D" id="BoxShape3D_ofstr"]
size = Vector3(1, 0.25, 0.5)
[sub_resource type="Animation" id="Animation_jdkrm"]
length = 0.001
tracks/0/type = "value"
tracks/0/imported = false
tracks/0/enabled = true
tracks/0/path = NodePath("Meshes/MeshInstance3D6:material_override:albedo_color")
tracks/0/interp = 1
tracks/0/loop_wrap = true
tracks/0/keys = {
"times": PackedFloat32Array(0),
"transitions": PackedFloat32Array(1),
"update": 0,
"values": [Color(1, 0.22000003, 0.22000003, 1)]
}
tracks/1/type = "value"
tracks/1/imported = false
tracks/1/enabled = true
tracks/1/path = NodePath(".:max_speed")
tracks/1/interp = 1
tracks/1/loop_wrap = true
tracks/1/keys = {
"times": PackedFloat32Array(0),
"transitions": PackedFloat32Array(1),
"update": 0,
"values": [8.0]
}
tracks/2/type = "value"
tracks/2/imported = false
tracks/2/enabled = true
tracks/2/path = NodePath("Meshes:scale")
tracks/2/interp = 1
tracks/2/loop_wrap = true
tracks/2/keys = {
"times": PackedFloat32Array(0),
"transitions": PackedFloat32Array(1),
"update": 0,
"values": [Vector3(1, 1, 1)]
}
[sub_resource type="Animation" id="Animation_ofstr"]
resource_name = "explode"
step = 0.1
tracks/0/type = "value"
tracks/0/imported = false
tracks/0/enabled = true
tracks/0/path = NodePath("Meshes/MeshInstance3D6:material_override:albedo_color")
tracks/0/interp = 1
tracks/0/loop_wrap = true
tracks/0/keys = {
"times": PackedFloat32Array(0, 1),
"transitions": PackedFloat32Array(1.2745606, 2.0705302),
"update": 0,
"values": [Color(1, 0.22000003, 0.22000003, 1), Color(1, 0.6, 0.6, 1)]
}
tracks/1/type = "value"
tracks/1/imported = false
tracks/1/enabled = true
tracks/1/path = NodePath(".:max_speed")
tracks/1/interp = 1
tracks/1/loop_wrap = true
tracks/1/keys = {
"times": PackedFloat32Array(0, 1),
"transitions": PackedFloat32Array(1.0000001, 0.46651652),
"update": 0,
"values": [8.0, 0.0]
}
tracks/2/type = "value"
tracks/2/imported = false
tracks/2/enabled = true
tracks/2/path = NodePath("Meshes:scale")
tracks/2/interp = 1
tracks/2/loop_wrap = true
tracks/2/keys = {
"times": PackedFloat32Array(0, 1),
"transitions": PackedFloat32Array(3.4822025, 0.24999988),
"update": 0,
"values": [Vector3(1, 1, 1), Vector3(2, 2, 2)]
}
tracks/3/type = "method"
tracks/3/imported = false
tracks/3/enabled = true
tracks/3/path = NodePath("ExplosiveCarBehavior")
tracks/3/interp = 1
tracks/3/loop_wrap = true
tracks/3/keys = {
"times": PackedFloat32Array(1),
"transitions": PackedFloat32Array(1),
"values": [{
"args": [],
"method": &"_anim_explode"
}]
}
[sub_resource type="AnimationLibrary" id="AnimationLibrary_nf60p"]
_data = {
&"RESET": SubResource("Animation_jdkrm"),
&"explode": SubResource("Animation_ofstr")
}
[sub_resource type="BoxShape3D" id="BoxShape3D_nf60p"]
size = Vector3(11.374023, 1, 1)
[node name="ExplosiveCar" unique_id=206023291 instance=ExtResource("1_jdkrm")]
[node name="CollisionShape3D" type="CollisionShape3D" parent="Hurtbox" parent_id_path=PackedInt32Array(688205599) index="0" unique_id=1284368855]
transform = Transform3D(2, 0, 0, 0, 2, 0, 0, 0, 2, -0.122092836, 0.34972915, -0.0012522953)
shape = SubResource("BoxShape3D_jdkrm")
debug_color = Color(0.9913104, 0, 0.27320355, 0.41960785)
[node name="Meshes" type="Node3D" parent="." index="2" unique_id=754389420]
[node name="MeshInstance3D6" type="MeshInstance3D" parent="Meshes" index="0" unique_id=394413961]
transform = Transform3D(2, 0, 0, 0, 2, 0, 0, 0, 2, -0.122092836, 0.34972915, -0.0012522953)
material_override = SubResource("StandardMaterial3D_ofstr")
mesh = SubResource("BoxMesh_nf60p")
[node name="MeshInstance3D7" type="MeshInstance3D" parent="Meshes" index="1" unique_id=118317787]
transform = Transform3D(2, 0, 0, 0, 2, 0, 0, 0, 2, 0.59585166, 0.65602696, 0.24429089)
mesh = SubResource("BoxMesh_vj2gi")
surface_material_override/0 = SubResource("StandardMaterial3D_1o86t")
[node name="MeshInstance3D8" type="MeshInstance3D" parent="Meshes" index="2" unique_id=2028775812]
transform = Transform3D(2, 0, 0, 0, 2, 0, 0, 0, 2, 0.60364604, 0.65602696, -0.23176795)
mesh = SubResource("BoxMesh_vj2gi")
surface_material_override/0 = SubResource("StandardMaterial3D_q2pip")
[node name="MeshInstance3D9" type="MeshInstance3D" parent="Meshes" index="3" unique_id=1459550134]
transform = Transform3D(2, 0, 0, 0, -8.742278e-08, -2, 0, 2, -8.742278e-08, -0.8505253, -0.079150766, -0.0012522853)
material_override = SubResource("StandardMaterial3D_ofstr")
mesh = SubResource("CylinderMesh_6ocff")
[node name="MeshInstance3D10" type="MeshInstance3D" parent="Meshes" index="4" unique_id=380519514]
transform = Transform3D(2, 0, 0, 0, -8.742278e-08, -2, 0, 2, -8.742278e-08, 0.62777025, -0.079150766, -0.0012522853)
material_override = SubResource("StandardMaterial3D_ofstr")
mesh = SubResource("CylinderMesh_6ocff")
[node name="CollisionShape3D" type="CollisionShape3D" parent="." index="3" unique_id=493184167]
transform = Transform3D(2, 0, 0, 0, 2, 0, 0, 0, 2, -0.122092836, 0.34972915, -0.0012522953)
shape = SubResource("BoxShape3D_ofstr")
[node name="AnimationPlayer" type="AnimationPlayer" parent="." index="4" unique_id=57061383]
unique_name_in_owner = true
libraries/ = SubResource("AnimationLibrary_nf60p")
speed_scale = 2.0
[node name="ExplosiveCarBehavior" type="Node3D" parent="." index="5" unique_id=61397067]
script = ExtResource("2_ofstr")
[node name="Trigger" type="Area3D" parent="ExplosiveCarBehavior" index="0" unique_id=509352389]
collision_layer = 0
collision_mask = 2
[node name="CollisionShape3D" type="CollisionShape3D" parent="ExplosiveCarBehavior/Trigger" index="0" unique_id=146579196]
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0.25, 0, 0)
shape = SubResource("BoxShape3D_nf60p")
[connection signal="body_entered" from="ExplosiveCarBehavior/Trigger" to="ExplosiveCarBehavior" method="_on_trigger_body_entered"]