Implermented health

This commit is contained in:
Michel 2025-02-02 02:23:55 +01:00
parent 76e5b1927f
commit e6391d9fdd
13 changed files with 142 additions and 109 deletions

View file

@ -14,7 +14,7 @@ size = Vector3(248.301, 1, 176.535)
[node name="TestScene" type="Node3D"]
[node name="Node3D" parent="." instance=ExtResource("2_k3l6b")]
[node name="Player" parent="." instance=ExtResource("2_k3l6b")]
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0.0230917, 0, -0.0855939)
[node name="DirectionalLight3D" type="DirectionalLight3D" parent="."]

View file

@ -63,7 +63,7 @@ node = SubResource("BBNode_qn8c3")
method = &"Fire"
[sub_resource type="BTProbability" id="BTProbability_3bm4s"]
run_chance = 0.33
run_chance = 0.66
children = [SubResource("BTCallMethod_1c0iq")]
[sub_resource type="BTCooldown" id="BTCooldown_3g17e"]

View file

@ -62,7 +62,7 @@ graph_offset = Vector2(-376, -32)
[sub_resource type="BlackboardPlan" id="BlackboardPlan_hf7lk"]
[sub_resource type="BoxShape3D" id="BoxShape3D_ov0pa"]
size = Vector3(1, 2.08771, 0.126)
size = Vector3(1, 2.08771, 0.273685)
[node name="Enemy" type="CharacterBody3D"]
script = ExtResource("1_n8jwt")
@ -71,15 +71,15 @@ script = ExtResource("1_n8jwt")
transform = Transform3D(0.42, 0, 0, 0, 0.42, 0, 0, 0, 0.42, 0, 0, 0)
[node name="Vert" parent="enemies" index="0"]
transform = Transform3D(98.6026, -0.0322576, 16.6591, 0.0327155, 100, -4.37121e-06, -16.6591, 0.00545441, 98.6026, 0, 0.000652267, 0)
transform = Transform3D(97.8205, -0.0251948, -20.7636, 0.0257551, 100, -4.37103e-06, 20.7636, -0.00534343, 97.8206, 0, 0.000652266, 0)
[node name="Sprite3D" type="Sprite3D" parent="enemies/Vert" index="0"]
transform = Transform3D(0.01, 0, 0, 0, 0.01, 4.37114e-10, 0, -4.37114e-10, 0.01, 0, 0.0260873, 0.000118641)
modulate = Color(1, 0.66, 0.66, 1)
transform = Transform3D(0.00999984, -1.44888e-06, 5.6131e-05, 1.44904e-06, 0.01, -2.46636e-08, -5.6131e-05, 3.27968e-08, 0.00999984, -3.11379e-06, 0.0260873, 0.000118726)
modulate = Color(1, 0.86, 0.86, 1)
texture = ExtResource("2_r5jpp")
[node name="Shoot Marker" type="Node3D" parent="enemies/Vert" index="1"]
transform = Transform3D(0.025, 0, 0, 0, 0.025, 0, 0, 0, 0.025, -0.00423838, 0.0391859, 0.000117709)
transform = Transform3D(0.0242074, -1.30064e-06, 0.00624512, 9.47821e-07, 0.025, 1.53265e-06, -0.00624511, -1.24728e-06, 0.0242074, -0.00403827, 0.0391857, 0.00234848)
[node name="AnimationPlayer" parent="enemies" index="1"]
libraries = {
@ -106,7 +106,7 @@ MuzzleFlash = ExtResource("10_dtmwf")
Origin = NodePath("../enemies/Vert/Shoot Marker")
[node name="CollisionShape3D" type="CollisionShape3D" parent="."]
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 1.02066, -0.00598145)
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 1.02066, 0.00610204)
shape = SubResource("BoxShape3D_ov0pa")
[node name="NavigationAgent" type="NavigationAgent3D" parent="."]

View file

@ -10,7 +10,7 @@
[resource]
diffuse_mode = 3
specular_mode = 1
albedo_color = Color(0.669713, 1.09979e-05, 0.0924059, 1)
albedo_color = Color(0.999731, 0.069561, 0.173636, 1)
albedo_texture = ExtResource("1_jli10")
metallic_specular = 0.02
roughness_texture = ExtResource("2_g6sro")

View file

@ -3,6 +3,16 @@
[ext_resource type="Script" path="res://scripts/muzzleflash.gd" id="2_3yxq0"]
[ext_resource type="Material" uid="uid://dqp4e2wn3lp1e" path="res://content/muzzleflash/muzzleflash_material.tres" id="2_c664a"]
[sub_resource type="Animation" id="Animation_inf8h"]
length = 0.001
tracks/0/type = "scale_3d"
tracks/0/imported = false
tracks/0/enabled = true
tracks/0/path = NodePath("Node3D")
tracks/0/interp = 1
tracks/0/loop_wrap = true
tracks/0/keys = PackedFloat32Array(0, 1, 1.5234, 1.59234, 0.307491)
[sub_resource type="Animation" id="Animation_44h7b"]
resource_name = "muzzleflash"
length = 0.1
@ -14,16 +24,6 @@ tracks/0/interp = 1
tracks/0/loop_wrap = true
tracks/0/keys = PackedFloat32Array(0, 1, 1.5234, 1.59234, 0.307491, 0.1, 1, 0.584257, 0.815035, 1.26645)
[sub_resource type="Animation" id="Animation_inf8h"]
length = 0.001
tracks/0/type = "scale_3d"
tracks/0/imported = false
tracks/0/enabled = true
tracks/0/path = NodePath("Node3D")
tracks/0/interp = 1
tracks/0/loop_wrap = true
tracks/0/keys = PackedFloat32Array(0, 1, 1.5234, 1.59234, 0.307491)
[sub_resource type="AnimationLibrary" id="AnimationLibrary_hlj70"]
_data = {
"RESET": SubResource("Animation_inf8h"),

View file

@ -23,7 +23,7 @@ heightmap_texture = ExtResource("3_eyjbo")
[resource]
next_pass = SubResource("StandardMaterial3D_e1on6")
albedo_color = Color(0.56, 0, 0, 1)
albedo_color = Color(0.712689, 2.16348e-05, 1.15514e-05, 1)
albedo_texture = ExtResource("1_gksjt")
metallic_specular = 0.02
roughness_texture = ExtResource("2_jh5sx")

View file

@ -27,4 +27,3 @@ blend_point_3/node = SubResource("AnimationNodeAnimation_hwjyc")
blend_point_3/pos = Vector2(-1, 0)
blend_point_4/node = SubResource("AnimationNodeAnimation_owips")
blend_point_4/pos = Vector2(0, -1)
max_space = Vector2(1, 3)

View file

@ -466,8 +466,8 @@ bones/6/parent = 5
bones/6/rest = Transform3D(0.999755, -0.0152834, 0.0159934, 0.0152834, -0.0454936, -0.998848, 0.0159934, 0.998848, -0.0452489, 0, 4.76836e-11, -7.62939e-10)
bones/6/enabled = true
bones/6/position = Vector3(0, 4.76836e-11, -7.62939e-10)
bones/6/rotation = Quaternion(0.722928, -4.71839e-09, 0.0110615, 0.690835)
bones/6/scale = Vector3(1, 1, 1)
bones/6/rotation = Quaternion(0.685382, -0.0293075, 0.03841, 0.726579)
bones/6/scale = Vector3(1.00716, 0.990373, 1.00756)
bones/7/name = "pole_line.R_end"
bones/7/parent = 6
bones/7/rest = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0.00391025, 0)
@ -487,8 +487,8 @@ bones/9/parent = 8
bones/9/rest = Transform3D(0.999755, 0.0152834, -0.0159934, -0.0152834, -0.0454936, -0.998848, -0.0159934, 0.998848, -0.0452489, 0, 4.76836e-11, -7.62939e-10)
bones/9/enabled = true
bones/9/position = Vector3(0, 4.76836e-11, -7.62939e-10)
bones/9/rotation = Quaternion(0.722928, 4.71839e-09, -0.0110615, 0.690835)
bones/9/scale = Vector3(1, 1, 1)
bones/9/rotation = Quaternion(0.609096, 0.083777, -0.0899037, 0.783518)
bones/9/scale = Vector3(0.910517, 1.21307, 0.910522)
bones/10/name = "pole_line.L_end"
bones/10/parent = 9
bones/10/rest = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0.00391025, 0)
@ -515,21 +515,21 @@ bones/13/parent = 12
bones/13/rest = Transform3D(0.289313, -0.201567, -0.935772, 0.93034, 0.289312, 0.225315, 0.225315, -0.935772, 0.271228, 0, 0.00139584, 0)
bones/13/enabled = true
bones/13/position = Vector3(0, 0.00139584, 0)
bones/13/rotation = Quaternion(-0.426841, -0.426841, 0.416113, 0.680046)
bones/13/rotation = Quaternion(-0.282023, -0.558744, 0.597224, 0.501589)
bones/13/scale = Vector3(1, 1, 1)
bones/14/name = "forearm.R"
bones/14/parent = 13
bones/14/rest = Transform3D(0.967755, 0.113719, 0.224763, 0.180815, 0.307618, -0.934172, -0.175374, 0.94469, 0.277137, 3.1834e-10, 0.00266141, -1.26107e-11)
bones/14/enabled = true
bones/14/position = Vector3(3.1834e-10, 0.00266141, -1.26107e-11)
bones/14/rotation = Quaternion(0.588005, 0.125226, 0.0209983, 0.798829)
bones/14/rotation = Quaternion(0.82986, 0.124679, -0.0240342, 0.543332)
bones/14/scale = Vector3(1, 1, 1)
bones/15/name = "hand.R"
bones/15/parent = 14
bones/15/rest = Transform3D(0.998803, -0.0473205, -0.0123773, 0.0478966, 0.997532, 0.0513467, 0.00991698, -0.0518781, 0.998604, -1.36696e-10, 0.00253111, 1.61345e-10)
bones/15/enabled = true
bones/15/position = Vector3(-1.36696e-10, 0.00253111, 1.61345e-10)
bones/15/rotation = Quaternion(-0.0258225, -0.0055771, 0.0238194, 0.999367)
bones/15/rotation = Quaternion(-0.295409, -0.0342655, 0.139281, 0.944542)
bones/15/scale = Vector3(1, 1, 1)
bones/16/name = "index_meta.R"
bones/16/parent = 15
@ -543,21 +543,21 @@ bones/17/parent = 16
bones/17/rest = Transform3D(0.917378, -0.395351, -0.0459933, 0.396836, 0.899629, 0.18218, -0.0306483, -0.18538, 0.982189, 4.75825e-10, 0.000649227, 3.51402e-10)
bones/17/enabled = true
bones/17/position = Vector3(4.75825e-10, 0.000649227, 3.51402e-10)
bones/17/rotation = Quaternion(-0.0942872, -0.00393634, 0.203213, 0.974576)
bones/17/rotation = Quaternion(-0.0979801, -0.0112315, 0.138692, 0.985413)
bones/17/scale = Vector3(1, 1, 1)
bones/18/name = "index2.R"
bones/18/parent = 17
bones/18/rest = Transform3D(0.932415, -0.327099, -0.153652, 0.332346, 0.943114, 0.00906678, 0.141946, -0.0595196, 0.988084, -5.00436e-13, 0.000399634, -1.3235e-10)
bones/18/enabled = true
bones/18/position = Vector3(-5.00436e-13, 0.000399634, -1.3235e-10)
bones/18/rotation = Quaternion(-0.0174465, -0.0751926, 0.167746, 0.982804)
bones/18/rotation = Quaternion(0.00285996, -0.0771369, -0.0955664, 0.992426)
bones/18/scale = Vector3(1, 1, 1)
bones/19/name = "index3.R"
bones/19/parent = 18
bones/19/rest = Transform3D(0.930111, -0.359594, 0.0747373, 0.358462, 0.933109, 0.0285086, -0.0799896, 0.000274406, 0.996796, 6.75992e-10, 0.000217569, 6.78151e-11)
bones/19/enabled = true
bones/19/position = Vector3(6.75992e-10, 0.000217569, 6.78151e-11)
bones/19/rotation = Quaternion(-0.00718539, 0.0393769, 0.18274, 0.982346)
bones/19/rotation = Quaternion(-0.014737, 0.0372155, -0.0126211, 0.999119)
bones/19/scale = Vector3(1, 1, 1)
bones/20/name = "index3.R_end"
bones/20/parent = 19
@ -585,14 +585,14 @@ bones/23/parent = 22
bones/23/rest = Transform3D(0.745321, -0.659727, 0.0962067, 0.665133, 0.745686, -0.0393761, -0.0457625, 0.0933381, 0.994582, 1.45929e-10, 0.000428075, 4.40949e-11)
bones/23/enabled = true
bones/23/position = Vector3(1.45929e-10, 0.000428075, 4.40949e-11)
bones/23/rotation = Quaternion(0.0355426, 0.0380212, 0.354815, 0.933487)
bones/23/rotation = Quaternion(0.0470606, 0.0222304, 0.674114, 0.736792)
bones/23/scale = Vector3(1, 1, 1)
bones/24/name = "middle3.R"
bones/24/parent = 23
bones/24/rest = Transform3D(0.927281, -0.373308, -0.028122, 0.373945, 0.927184, 0.0222794, 0.0177572, -0.0311754, 0.999356, -7.29711e-10, 0.000267549, 1.92479e-10)
bones/24/enabled = true
bones/24/position = Vector3(-7.29711e-10, 0.000267549, 1.92479e-10)
bones/24/rotation = Quaternion(-0.0136148, -0.0116853, 0.190323, 0.981557)
bones/24/rotation = Quaternion(-0.0161525, -0.00781051, 0.43526, 0.900126)
bones/24/scale = Vector3(1, 1, 1)
bones/25/name = "middle3.R_end"
bones/25/parent = 24
@ -620,14 +620,14 @@ bones/28/parent = 27
bones/28/rest = Transform3D(0.875576, -0.421953, 0.235207, 0.445166, 0.89384, -0.0536474, -0.187601, 0.151679, 0.970463, 1.72083e-10, 0.00041303, 3.68731e-11)
bones/28/enabled = true
bones/28/position = Vector3(1.72083e-10, 0.00041303, 3.68731e-11)
bones/28/rotation = Quaternion(0.0530868, 0.109316, 0.224192, 0.966938)
bones/28/rotation = Quaternion(0.102228, 0.0657092, 0.694722, 0.708938)
bones/28/scale = Vector3(1, 1, 1)
bones/29/name = "ring3.R"
bones/29/parent = 28
bones/29/rest = Transform3D(0.896325, -0.442626, -0.0261395, 0.443333, 0.893629, 0.0698765, -0.00757009, -0.0742205, 0.997213, -1.47222e-10, 0.0002467, -4.93319e-11)
bones/29/enabled = true
bones/29/position = Vector3(-1.47222e-10, 0.0002467, -4.93319e-11)
bones/29/rotation = Quaternion(-0.0370227, -0.00477103, 0.227628, 0.973032)
bones/29/rotation = Quaternion(-0.0349312, -0.0131626, -0.00239495, 0.9993)
bones/29/scale = Vector3(1, 1, 1)
bones/30/name = "ring3.R_end"
bones/30/parent = 29
@ -655,7 +655,7 @@ bones/33/parent = 32
bones/33/rest = Transform3D(0.900206, -0.418934, 0.118847, 0.430854, 0.896472, -0.103453, -0.0632026, 0.144335, 0.987509, 3.57407e-10, 0.000294327, -1.2612e-10)
bones/33/enabled = true
bones/33/position = Vector3(3.57407e-10, 0.000294327, -1.2612e-10)
bones/33/rotation = Quaternion(0.063689, 0.0467921, 0.218421, 0.972649)
bones/33/rotation = Quaternion(0.0718133, 0.0329945, 0.409986, 0.908661)
bones/33/scale = Vector3(1, 1, 1)
bones/34/name = "pinky3.R"
bones/34/parent = 33
@ -683,14 +683,14 @@ bones/37/parent = 36
bones/37/rest = Transform3D(0.81243, -0.582946, -0.0114595, 0.582738, 0.811175, 0.0491062, -0.0193306, -0.0465732, 0.998728, 3.87094e-10, 0.000535015, -2.64585e-10)
bones/37/enabled = true
bones/37/position = Vector3(3.87094e-10, 0.000535015, -2.64585e-10)
bones/37/rotation = Quaternion(-0.0251359, 0.00206782, 0.306236, 0.951621)
bones/37/rotation = Quaternion(-0.0719948, 0.0990852, 0.535014, 0.835918)
bones/37/scale = Vector3(1, 1, 1)
bones/38/name = "thumb2.R"
bones/38/parent = 37
bones/38/rest = Transform3D(0.997504, -0.0704799, -0.00439951, 0.0704634, 0.989289, 0.127834, -0.00465736, -0.127825, 0.991786, 3.60323e-12, 0.000226731, -4.33635e-10)
bones/38/enabled = true
bones/38/position = Vector3(3.60323e-12, 0.000226731, -4.33635e-10)
bones/38/rotation = Quaternion(-0.0640866, 6.46356e-05, 0.0353305, 0.997319)
bones/38/rotation = Quaternion(0.03212, 0.0582583, 0.363318, 0.929287)
bones/38/scale = Vector3(1, 1, 1)
bones/39/name = "thumb2.R_end"
bones/39/parent = 38
@ -704,7 +704,7 @@ bones/40/parent = 14
bones/40/rest = Transform3D(0.999974, 0.00428396, 0.00580153, -0.00412317, 0.999615, -0.0274478, -0.00591688, 0.0274232, 0.999606, -8.46418e-06, 0.000215645, -6.06698e-05)
bones/40/enabled = true
bones/40/position = Vector3(-8.46418e-06, 0.000215645, -6.06698e-05)
bones/40/rotation = Quaternion(0.0137191, 0.0029299, -0.00210199, 0.999899)
bones/40/rotation = Quaternion(0.0136922, -0.0106461, -0.00228802, 0.999847)
bones/40/scale = Vector3(1, 1, 1)
bones/41/name = "twist1.R_end"
bones/41/parent = 40
@ -718,7 +718,7 @@ bones/42/parent = 14
bones/42/rest = Transform3D(0.999974, 0.00428394, 0.00580145, -0.00412316, 0.999615, -0.0274474, -0.0059168, 0.0274228, 0.999606, -2.00581e-06, 0.00172259, -1.93289e-05)
bones/42/enabled = true
bones/42/position = Vector3(-2.00581e-06, 0.00172259, -1.93289e-05)
bones/42/rotation = Quaternion(0.0137189, 0.00292986, -0.00210199, 0.999899)
bones/42/rotation = Quaternion(0.0136163, -0.0397939, -0.00268602, 0.999112)
bones/42/scale = Vector3(1, 1, 1)
bones/43/name = "twist3.R_end"
bones/43/parent = 42
@ -732,7 +732,7 @@ bones/44/parent = 14
bones/44/rest = Transform3D(0.999974, 0.00428412, 0.00580153, -0.00412334, 0.999615, -0.0274478, -0.00591688, 0.0274232, 0.999606, -5.23504e-06, 0.000969117, -3.99994e-05)
bones/44/enabled = true
bones/44/position = Vector3(-5.23504e-06, 0.000969117, -3.99994e-05)
bones/44/rotation = Quaternion(0.0137191, 0.0029299, -0.00210208, 0.999899)
bones/44/rotation = Quaternion(0.0136523, -0.0268674, -0.00250983, 0.999543)
bones/44/scale = Vector3(1, 1, 1)
bones/45/name = "twist2.R_end"
bones/45/parent = 44
@ -760,7 +760,7 @@ bones/48/parent = 14
bones/48/rest = Transform3D(0.999974, 0.00428436, 0.00580146, -0.00412358, 0.999615, -0.0274474, -0.00591682, 0.0274228, 0.999606, -2.00581e-06, 0.00172259, -1.93289e-05)
bones/48/enabled = true
bones/48/position = Vector3(-2.00581e-06, 0.00172259, -1.93289e-05)
bones/48/rotation = Quaternion(0.0137189, 0.00292986, -0.0021022, 0.999899)
bones/48/rotation = Quaternion(0.013692, -0.0106462, -0.00228823, 0.999847)
bones/48/scale = Vector3(1, 1, 1)
bones/49/name = "armweartwist.R_end"
bones/49/parent = 48
@ -774,7 +774,7 @@ bones/50/parent = 14
bones/50/rest = Transform3D(0.998924, -0.0448829, -0.0116821, 0.0454014, 0.99778, 0.0487276, 0.00946913, -0.0492056, 0.998744, 1.22313e-06, 0.00247606, 1.34137e-06)
bones/50/enabled = true
bones/50/position = Vector3(1.22313e-06, 0.00247606, 1.34137e-06)
bones/50/rotation = Quaternion(-0.0244973, -0.00529082, 0.0225839, 0.999431)
bones/50/rotation = Quaternion(-0.0242033, -0.0187956, 0.0229129, 0.999268)
bones/50/scale = Vector3(1, 1, 1)
bones/51/name = "cuff.R_end"
bones/51/parent = 50
@ -788,7 +788,7 @@ bones/52/parent = 14
bones/52/rest = Transform3D(1, -2.01654e-09, 3.1474e-08, 2.01654e-09, 1, 7.23308e-08, -3.1474e-08, -7.23308e-08, 1, -1.54241e-10, -1.23587e-10, 3.80932e-10)
bones/52/enabled = true
bones/52/position = Vector3(-1.54241e-10, -1.23587e-10, 3.80932e-10)
bones/52/rotation = Quaternion(-3.61654e-08, 1.5737e-08, 1.00827e-09, 1)
bones/52/rotation = Quaternion(1.53914e-08, -0.0923886, 1.06304e-08, 0.995723)
bones/52/scale = Vector3(1, 1, 1)
bones/53/name = "blouse.R_end"
bones/53/parent = 52
@ -809,21 +809,21 @@ bones/55/parent = 54
bones/55/rest = Transform3D(0.289313, 0.201567, 0.935772, -0.93034, 0.289312, 0.225315, -0.225315, -0.935772, 0.271228, 0, 0.00139584, 0)
bones/55/enabled = true
bones/55/position = Vector3(0, 0.00139584, 0)
bones/55/rotation = Quaternion(-0.426841, 0.426841, -0.416113, 0.680046)
bones/55/rotation = Quaternion(-0.0166644, 0.462827, -0.758183, 0.45899)
bones/55/scale = Vector3(1, 1, 1)
bones/56/name = "forearm.L"
bones/56/parent = 55
bones/56/rest = Transform3D(0.967755, -0.113719, -0.224763, -0.180815, 0.307618, -0.934172, 0.175374, 0.94469, 0.277137, -3.1834e-10, 0.00266141, -1.26107e-11)
bones/56/enabled = true
bones/56/position = Vector3(-3.1834e-10, 0.00266141, -1.26107e-11)
bones/56/rotation = Quaternion(0.588005, -0.125226, -0.0209983, 0.798829)
bones/56/rotation = Quaternion(0.59871, -0.125498, -0.0193099, 0.790837)
bones/56/scale = Vector3(1, 1, 1)
bones/57/name = "hand.L"
bones/57/parent = 56
bones/57/rest = Transform3D(0.998803, 0.0473205, 0.0123773, -0.0478966, 0.997532, 0.0513467, -0.00991698, -0.0518781, 0.998604, 1.36696e-10, 0.00253111, 1.61345e-10)
bones/57/enabled = true
bones/57/position = Vector3(1.36696e-10, 0.00253111, 1.61345e-10)
bones/57/rotation = Quaternion(-0.0258225, 0.0055771, -0.0238194, 0.999367)
bones/57/rotation = Quaternion(-0.201574, -0.0350852, 0.238639, 0.949309)
bones/57/scale = Vector3(1, 1, 1)
bones/58/name = "index_meta.L"
bones/58/parent = 57
@ -836,22 +836,22 @@ bones/59/name = "index1.L"
bones/59/parent = 58
bones/59/rest = Transform3D(0.917378, 0.395351, 0.0459933, -0.396836, 0.899629, 0.18218, 0.0306483, -0.18538, 0.982189, -4.75825e-10, 0.000649227, 3.51402e-10)
bones/59/enabled = true
bones/59/position = Vector3(-4.75825e-10, 0.000649227, 3.51402e-10)
bones/59/rotation = Quaternion(-0.0942872, 0.00393634, -0.203213, 0.974576)
bones/59/position = Vector3(5.26133e-06, 0.00062688, 4.6132e-06)
bones/59/rotation = Quaternion(-0.0921515, 0.0504243, 0.195935, 0.974974)
bones/59/scale = Vector3(1, 1, 1)
bones/60/name = "index2.L"
bones/60/parent = 59
bones/60/rest = Transform3D(0.932415, 0.327099, 0.153652, -0.332346, 0.943114, 0.00906678, -0.141946, -0.0595196, 0.988084, 5.00436e-13, 0.000399634, -1.3235e-10)
bones/60/enabled = true
bones/60/position = Vector3(5.00436e-13, 0.000399634, -1.3235e-10)
bones/60/rotation = Quaternion(-0.0174465, 0.0751926, -0.167746, 0.982804)
bones/60/rotation = Quaternion(-0.0504229, 0.0584449, -0.605684, 0.791952)
bones/60/scale = Vector3(1, 1, 1)
bones/61/name = "index3.L"
bones/61/parent = 60
bones/61/rest = Transform3D(0.930111, 0.359594, -0.0747373, -0.358462, 0.933109, 0.0285086, 0.0799896, 0.000274406, 0.996796, -6.75992e-10, 0.000217569, 6.78151e-11)
bones/61/enabled = true
bones/61/position = Vector3(-6.75992e-10, 0.000217569, 6.78151e-11)
bones/61/rotation = Quaternion(-0.00718539, -0.0393769, -0.18274, 0.982346)
bones/61/rotation = Quaternion(0.0114703, -0.0383484, -0.608711, 0.792382)
bones/61/scale = Vector3(1, 1, 1)
bones/62/name = "index3.L_end"
bones/62/parent = 61
@ -871,22 +871,22 @@ bones/64/name = "middle1.L"
bones/64/parent = 63
bones/64/rest = Transform3D(0.897312, 0.438301, 0.0521827, -0.441346, 0.892693, 0.0911681, -0.00662413, -0.104837, 0.994467, -7.31031e-10, 0.00064664, 2.63282e-10)
bones/64/enabled = true
bones/64/position = Vector3(-7.31031e-10, 0.00064664, 2.63282e-10)
bones/64/rotation = Quaternion(-0.0503773, 0.0151146, -0.226087, 0.972686)
bones/64/position = Vector3(-1.39905e-05, 0.000607788, 8.67968e-07)
bones/64/rotation = Quaternion(-0.0560438, 0.00556503, 0.0915036, 0.994211)
bones/64/scale = Vector3(1, 1, 1)
bones/65/name = "middle2.L"
bones/65/parent = 64
bones/65/rest = Transform3D(0.745321, 0.659727, -0.0962067, -0.665133, 0.745686, -0.0393761, 0.0457625, 0.0933381, 0.994582, -1.45929e-10, 0.000428075, 4.40949e-11)
bones/65/enabled = true
bones/65/position = Vector3(-1.45929e-10, 0.000428075, 4.40949e-11)
bones/65/rotation = Quaternion(0.0355426, -0.0380212, -0.354815, 0.933487)
bones/65/rotation = Quaternion(0.0483554, -0.0192523, -0.71875, 0.693318)
bones/65/scale = Vector3(1, 1, 1)
bones/66/name = "middle3.L"
bones/66/parent = 65
bones/66/rest = Transform3D(0.927281, 0.373308, 0.028122, -0.373945, 0.927184, 0.0222794, -0.0177572, -0.0311754, 0.999356, 7.29711e-10, 0.000267549, 1.92479e-10)
bones/66/enabled = true
bones/66/position = Vector3(7.29711e-10, 0.000267549, 1.92479e-10)
bones/66/rotation = Quaternion(-0.0136148, 0.0116853, -0.190323, 0.981557)
bones/66/rotation = Quaternion(-0.0173623, 0.00452311, -0.601864, 0.798397)
bones/66/scale = Vector3(1, 1, 1)
bones/67/name = "middle3.L_end"
bones/67/parent = 66
@ -906,22 +906,22 @@ bones/69/name = "ring1.L"
bones/69/parent = 68
bones/69/rest = Transform3D(0.786512, 0.617183, 0.0219931, -0.611213, 0.783015, -0.115352, -0.0884141, 0.0772832, 0.993081, -7.66656e-10, 0.000618599, -1.41676e-10)
bones/69/enabled = true
bones/69/position = Vector3(-7.66656e-10, 0.000618599, -1.41676e-10)
bones/69/rotation = Quaternion(0.0510295, 0.0292471, -0.325405, 0.943744)
bones/69/position = Vector3(1.30419e-06, 0.000602323, -2.71001e-06)
bones/69/rotation = Quaternion(0.0409456, -0.0210825, 0.0696472, 0.996508)
bones/69/scale = Vector3(1, 1, 1)
bones/70/name = "ring2.L"
bones/70/parent = 69
bones/70/rest = Transform3D(0.875576, 0.421953, -0.235207, -0.445166, 0.89384, -0.0536474, 0.187601, 0.151679, 0.970463, -1.72083e-10, 0.00041303, 3.68731e-11)
bones/70/enabled = true
bones/70/position = Vector3(-1.72083e-10, 0.00041303, 3.68731e-11)
bones/70/rotation = Quaternion(0.0530868, -0.109316, -0.224192, 0.966938)
bones/70/rotation = Quaternion(0.0377608, -0.115509, -0.0908998, 0.988417)
bones/70/scale = Vector3(1, 1, 1)
bones/71/name = "ring3.L"
bones/71/parent = 70
bones/71/rest = Transform3D(0.896325, 0.442626, 0.0261395, -0.443333, 0.893629, 0.0698765, 0.00757009, -0.0742205, 0.997213, 1.47222e-10, 0.0002467, -4.93319e-11)
bones/71/enabled = true
bones/71/position = Vector3(1.47222e-10, 0.0002467, -4.93319e-11)
bones/71/rotation = Quaternion(-0.0370227, 0.00477103, -0.227628, 0.973032)
bones/71/rotation = Quaternion(-0.0354375, -0.0117314, -0.626531, 0.778502)
bones/71/scale = Vector3(1, 1, 1)
bones/72/name = "ring3.L_end"
bones/72/parent = 71
@ -941,22 +941,22 @@ bones/74/name = "pinky1.L"
bones/74/parent = 73
bones/74/rest = Transform3D(0.884728, 0.463521, -0.049038, -0.464454, 0.867839, -0.176462, -0.0392369, 0.178897, 0.983085, -1.94544e-10, 0.000594951, 7.62025e-11)
bones/74/enabled = true
bones/74/position = Vector3(-1.94544e-10, 0.000594951, 7.62025e-11)
bones/74/rotation = Quaternion(0.0919294, -0.00253551, -0.240062, 0.966392)
bones/74/position = Vector3(-8.65005e-06, 0.000669554, 2.38654e-05)
bones/74/rotation = Quaternion(0.0945839, -0.108202, 0.236727, 0.960889)
bones/74/scale = Vector3(1, 1, 1)
bones/75/name = "pinky2.L"
bones/75/parent = 74
bones/75/rest = Transform3D(0.900206, 0.418934, -0.118847, -0.430854, 0.896472, -0.103453, 0.0632026, 0.144335, 0.987509, -3.57407e-10, 0.000294327, -1.2612e-10)
bones/75/enabled = true
bones/75/position = Vector3(-3.57407e-10, 0.000294327, -1.2612e-10)
bones/75/rotation = Quaternion(0.063689, -0.0467921, -0.218421, 0.972649)
bones/75/rotation = Quaternion(0.0550313, -0.0567217, -0.0538149, 0.995419)
bones/75/scale = Vector3(1, 1, 1)
bones/76/name = "pinky3.L"
bones/76/parent = 75
bones/76/rest = Transform3D(0.886375, 0.455138, -0.0847801, -0.450338, 0.890097, 0.0701647, 0.107397, -0.0240126, 0.993926, 7.28884e-10, 0.000161741, 2.67904e-10)
bones/76/enabled = true
bones/76/position = Vector3(7.28884e-10, 0.000161741, 2.67904e-10)
bones/76/rotation = Quaternion(-0.0242506, -0.0494855, -0.23316, 0.970876)
bones/76/rotation = Quaternion(-0.0284048, -0.0472237, -0.149045, 0.987294)
bones/76/scale = Vector3(1, 1, 1)
bones/77/name = "pinky3.L_end"
bones/77/parent = 76
@ -969,22 +969,22 @@ bones/78/name = "thumb_meta.L"
bones/78/parent = 57
bones/78/rest = Transform3D(0.240535, 0.343136, 0.907965, 0.585873, 0.694485, -0.417665, -0.773884, 0.632415, -0.0339863, 7.71225e-05, 0.000177085, 8.39641e-05)
bones/78/enabled = true
bones/78/position = Vector3(7.71225e-05, 0.000177085, 8.39641e-05)
bones/78/rotation = Quaternion(0.380801, 0.609905, 0.088026, 0.68939)
bones/78/position = Vector3(-8.8677e-05, 0.000149522, 3.81398e-05)
bones/78/rotation = Quaternion(0.293949, 0.638458, 0.159887, 0.69311)
bones/78/scale = Vector3(1, 1, 1)
bones/79/name = "thumb1.L"
bones/79/parent = 78
bones/79/rest = Transform3D(0.81243, 0.582946, 0.0114595, -0.582738, 0.811175, 0.0491062, 0.0193306, -0.0465732, 0.998728, -3.87094e-10, 0.000535015, -2.64585e-10)
bones/79/enabled = true
bones/79/position = Vector3(-3.87094e-10, 0.000535015, -2.64585e-10)
bones/79/rotation = Quaternion(-0.0251359, -0.00206782, -0.306236, 0.951621)
bones/79/rotation = Quaternion(-0.246789, -0.068873, -0.208296, 0.943909)
bones/79/scale = Vector3(1, 1, 1)
bones/80/name = "thumb2.L"
bones/80/parent = 79
bones/80/rest = Transform3D(0.997504, 0.0704799, 0.00439951, -0.0704634, 0.989289, 0.127834, 0.00465736, -0.127825, 0.991786, -3.60323e-12, 0.000226731, -4.33635e-10)
bones/80/enabled = true
bones/80/position = Vector3(-3.60323e-12, 0.000226731, -4.33635e-10)
bones/80/rotation = Quaternion(-0.0640866, -6.46356e-05, -0.0353305, 0.997319)
bones/80/rotation = Quaternion(0.0181542, -0.258237, 0.0705999, 0.963328)
bones/80/scale = Vector3(1, 1, 1)
bones/81/name = "thumb2.L_end"
bones/81/parent = 80
@ -998,7 +998,7 @@ bones/82/parent = 56
bones/82/rest = Transform3D(0.999974, -0.00428396, -0.00580153, 0.00412317, 0.999615, -0.0274478, 0.00591688, 0.0274232, 0.999606, 8.46418e-06, 0.000215645, -6.06698e-05)
bones/82/enabled = true
bones/82/position = Vector3(8.46418e-06, 0.000215645, -6.06698e-05)
bones/82/rotation = Quaternion(0.0137191, -0.0029299, 0.00210199, 0.999899)
bones/82/rotation = Quaternion(0.013749, -0.0122868, 0.0019736, 0.999828)
bones/82/scale = Vector3(1, 1, 1)
bones/83/name = "twist1.L_end"
bones/83/parent = 82
@ -1012,7 +1012,7 @@ bones/84/parent = 56
bones/84/rest = Transform3D(0.999974, -0.00428394, -0.00580145, 0.00412316, 0.999615, -0.0274474, 0.0059168, 0.0274228, 0.999606, 2.00581e-06, 0.00172259, -1.93289e-05)
bones/84/enabled = true
bones/84/position = Vector3(2.00581e-06, 0.00172259, -1.93289e-05)
bones/84/rotation = Quaternion(0.0137189, -0.00292986, 0.00210199, 0.999899)
bones/84/rotation = Quaternion(0.0137985, -0.0378184, 0.00162178, 0.999188)
bones/84/scale = Vector3(1, 1, 1)
bones/85/name = "twist3.L_end"
bones/85/parent = 84
@ -1026,7 +1026,7 @@ bones/86/parent = 56
bones/86/rest = Transform3D(0.999974, -0.00428412, -0.00580153, 0.00412334, 0.999615, -0.0274478, 0.00591688, 0.0274232, 0.999606, 5.23504e-06, 0.000969117, -3.99994e-05)
bones/86/enabled = true
bones/86/position = Vector3(5.23504e-06, 0.000969117, -3.99994e-05)
bones/86/rotation = Quaternion(0.0137191, -0.0029299, 0.00210208, 0.999899)
bones/86/rotation = Quaternion(0.0137753, -0.0253152, 0.00179422, 0.999583)
bones/86/scale = Vector3(1, 1, 1)
bones/87/name = "twist2.L_end"
bones/87/parent = 86
@ -1054,7 +1054,7 @@ bones/90/parent = 56
bones/90/rest = Transform3D(0.999974, -0.00428436, -0.00580146, 0.00412358, 0.999615, -0.0274474, 0.00591682, 0.0274228, 0.999606, 2.00581e-06, 0.00172259, -1.93289e-05)
bones/90/enabled = true
bones/90/position = Vector3(2.00581e-06, 0.00172259, -1.93289e-05)
bones/90/rotation = Quaternion(0.0137189, -0.00292986, 0.0021022, 0.999899)
bones/90/rotation = Quaternion(0.0137488, -0.0122868, 0.00197381, 0.999828)
bones/90/scale = Vector3(1, 1, 1)
bones/91/name = "armweartwist.L_end"
bones/91/parent = 90
@ -1068,7 +1068,7 @@ bones/92/parent = 56
bones/92/rest = Transform3D(0.998924, 0.0448829, 0.0116821, -0.0454014, 0.99778, 0.0487276, -0.00946913, -0.0492056, 0.998744, -1.22313e-06, 0.00247606, 1.34137e-06)
bones/92/enabled = true
bones/92/position = Vector3(-1.22313e-06, 0.00247606, 1.34137e-06)
bones/92/rotation = Quaternion(-0.0244973, 0.00529082, -0.0225839, 0.999431)
bones/92/rotation = Quaternion(-0.0247151, -0.00402103, -0.0223549, 0.999436)
bones/92/scale = Vector3(1, 1, 1)
bones/93/name = "cuff.L_end"
bones/93/parent = 92
@ -1082,7 +1082,7 @@ bones/94/parent = 56
bones/94/rest = Transform3D(1, 2.01654e-09, -3.1474e-08, -2.01654e-09, 1, 7.23308e-08, 3.1474e-08, -7.23308e-08, 1, 1.54241e-10, -1.23587e-10, 3.80932e-10)
bones/94/enabled = true
bones/94/position = Vector3(1.54241e-10, -1.23587e-10, 3.80932e-10)
bones/94/rotation = Quaternion(-3.61654e-08, -1.5737e-08, -1.00827e-09, 1)
bones/94/rotation = Quaternion(-2.23139e-09, 0.0478625, 3.25588e-08, 0.998854)
bones/94/scale = Vector3(1, 1, 1)
bones/95/name = "blouse.L_end"
bones/95/parent = 94
@ -1095,8 +1095,8 @@ bones/96/name = "handIK.R"
bones/96/parent = 0
bones/96/rest = Transform3D(0.931583, 0.363365, 0.0109084, 0.0109083, -0.0579345, 0.998261, 0.363365, -0.929844, -0.0579345, 0.00338212, 0.00270377, -0.00286581)
bones/96/enabled = true
bones/96/position = Vector3(0.00338212, 0.00270377, -0.00286581)
bones/96/rotation = Quaternion(-0.715446, -0.130783, -0.130783, 0.673742)
bones/96/position = Vector3(0.00138322, 0.0042643, -0.00268604)
bones/96/rotation = Quaternion(-0.65666, 0.0629605, 0.234883, 0.713907)
bones/96/scale = Vector3(1, 1, 1)
bones/97/name = "handIK.R_end"
bones/97/parent = 96
@ -1109,8 +1109,8 @@ bones/98/name = "handIK.L"
bones/98/parent = 0
bones/98/rest = Transform3D(0.931583, -0.363365, -0.0109084, -0.0109083, -0.0579345, 0.998261, -0.363365, -0.929844, -0.0579345, -0.00338212, 0.00270377, -0.00286581)
bones/98/enabled = true
bones/98/position = Vector3(-0.00338212, 0.00270377, -0.00286581)
bones/98/rotation = Quaternion(-0.715446, 0.130783, 0.130783, 0.673742)
bones/98/position = Vector3(0.000460905, 0.00427366, -0.00350029)
bones/98/rotation = Quaternion(-0.727027, -0.103511, -0.060138, 0.676093)
bones/98/scale = Vector3(1, 1, 1)
bones/99/name = "handIK.L_end"
bones/99/parent = 98
@ -1153,7 +1153,7 @@ mesh = SubResource("ArrayMesh_lxa88")
skin = SubResource("Skin_1i0dj")
[node name="BoneAttachment3D" type="BoneAttachment3D" parent="LVA4_Armature/Skeleton3D"]
transform = Transform3D(0.931583, 0.363365, 0.0109077, -0.363365, 0.929844, 0.0579351, 0.010909, -0.0579348, 0.998261, 0.00338212, 0.0028658, -0.00250854)
transform = Transform3D(0.882008, -0.451171, -0.136039, 0.441757, 0.892132, -0.0946076, 0.164049, 0.0233483, 0.986176, 0.00146523, 0.00273574, -0.000998727)
bone_name = "hand.R"
bone_idx = 15
@ -1177,5 +1177,5 @@ anim_player = NodePath("..")
"parameters/Crouched Fire/blend_position" = 0
"parameters/Crouched Movement/blend_position" = Vector2(-0.531895, -0.033419)
parameters/Fire/blend_position = 0.0
parameters/Movement/blend_position = 0
parameters/Movement/0/blend_position = Vector2(0, 0)
parameters/Movement/blend_position = 0.248419
parameters/Movement/0/blend_position = Vector2(-0.437148, -0.851852)

View file

@ -35,13 +35,14 @@ Origin = NodePath("LVA4_Armature/Skeleton3D/BoneAttachment3D/Plane/Muzzle")
BulletOrigin = NodePath("..")
[node name="Skeleton3D" parent="CollisionShape3D/Camera3D/Weapon/LVA4_Armature" index="0"]
bones/6/rotation = Quaternion(0.697021, -0.0271559, 0.0376544, 0.715546)
bones/6/rotation = Quaternion(0.697459, -0.0272195, 0.0377435, 0.715112)
bones/6/scale = Vector3(1.01704, 0.970755, 1.01744)
bones/9/rotation = Quaternion(0.597208, 0.088759, -0.0953634, 0.791436)
bones/9/scale = Vector3(0.894297, 1.25036, 0.894302)
bones/13/rotation = Quaternion(-0.28923, -0.582728, 0.583821, 0.485724)
bones/14/rotation = Quaternion(0.848078, 0.123778, -0.0283134, 0.514433)
bones/15/rotation = Quaternion(-0.283662, -0.0771209, 0.0117335, 0.955746)
bones/9/rotation = Quaternion(0.59753, 0.0883948, -0.0950469, 0.791272)
bones/9/scale = Vector3(0.895205, 1.24851, 0.895209)
bones/12/rotation = Quaternion(0.5, 0.5, 0.5, -0.5)
bones/13/rotation = Quaternion(-0.288794, -0.583705, 0.584114, 0.484456)
bones/14/rotation = Quaternion(0.847616, 0.123803, -0.0282024, 0.515193)
bones/15/rotation = Quaternion(-0.281539, -0.0718473, 0.00808318, 0.956822)
bones/17/rotation = Quaternion(-0.0979801, -0.0112315, 0.138692, 0.985413)
bones/18/rotation = Quaternion(0.00285996, -0.0771369, -0.0955664, 0.992426)
bones/19/rotation = Quaternion(-0.014737, 0.0372155, -0.0126211, 0.999119)
@ -52,16 +53,17 @@ bones/29/rotation = Quaternion(-0.0349312, -0.0131626, -0.00239495, 0.9993)
bones/33/rotation = Quaternion(0.0718133, 0.0329945, 0.409986, 0.908661)
bones/37/rotation = Quaternion(-0.0719948, 0.0990852, 0.535014, 0.835918)
bones/38/rotation = Quaternion(0.0321199, 0.0582583, 0.363318, 0.929287)
bones/40/rotation = Quaternion(0.01367, -0.0189025, -0.00240104, 0.999725)
bones/42/rotation = Quaternion(0.0135558, -0.0612161, -0.00297769, 0.998028)
bones/44/rotation = Quaternion(0.0136076, -0.0431957, -0.00273264, 0.99897)
bones/40/rotation = Quaternion(0.0136756, -0.0172532, -0.0023784, 0.999755)
bones/42/rotation = Quaternion(0.0135645, -0.0568211, -0.00291822, 0.998288)
bones/44/rotation = Quaternion(0.0136133, -0.0399402, -0.00268841, 0.999106)
bones/46/rotation = Quaternion(0.8627, 0.184653, -0.263834, -0.389927)
bones/48/rotation = Quaternion(0.0136698, -0.0189026, -0.00240123, 0.999725)
bones/50/rotation = Quaternion(-0.0240003, -0.0270186, 0.0231118, 0.99908)
bones/52/rotation = Quaternion(9.57289e-08, -0.102194, 2.38743e-08, 0.994764)
bones/55/rotation = Quaternion(-0.00863172, 0.430989, -0.779795, 0.453977)
bones/56/rotation = Quaternion(0.568329, -0.124676, -0.024049, 0.812945)
bones/57/rotation = Quaternion(-0.202555, -0.0372334, 0.118361, 0.971378)
bones/48/rotation = Quaternion(0.0136754, -0.0172533, -0.00237861, 0.999755)
bones/50/rotation = Quaternion(-0.0240424, -0.0253808, 0.0230706, 0.999122)
bones/52/rotation = Quaternion(9.57256e-08, -0.10147, 2.38067e-08, 0.994839)
bones/54/rotation = Quaternion(0.5, -0.5, -0.5, -0.5)
bones/55/rotation = Quaternion(-0.00966559, 0.431855, -0.779032, 0.454442)
bones/56/rotation = Quaternion(0.569151, -0.1247, -0.023923, 0.81237)
bones/57/rotation = Quaternion(-0.205716, -0.0320915, 0.116515, 0.971121)
bones/59/position = Vector3(5.26137e-06, 0.00062688, 4.61328e-06)
bones/59/rotation = Quaternion(-0.0921515, 0.0504243, 0.195935, 0.974974)
bones/60/rotation = Quaternion(-0.0504229, 0.0584449, -0.605684, 0.791952)
@ -79,21 +81,23 @@ bones/74/rotation = Quaternion(0.0945839, -0.108202, 0.236727, 0.960889)
bones/75/rotation = Quaternion(0.0550313, -0.0567217, -0.0538148, 0.995419)
bones/76/rotation = Quaternion(-0.0284048, -0.0472237, -0.149045, 0.987294)
bones/78/position = Vector3(-8.86769e-05, 0.000149522, 3.81398e-05)
bones/78/rotation = Quaternion(0.293949, 0.638458, 0.159887, 0.69311)
bones/79/rotation = Quaternion(-0.24679, -0.068873, -0.208296, 0.943909)
bones/80/rotation = Quaternion(0.0181542, -0.258237, 0.0705999, 0.963327)
bones/82/rotation = Quaternion(0.0137306, -0.00845511, 0.00202618, 0.999868)
bones/84/rotation = Quaternion(0.0137638, -0.0259837, 0.00178515, 0.999566)
bones/86/rotation = Quaternion(0.0137486, -0.017656, 0.00189981, 0.999748)
bones/90/rotation = Quaternion(0.0137304, -0.00845505, 0.0020264, 0.999868)
bones/92/rotation = Quaternion(-0.0246213, -0.000215826, -0.0224486, 0.999445)
bones/94/rotation = Quaternion(2.79802e-09, 0.0449708, 4.00876e-08, 0.998988)
bones/82/rotation = Quaternion(0.013728, -0.00687772, 0.0020478, 0.99988)
bones/84/rotation = Quaternion(0.0137617, -0.0217986, 0.00184283, 0.999666)
bones/86/rotation = Quaternion(0.0137452, -0.0144382, 0.0019441, 0.999799)
bones/88/rotation = Quaternion(0.8627, -0.184653, 0.263834, -0.389927)
bones/90/rotation = Quaternion(0.0137278, -0.00687766, 0.00204802, 0.99988)
bones/92/rotation = Quaternion(-0.0245858, 0.00136125, -0.0224883, 0.999444)
bones/94/rotation = Quaternion(2.7712e-09, 0.0456322, 4.00834e-08, 0.998958)
bones/96/position = Vector3(0.00148682, 0.00419669, -0.00257247)
bones/96/rotation = Quaternion(-0.664802, 0.0151952, 0.13056, 0.735365)
bones/96/rotation = Quaternion(-0.664692, 0.0194188, 0.125885, 0.736179)
bones/98/position = Vector3(0.000566952, 0.00437002, -0.00361386)
bones/98/rotation = Quaternion(-0.686633, -0.158208, -0.166366, 0.689803)
bones/98/rotation = Quaternion(-0.687624, -0.153843, -0.170745, 0.688732)
[node name="BoneAttachment3D" parent="CollisionShape3D/Camera3D/Weapon/LVA4_Armature/Skeleton3D" index="1"]
transform = Transform3D(0.965405, -0.212387, -0.151277, 0.196116, 0.973749, -0.115552, 0.171848, 0.0818871, 0.981714, 0.00148609, 0.00257259, -0.00101604)
transform = Transform3D(0.967405, -0.211612, -0.139095, 0.196587, 0.973809, -0.114238, 0.159626, 0.0831701, 0.983668, 0.00147876, 0.00257324, -0.00102415)
[node name="Muzzle" parent="CollisionShape3D/Camera3D/Weapon/LVA4_Armature/Skeleton3D/BoneAttachment3D/Plane" index="0"]
transform = Transform3D(0.00256023, 0.00111408, -0.00109729, 0.000993761, 0.00046617, 0.00279197, 0.00120734, -0.00274618, 2.87907e-05, -0.00118721, 0.00250132, 0.000390777)
@ -108,4 +112,7 @@ max_health = 5.0
[node name="Ui" parent="." instance=ExtResource("7_qi8fi")]
[node name="Enemy Target" type="Node3D" parent="."]
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 1.32602, 0)
[editable path="CollisionShape3D/Camera3D/Weapon"]

View file

@ -7,6 +7,7 @@ const MOVEMENT_SPEED = 1
@onready var agent:NavigationAgent3D = $NavigationAgent
@onready var enemyAi: EnemyAI = $BTPlayer
@onready var health: Health = $Health
@onready var origin: Node3D = $"enemies/Vert/Shoot Marker"
const SPEED = 5.0
const JUMP_VELOCITY = 4.5
@ -43,7 +44,27 @@ func _physics_process(delta: float) -> void:
if enemyAi.aggressive:
rotateTo(delta, (Player.Instance.global_position - self.global_position).normalized())
else:
rotateTo(delta, -velocity.normalized())
rotateTo(delta, velocity.normalized())
updateMovementBlend(delta, velocity.length())
self.animationtree['parameters/Movement/blend_position'] = movementBlend
func fireWeapon() -> void:
var fireDirection = (Player.Instance.enemyTarget.global_position - origin.global_position).normalized()
fireDirection = fireDirection.rotated(Vector3.UP, randf_range(-.3, .3))
DebugDraw3D.draw_arrow(origin.global_position, origin.global_position + Vector3.UP * 1, Color.RED, 0.5, true, 10)
DebugDraw3D.draw_arrow(origin.global_position, origin.global_position + fireDirection * 10, Color.WHITE, 0.5, true, 10)
var query = PhysicsRayQueryParameters3D.create(origin.global_position, origin.global_position + fireDirection * 200)
var result = get_world_3d().direct_space_state.intersect_ray(query)
if not result:
return
var health = result.collider.get_node_or_null('Health')
print(health)
if not health:
return
result.collider.health.take_damage(1, Vector2(0,0))

View file

@ -5,7 +5,7 @@ class_name EnemyAI
const ROAM_DISTANCE: float = 10.0
const DISTANCE_TO_PLAYER: float = 10.0
@export var character: CharacterBody3D
@export var character: Enemy
@export_category("Sprite")
@export var sprite:Sprite3D;
@ -14,7 +14,6 @@ const DISTANCE_TO_PLAYER: float = 10.0
@export_category("Agents")
@export var agent: NavigationAgent3D;
@export var animationTree: AnimationTree;
@export_category("Firing")
@ -47,3 +46,5 @@ func Fire() -> void:
self.animationTree['parameters/playback'].travel('Fire')
var instance = MuzzleFlash.instantiate(PackedScene.GEN_EDIT_STATE_INSTANCE)
Origin.add_child(instance)
character.fireWeapon()

View file

@ -13,6 +13,7 @@ static var Instance: Player;
@onready var animationtree: AnimationTree = $CollisionShape3D/Camera3D/Weapon/AnimationPlayer/AnimationTree
@onready var collisionShape: CollisionShape3D = $CollisionShape3D
@onready var health: Health = $Health
@onready var enemyTarget: Node3D = $"Enemy Target"
const CROUCHED_SPEED: float = 2.5
const SPEED: float = 5.0
@ -28,6 +29,7 @@ var gravity: float = ProjectSettings.get_setting("physics/3d/default_gravity")
func _ready() -> void:
Instance = self
health.damaged.connect(self.damaged)
func _physics_process(delta: float) -> void:
# Add the gravity.
@ -79,7 +81,7 @@ func _physics_process(delta: float) -> void:
lastDirection.y = move_toward(lastDirection.y, input_dir.y, 0.05);
var yLeft = clamp(lastDirection.y - 1, 0, 1);
animationtree.set('parameters/Movement/blend_position', yLeft)
var yRemainder = Vector2(lastDirection.x, clamp(lastDirection.y, 0, 1));
var yRemainder = Vector2(lastDirection.x, clamp(lastDirection.y, -1, 1));
animationtree.set(blendProperty, yRemainder);
func handleCrouching():
@ -91,3 +93,6 @@ func handleCrouching():
self.PlayerState = PlayerStates.STANDING
(collisionShape.shape as CylinderShape3D).height = 2
self.animationtree['parameters/playback'].travel('Movement')
func damaged():
print("Damage")

View file

@ -49,7 +49,7 @@ func fireBullet() -> void:
print('No result')
return
var health = result.collider.get_node('Health')
var health = result.collider.get_node_or_null('Health')
if health:
print("Dealing Damage")
result.collider.health.take_damage(1, Vector2(0,0))