Collision of zombie body parts completed and different damage added depending on the body part hit

This commit is contained in:
Morph01
2024-08-22 16:15:54 +02:00
parent d88cb9fbff
commit 1f52eb2c52
12 changed files with 467 additions and 124 deletions

View File

@@ -3771,6 +3771,6 @@ callback_mode_process = 0
tree_root = SubResource("AnimationNodeBlendTree_dptuf")
anim_player = NodePath("../AnimationPlayer")
parameters/ground_air_transition/current_state = "air"
parameters/ground_air_transition/transition_request = ""
parameters/ground_air_transition/transition_request = "air"
parameters/ground_air_transition/current_index = 1
parameters/iwr_blend/blend_amount = -1.0

View File

@@ -1,4 +1,4 @@
[gd_scene load_steps=27 format=3 uid="uid://bjuf33f7oteit"]
[gd_scene load_steps=39 format=3 uid="uid://bjuf33f7oteit"]
[ext_resource type="Texture2D" uid="uid://yrlrk74j3no" path="res://Assets/Models/Characters/zombie_mremireh_body__diffuse.png" id="1_xkx2p"]
[ext_resource type="Texture2D" uid="uid://byrx1euloda3v" path="res://Assets/Models/Characters/zombie_mremireh_body_normal.png" id="2_0tyam"]
@@ -245,21 +245,67 @@ _surfaces = [{
}]
blend_shape_mode = 0
[sub_resource type="CapsuleShape3D" id="CapsuleShape3D_6sdfw"]
radius = 21.018
height = 85.546
[sub_resource type="SphereShape3D" id="SphereShape3D_7uivi"]
radius = 28.0
[sub_resource type="CapsuleShape3D" id="CapsuleShape3D_06hh8"]
radius = 29.2405
height = 64.041
[sub_resource type="CapsuleShape3D" id="CapsuleShape3D_cwf3y"]
radius = 5.649
height = 18.308
[sub_resource type="CapsuleShape3D" id="CapsuleShape3D_t3iic"]
radius = 13.38
height = 64.798
[sub_resource type="CapsuleShape3D" id="CapsuleShape3D_rby1r"]
radius = 13.059
height = 64.718
[sub_resource type="CapsuleShape3D" id="CapsuleShape3D_60q35"]
radius = 10.165
height = 63.798
[sub_resource type="BoxShape3D" id="BoxShape3D_h2c2r"]
size = Vector3(35.13, 13.335, 23.31)
[sub_resource type="CapsuleShape3D" id="CapsuleShape3D_lg4i2"]
radius = 4.64
height = 30.995
[sub_resource type="CapsuleShape3D" id="CapsuleShape3D_hdo3x"]
radius = 6.475
height = 43.158
[sub_resource type="CapsuleShape3D" id="CapsuleShape3D_gdijl"]
radius = 8.32
height = 44.004
[sub_resource type="CapsuleShape3D" id="CapsuleShape3D_fi3w5"]
radius = 4.64
height = 30.995
[sub_resource type="CapsuleShape3D" id="CapsuleShape3D_n3g5u"]
radius = 5.95
height = 43.158
[sub_resource type="CapsuleShape3D" id="CapsuleShape3D_8hssk"]
radius = 6.845
height = 44.004
[sub_resource type="CapsuleShape3D" id="CapsuleShape3D_i68vj"]
radius = 9.5
height = 47.85
[sub_resource type="CapsuleShape3D" id="CapsuleShape3D_usp42"]
radius = 9.5
height = 47.85
[sub_resource type="CapsuleShape3D" id="CapsuleShape3D_qs6hq"]
radius = 7.92
height = 66.975
[sub_resource type="CapsuleShape3D" id="CapsuleShape3D_8npuj"]
radius = 7.92
height = 66.975
[sub_resource type="CapsuleShape3D" id="CapsuleShape3D_bnuqi"]
radius = 11.465
height = 58.23
[sub_resource type="CapsuleShape3D" id="CapsuleShape3D_kifmm"]
radius = 11.465
height = 58.23
[sub_resource type="Animation" id="Animation_miu52"]
resource_name = "Attack"
@@ -2327,50 +2373,50 @@ transitions = ["Run", "Attack", SubResource("AnimationNodeStateMachineTransition
[node name="zombie" type="Zombie"]
[node name="Armature" type="Node3D" parent="."]
transform = Transform3D(-0.01, -8.74228e-10, 3.82137e-17, 0, -4.37114e-10, -0.01, 8.74228e-10, -0.01, 4.37114e-10, 0, -0.317449, 0)
transform = Transform3D(-0.01, -8.74228e-10, 3.82137e-17, 0, -4.37114e-10, -0.01, 8.74228e-10, -0.01, 4.37114e-10, 0, -0.119675, 0)
[node name="Skeleton3D" type="Skeleton3D" parent="Armature"]
bones/0/name = "mixamorig_Hips"
bones/0/parent = -1
bones/0/rest = Transform3D(1, -1.64104e-06, -1.23603e-07, 1.23603e-07, 0, 1, -1.64104e-06, -1, 0, -0.0301997, 0.410377, -103.255)
bones/0/enabled = true
bones/0/position = Vector3(-21.0628, 118.124, -12.4199)
bones/0/rotation = Quaternion(0.0218933, -0.115578, 0.0972942, 0.988279)
bones/0/position = Vector3(-19.7461, 115.531, -13.8753)
bones/0/rotation = Quaternion(-0.188683, -0.120618, 0.114478, 0.967856)
bones/0/scale = Vector3(1, 1, 1)
bones/1/name = "mixamorig_Spine"
bones/1/parent = 0
bones/1/rest = Transform3D(1, 1.64209e-06, 1.08946e-07, -1.64105e-06, 0.99996, -0.0089287, -1.23603e-07, 0.0089287, 0.99996, -0.0024263, 12.7776, 0.315252)
bones/1/enabled = true
bones/1/position = Vector3(-0.0024263, 12.7776, 0.315252)
bones/1/rotation = Quaternion(0.0325627, 0.018889, 0.104853, 0.993775)
bones/1/rotation = Quaternion(0.013372, 0.0120796, 0.0624889, 0.997883)
bones/1/scale = Vector3(1, 1, 1)
bones/2/name = "mixamorig_Spine1"
bones/2/parent = 1
bones/2/rest = Transform3D(1, -8.12885e-12, -3.90108e-14, 8.12895e-12, 0.999989, 0.0046898, 8.87653e-16, -0.0046898, 0.999989, 2.71058e-09, 8.79264, 1.49012e-07)
bones/2/enabled = true
bones/2/position = Vector3(2.71058e-09, 8.79264, 1.49012e-07)
bones/2/rotation = Quaternion(0.00429218, 0.00868345, 0.0144037, 0.999849)
bones/2/rotation = Quaternion(-0.00753373, 0.0119026, 0.0123136, 0.999825)
bones/2/scale = Vector3(1, 1, 1)
bones/3/name = "mixamorig_Spine2"
bones/3/parent = 2
bones/3/rest = Transform3D(1, -3.75935e-18, -2.14464e-21, 3.75932e-18, 0.999991, 0.00423897, -1.37911e-20, -0.00423897, 0.999991, 2.498e-16, 8.65112, -5.96046e-08)
bones/3/enabled = true
bones/3/position = Vector3(2.498e-16, 8.65112, -5.96046e-08)
bones/3/rotation = Quaternion(0.00546575, 0.00783817, 0.0140679, 0.999855)
bones/3/rotation = Quaternion(-0.00630425, 0.0130548, 0.0117033, 0.999826)
bones/3/scale = Vector3(1, 1, 1)
bones/4/name = "mixamorig_Neck"
bones/4/parent = 3
bones/4/rest = Transform3D(1, -6.70873e-21, -7.44903e-23, 6.70874e-21, 1, 1.98848e-08, 7.44902e-23, -1.98848e-08, 1, -3.72529e-09, 21.2425, -0.842534)
bones/4/enabled = true
bones/4/position = Vector3(-3.72529e-09, 21.2425, -0.842534)
bones/4/rotation = Quaternion(0.0490221, -0.0837083, 0.0119374, 0.995212)
bones/4/rotation = Quaternion(-0.0576141, 0.0128626, -0.0446939, 0.997255)
bones/4/scale = Vector3(1, 1, 1)
bones/5/name = "mixamorig_Head"
bones/5/parent = 4
bones/5/rest = Transform3D(1, -6.68473e-21, 3.2708e-23, 6.68473e-21, 1, 0, -3.2708e-23, 0, 1, 4.28824e-15, 20.4181, 4.8338)
bones/5/enabled = true
bones/5/position = Vector3(4.28824e-15, 20.4181, 4.8338)
bones/5/rotation = Quaternion(-0.00611666, -0.444544, 0.132006, 0.885956)
bones/5/rotation = Quaternion(-0.284022, 0.0347652, -0.00104218, 0.958187)
bones/5/scale = Vector3(1, 1, 1)
bones/6/name = "mixamorig_HeadTop_End"
bones/6/parent = 5
@@ -2398,49 +2444,49 @@ bones/9/parent = 3
bones/9/rest = Transform3D(-0.0117089, 0.982404, -0.1864, 0.00222149, -0.186386, -0.982474, -0.999929, -0.0119177, 0, 6.57015, 17.5956, -2.76176)
bones/9/enabled = true
bones/9/position = Vector3(6.57023, 17.5956, -2.76177)
bones/9/rotation = Quaternion(-0.582228, -0.429761, 0.543818, -0.424945)
bones/9/rotation = Quaternion(-0.555954, -0.436216, 0.579537, -0.405915)
bones/9/scale = Vector3(1, 1, 1)
bones/10/name = "mixamorig_LeftArm"
bones/10/parent = 9
bones/10/rest = Transform3D(0.999929, -0.011709, -0.00222139, 0.0119178, 0.982404, 0.186385, -8.03266e-08, -0.186399, 0.982474, -4.47035e-08, 12.1385, 5.01977e-06)
bones/10/enabled = true
bones/10/position = Vector3(4.70413e-06, 12.1385, -3.28595e-05)
bones/10/rotation = Quaternion(-0.0315218, -0.502754, -0.118988, 0.855621)
bones/10/rotation = Quaternion(0.269987, -0.00897437, -0.07842, 0.959623)
bones/10/scale = Vector3(1, 1, 1)
bones/11/name = "mixamorig_LeftForeArm"
bones/11/parent = 10
bones/11/rest = Transform3D(1, 9.44764e-09, -8.19156e-09, -9.44763e-09, 1, 8.04663e-07, 8.19157e-09, -8.04663e-07, 1, 1.05432e-07, 18.4696, 1.60245e-05)
bones/11/enabled = true
bones/11/position = Vector3(-2.09953e-05, 18.4696, 1.20081e-05)
bones/11/rotation = Quaternion(-3.83984e-07, 1.06433e-07, 0.245779, 0.969326)
bones/11/rotation = Quaternion(-3.49033e-07, 2.91946e-07, 0.742396, 0.669962)
bones/11/scale = Vector3(1, 1, 1)
bones/12/name = "mixamorig_LeftHand"
bones/12/parent = 11
bones/12/rest = Transform3D(1, -8.07957e-09, 8.07957e-09, 8.07957e-09, 1, -5.6028e-14, -8.07957e-09, 5.60933e-14, 1, 2.0646e-07, 29.5088, 1.52078e-05)
bones/12/enabled = true
bones/12/position = Vector3(-1.12085e-05, 29.5088, -1.80238e-06)
bones/12/rotation = Quaternion(-0.188172, -0.429154, -0.104744, 0.877181)
bones/12/rotation = Quaternion(-0.584077, -0.0223393, -0.00132725, 0.81139)
bones/12/scale = Vector3(1, 1, 1)
bones/13/name = "mixamorig_LeftHandThumb1"
bones/13/parent = 12
bones/13/rest = Transform3D(0.859298, -0.448859, 0.245218, 0.510972, 0.774612, -0.372671, -0.0226725, 0.445535, 0.894977, -9.22388, 10.7665, 2.38609)
bones/13/enabled = true
bones/13/position = Vector3(-9.22385, 10.7665, 2.38621)
bones/13/rotation = Quaternion(0.167938, 0.066985, 0.222178, 0.958096)
bones/13/rotation = Quaternion(0.16794, 0.0669929, 0.222232, 0.958082)
bones/13/scale = Vector3(1, 1, 1)
bones/14/name = "mixamorig_LeftHandThumb2"
bones/14/parent = 13
bones/14/rest = Transform3D(1, -7.42262e-07, 1.21445e-06, 7.42266e-07, 1, -2.8573e-06, -1.21444e-06, 2.8573e-06, 1, -1.43051e-06, 6.33226, 1.07288e-05)
bones/14/enabled = true
bones/14/position = Vector3(-1.31428e-05, 6.33228, -1.54967e-06)
bones/14/rotation = Quaternion(0.0117143, -1.32336e-05, -0.0769527, 0.996966)
bones/14/rotation = Quaternion(0.00662792, -0.000681845, -0.0757287, 0.997106)
bones/14/scale = Vector3(1, 1, 1)
bones/15/name = "mixamorig_LeftHandThumb3"
bones/15/parent = 14
bones/15/rest = Transform3D(1, 1.06543e-06, -1.90269e-06, -1.06543e-06, 1, 5.96057e-08, 1.90269e-06, -5.96036e-08, 1, -1.19209e-06, 5.98994, -1.12057e-05)
bones/15/enabled = true
bones/15/position = Vector3(1.39474e-05, 5.98993, -1.37087e-06)
bones/15/rotation = Quaternion(-0.0210812, -7.80055e-06, -0.0160719, 0.999649)
bones/15/rotation = Quaternion(-0.023582, -0.000584667, -0.0154664, 0.999602)
bones/15/scale = Vector3(1, 1, 1)
bones/16/name = "mixamorig_LeftHandThumb4"
bones/16/parent = 15
@@ -2454,14 +2500,14 @@ bones/17/parent = 12
bones/17/rest = Transform3D(1, -1.40998e-06, -1.3975e-07, 1.40998e-06, 1, 5.20607e-06, 1.39742e-07, -5.20607e-06, 1, -6.40379, 26.4943, -0.17099)
bones/17/enabled = true
bones/17/position = Vector3(-6.4038, 26.4943, -0.171011)
bones/17/rotation = Quaternion(0.000615164, -1.64396e-07, -6.43586e-05, 1)
bones/17/rotation = Quaternion(0.000437309, -1.38198e-07, -4.29047e-05, 1)
bones/17/scale = Vector3(1, 1, 1)
bones/18/name = "mixamorig_LeftHandIndex2"
bones/18/parent = 17
bones/18/rest = Transform3D(1, -5.7191e-08, 5.71908e-08, 5.71911e-08, 1, -2.17708e-06, -5.71907e-08, 2.17708e-06, 1, 5.78031e-07, 8.79287, 1.14833e-05)
bones/18/enabled = true
bones/18/position = Vector3(1.37331e-05, 8.79288, -1.65009e-05)
bones/18/rotation = Quaternion(5.5406e-05, 7.71484e-08, -6.62781e-06, 1)
bones/18/rotation = Quaternion(0.000114979, 1.01499e-07, -1.38514e-05, 1)
bones/18/scale = Vector3(1, 1, 1)
bones/19/name = "mixamorig_LeftHandIndex3"
bones/19/parent = 18
@@ -2475,14 +2521,14 @@ bones/20/parent = 12
bones/20/rest = Transform3D(1, -2.53799e-07, -1.03828e-07, 2.53798e-07, 1, -4.87293e-06, 1.03829e-07, 4.87293e-06, 1, 0.00151853, 25.7911, 0.0166931)
bones/20/enabled = true
bones/20/position = Vector3(0.00149734, 25.7911, 0.0166703)
bones/20/rotation = Quaternion(0.000475565, -1.46651e-07, -4.72496e-05, 1)
bones/20/rotation = Quaternion(0.000297683, -1.10318e-07, -2.58771e-05, 1)
bones/20/scale = Vector3(1, 1, 1)
bones/21/name = "mixamorig_LeftHandMiddle2"
bones/21/parent = 20
bones/21/rest = Transform3D(1, -2.4022e-06, 1.80303e-08, 2.4022e-06, 1, -7.93205e-07, -1.80284e-08, 7.93205e-07, 1, -1.08228e-07, 9.394, -7.18399e-06)
bones/21/enabled = true
bones/21/position = Vector3(5.40327e-06, 9.39401, 1.20456e-05)
bones/21/rotation = Quaternion(0.000194673, 2.45103e-08, -2.3109e-05, 1)
bones/21/rotation = Quaternion(0.000254265, 2.29474e-08, -3.02958e-05, 1)
bones/21/scale = Vector3(1, 1, 1)
bones/22/name = "mixamorig_LeftHandMiddle3"
bones/22/parent = 21
@@ -2496,14 +2542,14 @@ bones/23/parent = 12
bones/23/rest = Transform3D(1, -1.82739e-06, -1.99177e-07, 1.82739e-06, 1, 4.87304e-06, 1.99168e-07, -4.87304e-06, 1, 6.22733, 24.6876, -0.127838)
bones/23/enabled = true
bones/23/position = Vector3(6.22732, 24.6876, -0.127856)
bones/23/rotation = Quaternion(0.00061533, -1.96357e-07, -6.41419e-05, 1)
bones/23/rotation = Quaternion(0.000437477, -1.68912e-07, -4.27081e-05, 1)
bones/23/scale = Vector3(1, 1, 1)
bones/24/name = "mixamorig_LeftHandRing2"
bones/24/parent = 23
bones/24/rest = Transform3D(1, -1.24633e-06, 1.73458e-07, 1.24633e-06, 1, -1.10205e-05, -1.73444e-07, 1.10205e-05, 1, 5.22701e-07, 9.3938, -2.21515e-07)
bones/24/enabled = true
bones/24/position = Vector3(5.22701e-07, 9.3938, -2.21515e-07)
bones/24/rotation = Quaternion(5.4886e-05, 1.24522e-07, -6.93144e-06, 1)
bones/24/rotation = Quaternion(0.000114461, 1.5538e-07, -1.41474e-05, 1)
bones/24/scale = Vector3(1, 1, 1)
bones/25/name = "mixamorig_LeftHandRing3"
bones/25/parent = 24
@@ -2517,14 +2563,14 @@ bones/26/parent = 12
bones/26/rest = Transform3D(1, -1.81111e-06, -2.15452e-07, 1.81111e-06, 1, 1.81111e-06, 2.15449e-07, -1.81111e-06, 1, 12.817, 23.682, -0.108689)
bones/26/enabled = true
bones/26/position = Vector3(12.817, 23.682, -0.108709)
bones/26/rotation = Quaternion(-0.00383334, 2.18464e-05, -0.0354375, 0.999365)
bones/26/rotation = Quaternion(-0.00401116, 1.55076e-05, -0.0354161, 0.999365)
bones/26/scale = Vector3(1, 1, 1)
bones/27/name = "mixamorig_LeftHandPinky2"
bones/27/parent = 26
bones/27/rest = Transform3D(1, 5.23462e-07, 3.11004e-07, -5.23463e-07, 1, 1.93477e-06, -3.11003e-07, -1.93477e-06, 1, 5.19565e-07, 8.42511, -8.07793e-06)
bones/27/enabled = true
bones/27/position = Vector3(-1.25561e-05, 8.42512, -4.09331e-06)
bones/27/rotation = Quaternion(0.00450318, 2.11213e-06, 0.0353666, 0.999364)
bones/27/rotation = Quaternion(0.00456275, 4.25075e-06, 0.0353594, 0.999364)
bones/27/scale = Vector3(1, 1, 1)
bones/28/name = "mixamorig_LeftHandPinky3"
bones/28/parent = 27
@@ -2538,49 +2584,49 @@ bones/29/parent = 3
bones/29/rest = Transform3D(-0.0117083, -0.982396, 0.186444, -0.00222197, -0.186431, -0.982465, 0.999929, -0.0119172, -1.19209e-07, -6.57016, 17.5959, -2.76177)
bones/29/enabled = true
bones/29/position = Vector3(-6.57023, 17.5958, -2.76177)
bones/29/rotation = Quaternion(0.474124, -0.515141, 0.530316, 0.478123)
bones/29/rotation = Quaternion(0.402301, -0.571848, 0.47604, 0.533414)
bones/29/scale = Vector3(1, 1, 1)
bones/30/name = "mixamorig_RightArm"
bones/30/parent = 29
bones/30/rest = Transform3D(0.999929, 0.0117084, 0.00222177, -0.0119174, 0.982396, 0.186427, 1.14669e-07, -0.186441, 0.982466, 2.98023e-08, 12.1386, 1.29775e-05)
bones/30/enabled = true
bones/30/position = Vector3(1.88144e-06, 12.1386, 2.57062e-05)
bones/30/rotation = Quaternion(0.593417, -0.219121, 0.132293, 0.763113)
bones/30/rotation = Quaternion(0.561226, -0.198627, -0.110937, 0.79578)
bones/30/scale = Vector3(1, 1, 1)
bones/31/name = "mixamorig_RightForeArm"
bones/31/parent = 30
bones/31/rest = Transform3D(1, 2.20824e-09, -1.29789e-09, -2.20823e-09, 1, 4.64471e-06, 1.2979e-09, -4.64471e-06, 1, -2.66512e-07, 18.4696, -1.55792e-05)
bones/31/enabled = true
bones/31/position = Vector3(-6.25607e-06, 18.4696, -3.97924e-06)
bones/31/rotation = Quaternion(-1.44008e-06, -1.7512e-06, -0.775136, 0.631794)
bones/31/rotation = Quaternion(-1.85358e-06, -1.53653e-06, -0.636183, 0.771538)
bones/31/scale = Vector3(1, 1, 1)
bones/32/name = "mixamorig_RightHand"
bones/32/parent = 31
bones/32/rest = Transform3D(1, 3.41881e-08, -3.41881e-08, -3.41882e-08, 1, -1.15386e-06, 3.41881e-08, 1.15386e-06, 1, 1.73907e-07, 29.5089, 3.67749e-06)
bones/32/enabled = true
bones/32/position = Vector3(8.60867e-06, 29.5089, -7.78946e-06)
bones/32/rotation = Quaternion(-0.692315, 0.0108468, -0.144859, 0.706823)
bones/32/rotation = Quaternion(-0.702058, -0.101158, -0.085934, 0.699641)
bones/32/scale = Vector3(1, 1, 1)
bones/33/name = "mixamorig_RightHandThumb1"
bones/33/parent = 32
bones/33/rest = Transform3D(0.860766, 0.448862, -0.240009, -0.508707, 0.774631, -0.375718, 0.0172729, 0.4455, 0.895115, 9.22384, 10.7664, 2.38598)
bones/33/enabled = true
bones/33/position = Vector3(9.22384, 10.7664, 2.38598)
bones/33/rotation = Quaternion(0.16473, -0.0624911, -0.222778, 0.958816)
bones/33/rotation = Quaternion(0.157513, -0.0658959, -0.21974, 0.960501)
bones/33/scale = Vector3(1, 1, 1)
bones/34/name = "mixamorig_RightHandThumb2"
bones/34/parent = 33
bones/34/rest = Transform3D(1, 9.78185e-07, 1.58414e-06, -9.78058e-07, 1, -7.96765e-05, -1.58422e-06, 7.96765e-05, 1, 8.13007e-05, 6.33229, 0.000127316)
bones/34/enabled = true
bones/34/position = Vector3(-1.04609e-05, 6.33219, 3.09219e-06)
bones/34/rotation = Quaternion(-0.124418, 0.0151862, 0.1029, 0.986763)
bones/34/rotation = Quaternion(-0.162286, 0.0191156, 0.0749297, 0.983709)
bones/34/scale = Vector3(1, 1, 1)
bones/35/name = "mixamorig_RightHandThumb3"
bones/35/parent = 34
bones/35/rest = Transform3D(1, 1.58742e-05, -4.17779e-07, -1.58742e-05, 1, -1.017e-05, 4.17617e-07, 1.017e-05, 1, -9.10759e-05, 5.99004, -5.31673e-05)
bones/35/enabled = true
bones/35/position = Vector3(-2.104e-05, 5.99006, 8.10656e-06)
bones/35/rotation = Quaternion(-0.0918432, 0.0129217, 0.0116887, 0.995621)
bones/35/rotation = Quaternion(-0.110777, 0.0175316, -0.000752621, 0.99369)
bones/35/scale = Vector3(1, 1, 1)
bones/36/name = "mixamorig_RightHandThumb4"
bones/36/parent = 35
@@ -2594,14 +2640,14 @@ bones/37/parent = 32
bones/37/rest = Transform3D(1, 1.19311e-06, 6.31644e-08, -1.19311e-06, 1, 6.37229e-07, -6.31636e-08, -6.37229e-07, 1, 6.40379, 26.4943, -0.171003)
bones/37/enabled = true
bones/37/position = Vector3(6.40379, 26.4943, -0.171003)
bones/37/rotation = Quaternion(0.000805152, 4.15027e-08, 8.96382e-05, 1)
bones/37/rotation = Quaternion(-0.00693688, 3.72472e-08, -0.000853035, 0.999976)
bones/37/scale = Vector3(1, 1, 1)
bones/38/name = "mixamorig_RightHandIndex2"
bones/38/parent = 37
bones/38/rest = Transform3D(1, 7.46894e-08, 9.95477e-08, -7.46894e-08, 1, -4.63684e-10, -9.95477e-08, 4.63676e-10, 1, -1.26993e-07, 8.79249, -1.4677e-05)
bones/38/enabled = true
bones/38/position = Vector3(-1.28424e-05, 8.79251, -8.78218e-07)
bones/38/rotation = Quaternion(5.89851e-06, 4.64316e-08, 6.28334e-07, 1)
bones/38/rotation = Quaternion(1.22586e-05, 5.29006e-08, 1.39329e-06, 1)
bones/38/scale = Vector3(1, 1, 1)
bones/39/name = "mixamorig_RightHandIndex3"
bones/39/parent = 38
@@ -2615,14 +2661,14 @@ bones/40/parent = 32
bones/40/rest = Transform3D(1, -9.95149e-09, 9.94947e-09, 9.95148e-09, 1, 6.36698e-07, -9.94948e-09, -6.36698e-07, 1, -0.00152069, 25.7911, 0.0160086)
bones/40/enabled = true
bones/40/position = Vector3(-0.00151818, 25.7911, 0.0160007)
bones/40/rotation = Quaternion(0.000805153, 1.4506e-08, 8.93651e-05, 1)
bones/40/rotation = Quaternion(-0.00693688, 1.16431e-08, -0.000853327, 0.999976)
bones/40/scale = Vector3(1, 1, 1)
bones/41/name = "mixamorig_RightHandMiddle2"
bones/41/parent = 40
bones/41/rest = Transform3D(1, 1.85919e-06, 1.6737e-07, -1.85919e-06, 1, 6.7514e-11, -1.6737e-07, -6.78252e-11, 1, -2.76976e-07, 9.39372, -1.51631e-07)
bones/41/enabled = true
bones/41/position = Vector3(-2.76976e-07, 9.39372, -1.51631e-07)
bones/41/rotation = Quaternion(5.90052e-06, 7.92945e-08, 6.18316e-07, 1)
bones/41/rotation = Quaternion(1.22611e-05, 8.38709e-08, 1.38785e-06, 1)
bones/41/scale = Vector3(1, 1, 1)
bones/42/name = "mixamorig_RightHandMiddle3"
bones/42/parent = 41
@@ -2636,14 +2682,14 @@ bones/43/parent = 32
bones/43/rest = Transform3D(1, 2.13186e-06, 1.4306e-07, -2.13186e-06, 1, 6.36069e-07, -1.43059e-07, -6.3607e-07, 1, -6.22732, 24.6876, -0.128004)
bones/43/enabled = true
bones/43/position = Vector3(-6.22732, 24.6876, -0.128004)
bones/43/rotation = Quaternion(0.000805153, 8.04117e-08, 8.91697e-05, 1)
bones/43/rotation = Quaternion(-0.00693688, 8.06993e-08, -0.000853521, 0.999976)
bones/43/scale = Vector3(1, 1, 1)
bones/44/name = "mixamorig_RightHandRing2"
bones/44/parent = 43
bones/44/rest = Transform3D(1, 1.12419e-06, 5.79532e-08, -1.12419e-06, 1, 6.95668e-10, -5.79532e-08, -6.95734e-10, 1, 8.07033e-07, 9.3942, -1.75455e-06)
bones/44/enabled = true
bones/44/position = Vector3(8.07033e-07, 9.3942, -1.75455e-06)
bones/44/rotation = Quaternion(5.89617e-06, 2.91821e-08, 9.78356e-07, 1)
bones/44/rotation = Quaternion(1.22546e-05, 3.89901e-08, 1.75557e-06, 1)
bones/44/scale = Vector3(1, 1, 1)
bones/45/name = "mixamorig_RightHandRing3"
bones/45/parent = 44
@@ -2657,14 +2703,14 @@ bones/46/parent = 32
bones/46/rest = Transform3D(1, 6.47815e-15, 9.94947e-09, -1.28132e-14, 1, 6.36719e-07, -9.94947e-09, -6.36719e-07, 1, -12.817, 23.682, -0.109006)
bones/46/enabled = true
bones/46/position = Vector3(-12.817, 23.682, -0.109006)
bones/46/rotation = Quaternion(0.000805153, 1.4502e-08, 8.93564e-05, 1)
bones/46/rotation = Quaternion(-0.00693688, 1.16778e-08, -0.00085333, 0.999976)
bones/46/scale = Vector3(1, 1, 1)
bones/47/name = "mixamorig_RightHandPinky2"
bones/47/parent = 46
bones/47/rest = Transform3D(1, -9.9495e-09, 1.99446e-15, 9.9495e-09, 1, 4.67832e-11, -1.99492e-15, -4.67832e-11, 1, -6.22665e-08, 8.42509, -1.63054e-05)
bones/47/enabled = true
bones/47/position = Vector3(-8.14846e-07, 8.42511, -1.11513e-06)
bones/47/rotation = Quaternion(5.90162e-06, -4.50426e-09, 6.78176e-07, 1)
bones/47/rotation = Quaternion(1.22619e-05, 1.2102e-09, 1.44749e-06, 1)
bones/47/scale = Vector3(1, 1, 1)
bones/48/name = "mixamorig_RightHandPinky3"
bones/48/parent = 47
@@ -2678,28 +2724,28 @@ bones/49/parent = 0
bones/49/rest = Transform3D(-1, -1.61224e-06, 4.29343e-08, 1.60665e-06, -0.993503, 0.113804, -1.40823e-07, 0.113804, 0.993502, 11.3941, -6.1878, -0.41386)
bones/49/enabled = true
bones/49/position = Vector3(11.3941, -6.18783, -0.413817)
bones/49/rotation = Quaternion(0.408146, 0.151195, 0.900072, -0.0206657)
bones/49/rotation = Quaternion(0.158995, -0.15948, 0.972377, -0.0614046)
bones/49/scale = Vector3(1, 1, 0.999998)
bones/50/name = "mixamorig_LeftLeg"
bones/50/parent = 49
bones/50/rest = Transform3D(1, 6.94812e-08, -1.06469e-07, -4.11865e-08, 0.969334, 0.245744, 1.20279e-07, -0.245744, 0.969335, -3.44336e-07, 32.5338, 4.70383e-05)
bones/50/enabled = true
bones/50/position = Vector3(-3.43632e-06, 32.5338, 4.43263e-06)
bones/50/rotation = Quaternion(-0.226508, -0.198811, 0.127426, 0.94495)
bones/50/rotation = Quaternion(-0.213727, -0.186954, 0.0877828, 0.954811)
bones/50/scale = Vector3(1, 1, 1)
bones/51/name = "mixamorig_LeftFoot"
bones/51/parent = 50
bones/51/rest = Transform3D(0.977152, -0.211548, -0.0205252, 0.0806816, 0.458539, -0.885004, 0.196632, 0.863127, 0.465131, -1.98803e-07, 48.648, 1.91926e-07)
bones/51/enabled = true
bones/51/position = Vector3(-1.98803e-07, 48.648, 1.91926e-07)
bones/51/rotation = Quaternion(0.607916, -0.237733, 0.20714, 0.728707)
bones/51/rotation = Quaternion(0.644057, -0.179709, 0.143855, 0.729521)
bones/51/scale = Vector3(1, 1, 1)
bones/52/name = "mixamorig_LeftToeBase"
bones/52/parent = 51
bones/52/rest = Transform3D(0.994305, -0.00805927, -0.106271, -0.0542637, 0.819927, -0.569891, 0.091727, 0.572412, 0.81482, -2.03601e-05, 29, 1.81803e-05)
bones/52/enabled = true
bones/52/position = Vector3(-1.33779e-07, 29, -1.3077e-06)
bones/52/rotation = Quaternion(0.213664, 0.0268641, 0.0060122, 0.976519)
bones/52/rotation = Quaternion(0.383138, -0.564065, -0.189697, 0.706436)
bones/52/scale = Vector3(1, 1, 1)
bones/53/name = "mixamorig_LeftToe_End"
bones/53/parent = 52
@@ -2713,28 +2759,28 @@ bones/54/parent = 0
bones/54/rest = Transform3D(-1, -1.61224e-06, 4.29171e-08, 1.60665e-06, -0.993503, 0.113804, -1.40841e-07, 0.113804, 0.993502, -11.3941, -6.18776, -0.413858)
bones/54/enabled = true
bones/54/position = Vector3(-11.3941, -6.18779, -0.413815)
bones/54/rotation = Quaternion(-0.194731, 0.300978, 0.898943, 0.25178)
bones/54/rotation = Quaternion(-0.281128, 0.126173, 0.894204, 0.324727)
bones/54/scale = Vector3(1, 1, 0.999998)
bones/55/name = "mixamorig_RightLeg"
bones/55/parent = 54
bones/55/rest = Transform3D(1, 6.94846e-08, -1.06487e-07, -4.11853e-08, 0.969334, 0.245744, 1.20297e-07, -0.245744, 0.969335, -3.44467e-07, 32.5338, 5.8359e-05)
bones/55/enabled = true
bones/55/position = Vector3(9.66912e-06, 32.5338, 3.41562e-06)
bones/55/rotation = Quaternion(-0.479295, 0.0681544, -0.030738, 0.874464)
bones/55/rotation = Quaternion(-0.446112, 0.0406986, -0.0975596, 0.888712)
bones/55/scale = Vector3(1, 1, 1)
bones/56/name = "mixamorig_RightFoot"
bones/56/parent = 55
bones/56/rest = Transform3D(0.977152, 0.211549, 0.0205261, -0.0806797, 0.458533, -0.885007, -0.196634, 0.863131, 0.465124, 7.5487e-07, 48.6481, -4.9512e-06)
bones/56/enabled = true
bones/56/position = Vector3(7.5487e-07, 48.6481, -4.9512e-06)
bones/56/rotation = Quaternion(0.507878, 0.189076, 0.247287, 0.803218)
bones/56/rotation = Quaternion(0.52573, 0.165264, 0.263969, 0.791591)
bones/56/scale = Vector3(1, 1, 1)
bones/57/name = "mixamorig_RightToeBase"
bones/57/parent = 56
bones/57/rest = Transform3D(0.994304, 0.00805453, 0.106272, 0.0542684, 0.819927, -0.56989, -0.0917255, 0.572412, 0.81482, -6.79173e-06, 29, 9.25874e-06)
bones/57/enabled = true
bones/57/position = Vector3(2.46004e-06, 29, 8.76624e-06)
bones/57/rotation = Quaternion(0.640791, 0.221586, 0.0788362, 0.730802)
bones/57/rotation = Quaternion(0.627212, 0.149602, 0.0321091, 0.763671)
bones/57/scale = Vector3(1, 1, 1)
bones/58/name = "mixamorig_RightToe_End"
bones/58/parent = 57
@@ -2752,65 +2798,213 @@ skin = SubResource("Skin_igf26")
mesh = SubResource("ArrayMesh_kq2p3")
skin = SubResource("Skin_igf26")
[node name="Physical Bone mixamorig_Hips" type="PhysicalBone3D" parent="Armature/Skeleton3D"]
transform = Transform3D(-0.935613, -0.327257, 0.115515, -0.0425122, -0.220403, -0.974095, 0.345573, -0.917126, 0.192925, -39.9196, 130.432, -65.103)
collision_layer = 2
collision_mask = 2
joint_offset = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 1.01829, -51.9393, 24.3426)
body_offset = Transform3D(-0.820447, -0.56701, -0.0272594, 0.150176, -0.170489, -0.973509, 0.548558, -0.803883, 0.225749, -27.9511, 14.6898, -47.807)
bone_name = "mixamorig_Hips"
[node name="CollisionShape3D" type="CollisionShape3D" parent="Armature/Skeleton3D/Physical Bone mixamorig_Hips"]
transform = Transform3D(1, 3.72529e-08, -2.98023e-08, 0, -2.98023e-08, 1, 0, -1, 0, -1.14834, -2.90698, -8.45403)
shape = SubResource("CapsuleShape3D_6sdfw")
[node name="Physical Bone mixamorig_Head" type="PhysicalBone3D" parent="Armature/Skeleton3D"]
transform = Transform3D(0.612376, -0.468423, 0.635274, -0.440774, 0.465501, 0.765957, -0.655587, -0.750324, 0.078612, 12.2865, 21.0574, -25.0904)
collision_layer = 2
collision_mask = 2
joint_type = 1
joint_offset = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, -124.145, 88.7641, 84.1187)
body_offset = Transform3D(-0.619869, -0.693389, 0.365594, -0.687157, 0.705237, 0.172105, -0.377703, -0.144741, -0.912778, -46.159, -162.384, 42.7395)
[node name="Head" type="BoneAttachment3D" parent="Armature/Skeleton3D"]
transform = Transform3D(0.965503, -0.0897317, -0.244443, 0.258869, 0.432177, 0.863835, 0.0281294, -0.897313, 0.440497, -40.2212, 179.019, -41.5008)
bone_name = "mixamorig_Head"
joint_constraints/bias = 0.3
joint_constraints/damping = 1.0
joint_constraints/impulse_clamp = 0.0
bone_idx = 5
[node name="CollisionShape3D" type="CollisionShape3D" parent="Armature/Skeleton3D/Physical Bone mixamorig_Head"]
transform = Transform3D(1, -1.86265e-09, -7.45058e-09, 7.45058e-09, -1.49012e-08, 1, -9.31323e-10, -1, 0, -0.273333, -1.05025, 7.16187)
shape = SubResource("CapsuleShape3D_06hh8")
[node name="Physical Bone mixamorig_LeftLeg" type="PhysicalBone3D" parent="Armature/Skeleton3D"]
transform = Transform3D(-0.584484, -0.53304, 0.6112, 0.00999568, -0.757656, -0.651668, 0.811094, -0.374676, 0.448601, -56.685, 92.5312, -18.1053)
[node name="HeadArea3D" type="BoneCollisionShape" parent="Armature/Skeleton3D/Head" groups=["enemy"]]
collision_layer = 2
collision_mask = 2
joint_type = 1
joint_offset = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, -20.0972, -30.3403, 47.6736)
body_offset = Transform3D(0.956002, 0.137885, 0.258225, -0.271428, 0.747124, 0.605735, -0.109462, -0.649117, 0.752253, 11.0859, -11.6646, -57.7569)
[node name="CollisionShape3D" type="CollisionShape3D" parent="Armature/Skeleton3D/Head/HeadArea3D"]
transform = Transform3D(1, -1.11759e-08, 0, 0, 1, -1.49012e-08, 0, -5.96046e-08, 0.999999, 0.308067, 13.8295, 0.95359)
shape = SubResource("SphereShape3D_7uivi")
[node name="Neck" type="BoneAttachment3D" parent="Armature/Skeleton3D"]
transform = Transform3D(0.948329, -0.229281, -0.219321, 0.308634, 0.826936, 0.470023, 0.0735975, -0.513426, 0.854972, -34.4795, 159.862, -35.1504)
bone_name = "mixamorig_Neck"
bone_idx = 4
[node name="NeckArea3D" type="BoneCollisionShape" parent="Armature/Skeleton3D/Neck" groups=["enemy"]]
collision_layer = 2
collision_mask = 2
[node name="CollisionShape3D" type="CollisionShape3D" parent="Armature/Skeleton3D/Neck/NeckArea3D"]
transform = Transform3D(0.999999, 1.49012e-08, -7.45058e-08, 0, 0.999999, 2.98023e-08, -1.49012e-08, -8.9407e-08, 0.999999, -0.131804, 5.20842, 0.683441)
shape = SubResource("CapsuleShape3D_cwf3y")
[node name="Spine" type="BoneAttachment3D" parent="Armature/Skeleton3D"]
transform = Transform3D(0.9193, -0.319017, -0.230467, 0.383602, 0.857213, 0.343562, 0.0879577, -0.404244, 0.910412, -24.7228, 134.832, -22.0229)
bone_name = "mixamorig_Spine1"
bone_idx = 2
[node name="SpineArea3D" type="BoneCollisionShape" parent="Armature/Skeleton3D/Spine" groups=["enemy"]]
collision_layer = 2
collision_mask = 2
[node name="CollisionShape3D" type="CollisionShape3D" parent="Armature/Skeleton3D/Spine/SpineArea3D"]
transform = Transform3D(1, 1.06171e-07, -1.2666e-07, -9.49949e-08, 1, 8.9407e-08, 4.09782e-08, -5.96046e-08, 0.999999, -0.0514412, 0.943031, 1.10226)
shape = SubResource("CapsuleShape3D_rby1r")
[node name="Hips" type="BoneAttachment3D" parent="Armature/Skeleton3D"]
transform = Transform3D(0.944693, -0.176079, -0.276681, 0.267113, 0.902587, 0.33762, 0.190281, -0.392852, 0.8997, -19.7461, 115.531, -13.8753)
bone_name = "mixamorig_Hips"
bone_idx = 0
[node name="HipsArea3D" type="BoneCollisionShape" parent="Armature/Skeleton3D/Hips" groups=["enemy"]]
collision_layer = 2
collision_mask = 2
[node name="CollisionShape3D" type="CollisionShape3D" parent="Armature/Skeleton3D/Hips/HipsArea3D"]
transform = Transform3D(1, 8.56817e-08, -1.19209e-07, -8.28877e-08, 1, 7.45058e-08, 2.98023e-08, -5.58794e-08, 0.999999, 2.87244, 0.657021, 0.688314)
shape = SubResource("BoxShape3D_h2c2r")
[node name="LeftArm" type="BoneAttachment3D" parent="Armature/Skeleton3D"]
transform = Transform3D(0.00088034, 0.882415, -0.470472, -0.361928, -0.438296, -0.822742, -0.932205, 0.171001, 0.318985, -14.8489, 160.041, -33.5058)
bone_name = "mixamorig_LeftArm"
bone_idx = 10
[node name="LeftArmArea3D" type="BoneCollisionShape" parent="Armature/Skeleton3D/LeftArm" groups=["enemy"]]
collision_layer = 2
collision_mask = 2
[node name="CollisionShape3D" type="CollisionShape3D" parent="Armature/Skeleton3D/LeftArm/LeftArmArea3D"]
transform = Transform3D(1, -2.98023e-08, -1.43051e-06, -1.19209e-07, 1, -2.98023e-08, 0, 2.98023e-08, 1, 0.346855, 4.07666, 1.03796)
shape = SubResource("CapsuleShape3D_lg4i2")
[node name="LeftForearm" type="BoneAttachment3D" parent="Armature/Skeleton3D"]
transform = Transform3D(0.877695, -0.0911496, -0.470471, -0.398969, 0.404869, -0.822743, 0.265472, 0.90982, 0.318985, 1.44897, 151.946, -30.3475)
bone_name = "mixamorig_LeftForeArm"
bone_idx = 11
[node name="LeftForearmArea3D" type="BoneCollisionShape" parent="Armature/Skeleton3D/LeftForearm" groups=["enemy"]]
collision_layer = 2
collision_mask = 2
[node name="CollisionShape3D" type="CollisionShape3D" parent="Armature/Skeleton3D/LeftForearm/LeftForearmArea3D"]
transform = Transform3D(1, -1.49012e-08, -1.3113e-06, -1.2666e-07, 1, 1.2666e-07, 0, -2.98023e-08, 1, 0.691883, 6.33018, 0.901428)
shape = SubResource("CapsuleShape3D_hdo3x")
[node name="LeftHand" type="BoneAttachment3D" parent="Armature/Skeleton3D"]
transform = Transform3D(0.856849, 0.441734, -0.26586, -0.419978, 0.897128, 0.137043, 0.299047, -0.00577003, 0.954221, -1.24076, 163.893, -3.49978)
bone_name = "mixamorig_LeftHand"
bone_idx = 12
[node name="LeftHandArea3D" type="BoneCollisionShape" parent="Armature/Skeleton3D/LeftHand" groups=["enemy"]]
collision_layer = 2
collision_mask = 2
[node name="CollisionShape3D" type="CollisionShape3D" parent="Armature/Skeleton3D/LeftHand/LeftHandArea3D"]
transform = Transform3D(1, -8.9407e-08, -1.2368e-06, -1.19209e-07, 1, 7.82311e-07, 8.9407e-08, 6.14673e-08, 1, 3.50799, 22.7103, 0.184517)
shape = SubResource("CapsuleShape3D_gdijl")
[node name="RightArm" type="BoneAttachment3D" parent="Armature/Skeleton3D"]
transform = Transform3D(0.107186, -0.200778, 0.973755, 0.24374, -0.944204, -0.221515, 0.963899, 0.261087, -0.0522679, -50.2697, 150.638, -38.769)
bone_name = "mixamorig_RightArm"
bone_idx = 30
[node name="RightArmArea3D" type="BoneCollisionShape" parent="Armature/Skeleton3D/RightArm" groups=["enemy"]]
collision_layer = 2
collision_mask = 2
[node name="CollisionShape3D" type="CollisionShape3D" parent="Armature/Skeleton3D/RightArm/RightArmArea3D"]
transform = Transform3D(1, -2.98023e-08, -1.43051e-06, -1.19209e-07, 1, -2.98023e-08, 0, 2.98023e-08, 1, 0.346855, 4.07666, 1.03796)
shape = SubResource("CapsuleShape3D_fi3w5")
[node name="RightForearm" type="BoneAttachment3D" parent="Armature/Skeleton3D"]
transform = Transform3D(0.217528, 0.0669645, 0.973754, 0.973347, 0.0593633, -0.22152, -0.0726392, 0.995988, -0.0522666, -53.978, 133.199, -33.9468)
bone_name = "mixamorig_RightForeArm"
bone_idx = 31
[node name="RightForearmArea3D" type="BoneCollisionShape" parent="Armature/Skeleton3D/RightForearm" groups=["enemy"]]
collision_layer = 2
collision_mask = 2
[node name="CollisionShape3D" type="CollisionShape3D" parent="Armature/Skeleton3D/RightForearm/RightForearmArea3D"]
transform = Transform3D(0.999999, 2.38419e-07, -1.30385e-06, -8.9407e-08, 1, 2.5332e-07, 1.19209e-07, 5.96046e-08, 1, -0.424438, 17.0012, 1.36327)
shape = SubResource("CapsuleShape3D_n3g5u")
[node name="RightHand" type="BoneAttachment3D" parent="Armature/Skeleton3D"]
transform = Transform3D(0.466651, -0.882646, 0.0563324, 0.88226, 0.469026, 0.0403997, -0.0620799, 0.0308475, 0.997595, -52.002, 134.951, -4.55631)
bone_name = "mixamorig_RightHand"
bone_idx = 32
[node name="RightHandArea3D" type="BoneCollisionShape" parent="Armature/Skeleton3D/RightHand" groups=["enemy"]]
collision_layer = 2
collision_mask = 2
[node name="CollisionShape3D" type="CollisionShape3D" parent="Armature/Skeleton3D/RightHand/RightHandArea3D"]
transform = Transform3D(1, -8.9407e-08, -1.2368e-06, -1.19209e-07, 1, 7.82311e-07, 8.9407e-08, 6.14673e-08, 1, 3.50799, 22.7103, 0.184517)
shape = SubResource("CapsuleShape3D_8hssk")
[node name="LeftUpLeg" type="BoneAttachment3D" parent="Armature/Skeleton3D"]
transform = Transform3D(-0.939982, 0.321913, 0.11316, -0.307369, -0.942821, 0.128888, 0.148181, 0.0863708, 0.985179, -7.7781, 112.85, -9.64866)
bone_name = "mixamorig_LeftUpLeg"
bone_idx = 49
[node name="LeftUpLegArea3D" type="BoneCollisionShape" parent="Armature/Skeleton3D/LeftUpLeg" groups=["enemy"]]
collision_layer = 2
collision_mask = 2
[node name="CollisionShape3D" type="CollisionShape3D" parent="Armature/Skeleton3D/LeftUpLeg/LeftUpLegArea3D"]
transform = Transform3D(1, 9.49949e-08, -1.66008e-07, -3.11993e-08, 1, -2.98023e-08, 6.0536e-09, 5.96046e-08, 0.999999, 0.191536, 15.8868, -0.254265)
shape = SubResource("CapsuleShape3D_i68vj")
[node name="RightUpLeg" type="BoneAttachment3D" parent="Armature/Skeleton3D"]
transform = Transform3D(-0.524124, -0.49422, -0.69357, 0.09417, -0.843031, 0.529557, -0.84642, 0.21224, 0.488392, -29.3059, 106.763, -13.9848)
bone_name = "mixamorig_RightUpLeg"
bone_idx = 54
[node name="RightUpLegArea3D" type="BoneCollisionShape" parent="Armature/Skeleton3D/RightUpLeg" groups=["enemy"]]
collision_layer = 2
collision_mask = 2
[node name="CollisionShape3D" type="CollisionShape3D" parent="Armature/Skeleton3D/RightUpLeg/RightUpLegArea3D"]
transform = Transform3D(1, 9.49949e-08, -1.66008e-07, -3.11993e-08, 1, -2.98023e-08, 6.0536e-09, 5.96046e-08, 0.999999, 0.191536, 15.8868, -0.254265)
shape = SubResource("CapsuleShape3D_usp42")
[node name="LeftLeg" type="BoneAttachment3D" parent="Armature/Skeleton3D"]
transform = Transform3D(-0.743946, 0.320096, 0.586586, -0.473359, -0.872029, -0.124484, 0.471673, -0.370274, 0.800261, 2.69496, 82.1761, -6.83869)
bone_name = "mixamorig_LeftLeg"
joint_constraints/bias = 0.3
joint_constraints/damping = 1.0
joint_constraints/impulse_clamp = 0.0
bone_idx = 50
[node name="CollisionShape3D" type="CollisionShape3D" parent="Armature/Skeleton3D/Physical Bone mixamorig_LeftLeg"]
transform = Transform3D(1, 0, 0, 0, 0, 1, 0, -1, 0, 0, 0, 0)
shape = SubResource("CapsuleShape3D_t3iic")
[node name="Physical Bone mixamorig_RightLeg" type="PhysicalBone3D" parent="Armature/Skeleton3D"]
transform = Transform3D(-0.727292, 0.081987, 0.681101, -0.372987, -0.880318, -0.292667, 0.575754, -0.467055, 0.670813, -77.3196, 93.4405, -27.3206)
[node name="LeftLegArea3D" type="BoneCollisionShape" parent="Armature/Skeleton3D/LeftLeg" groups=["enemy"]]
collision_layer = 2
collision_mask = 2
joint_type = 1
joint_offset = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, -6.19504, 1.46457, 37.5698)
body_offset = Transform3D(-0.0922445, 0.0753763, -0.99264, -0.0106643, 0.996915, 0.0768258, 0.995462, 0.0174719, -0.0911348, 36.6114, -4.41245, 9.56525)
bone_name = "mixamorig_RightLeg"
joint_constraints/bias = 0.3
joint_constraints/damping = 1.0
joint_constraints/impulse_clamp = 0.0
[node name="CollisionShape3D" type="CollisionShape3D" parent="Armature/Skeleton3D/Physical Bone mixamorig_RightLeg"]
transform = Transform3D(1, 0, 0, 0, 0, 1, 0, -1, 0, 0, 0, 0)
shape = SubResource("CapsuleShape3D_60q35")
[node name="CollisionShape3D" type="CollisionShape3D" parent="Armature/Skeleton3D/LeftLeg/LeftLegArea3D"]
transform = Transform3D(1, 8.19564e-08, -1.19209e-07, -5.21541e-08, 1, -1.19209e-07, 1.49012e-07, 1.04308e-07, 0.999999, -0.731384, 28.043, -1.34705)
shape = SubResource("CapsuleShape3D_qs6hq")
[node name="RightLeg" type="BoneAttachment3D" parent="Armature/Skeleton3D"]
transform = Transform3D(-0.418964, 0.19551, -0.886704, 0.276651, -0.902627, -0.329739, -0.864831, -0.383456, 0.324079, -45.3848, 79.3357, -7.07985)
bone_name = "mixamorig_RightLeg"
bone_idx = 55
[node name="RightLegArea3D" type="BoneCollisionShape" parent="Armature/Skeleton3D/RightLeg" groups=["enemy"]]
collision_layer = 2
collision_mask = 2
[node name="CollisionShape3D" type="CollisionShape3D" parent="Armature/Skeleton3D/RightLeg/RightLegArea3D"]
transform = Transform3D(1, 8.19564e-08, -1.19209e-07, -5.21541e-08, 1, -1.19209e-07, 1.49012e-07, 1.04308e-07, 0.999999, -0.731384, 28.043, -1.34705)
shape = SubResource("CapsuleShape3D_8npuj")
[node name="LeftFoot" type="BoneAttachment3D" parent="Armature/Skeleton3D"]
transform = Transform3D(-0.409515, 0.89054, -0.198082, -0.460069, -0.0140963, 0.887772, 0.787802, 0.454686, 0.415481, 18.267, 39.7536, -24.8518)
bone_name = "mixamorig_LeftFoot"
bone_idx = 51
[node name="LeftFootArea3D" type="BoneCollisionShape" parent="Armature/Skeleton3D/LeftFoot" groups=["enemy"]]
collision_layer = 2
collision_mask = 2
[node name="CollisionShape3D" type="CollisionShape3D" parent="Armature/Skeleton3D/LeftFoot/LeftFootArea3D"]
transform = Transform3D(0.969109, 0.0418097, -0.243058, -0.174756, 0.811824, -0.557136, 0.174027, 0.582401, 0.794053, 0.736116, 19.3427, 1.8218)
shape = SubResource("CapsuleShape3D_bnuqi")
[node name="RightFoot" type="BoneAttachment3D" parent="Armature/Skeleton3D"]
transform = Transform3D(-0.236119, -0.652915, -0.719686, -0.316326, -0.648642, 0.692243, -0.918795, 0.391108, -0.0533792, -35.8736, 35.4246, -25.7342)
bone_name = "mixamorig_RightFoot"
bone_idx = 56
[node name="RightFootArea3D" type="BoneCollisionShape" parent="Armature/Skeleton3D/RightFoot" groups=["enemy"]]
collision_layer = 2
collision_mask = 2
[node name="CollisionShape3D" type="CollisionShape3D" parent="Armature/Skeleton3D/RightFoot/RightFootArea3D"]
transform = Transform3D(0.969109, 0.0418097, -0.243058, -0.174756, 0.811824, -0.557136, 0.174027, 0.582401, 0.794053, 0.736116, 19.3427, 1.8218)
shape = SubResource("CapsuleShape3D_kifmm")
[node name="AnimationPlayer" type="AnimationPlayer" parent="."]
deterministic = true

View File

@@ -77,6 +77,8 @@ mesh = SubResource("PlaneMesh_mmup0")
skeleton = NodePath("../../..")
[node name="StaticBody3D" type="StaticBody3D" parent="Map/NavigationRegion3D/Floor"]
collision_layer = 3
collision_mask = 3
[node name="CollisionShape3D" type="CollisionShape3D" parent="Map/NavigationRegion3D/Floor/StaticBody3D"]
shape = SubResource("ConcavePolygonShape3D_26ptr")
@@ -87,6 +89,8 @@ mesh = SubResource("BoxMesh_plpqy")
skeleton = NodePath("../../..")
[node name="StaticBody3D" type="StaticBody3D" parent="Map/NavigationRegion3D/Wall"]
collision_layer = 3
collision_mask = 3
[node name="CollisionShape3D" type="CollisionShape3D" parent="Map/NavigationRegion3D/Wall/StaticBody3D"]
shape = SubResource("ConcavePolygonShape3D_v7prx")
@@ -98,20 +102,14 @@ skeleton = NodePath("../../..")
surface_material_override/0 = SubResource("StandardMaterial3D_pfpgv")
[node name="StaticBody3D" type="StaticBody3D" parent="Map/NavigationRegion3D/Slope"]
collision_layer = 3
collision_mask = 3
[node name="CollisionShape3D" type="CollisionShape3D" parent="Map/NavigationRegion3D/Slope/StaticBody3D"]
shape = SubResource("ConcavePolygonShape3D_rit6o")
[node name="zombie" parent="Map" instance=ExtResource("5_4vmh3")]
m_PlayerPath = NodePath("../../FirstPersonPlayer")
transform = Transform3D(-0.98774, 0, -0.156107, 0, 1, 0, 0.156107, 0, -0.98774, 0, 0, 7.38477)
[node name="zombie2" parent="Map" instance=ExtResource("5_4vmh3")]
m_PlayerPath = NodePath("../../FirstPersonPlayer")
transform = Transform3D(-0.98774, 0, -0.156107, 0, 1, 0, 0.156107, 0, -0.98774, 8.0927, 0, 7.38477)
[node name="zombie3" parent="Map" instance=ExtResource("5_4vmh3")]
m_PlayerPath = NodePath("../../FirstPersonPlayer")
transform = Transform3D(-0.98774, 0, -0.156107, 0, 1, 0, 0.156107, 0, -0.98774, 14.3905, 0, -18.3684)
[node name="FirstPersonPlayer" parent="." instance=ExtResource("5_8ctht")]

View File

@@ -25,14 +25,17 @@ material = SubResource("StandardMaterial3D_gn2fy")
size = Vector3(0.04, 0.04, 0.04)
[node name="Bullet" type="Bullet"]
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, -52730.2)
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, -56304.6)
[node name="MeshInstance3D" type="MeshInstance3D" parent="."]
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, -0.6)
mesh = SubResource("BoxMesh_ibwn0")
surface_material_override/0 = SubResource("StandardMaterial3D_2qdhl")
[node name="RayCast3D" type="RayCast3D" parent="."]
target_position = Vector3(0, 0, -0.6)
collision_mask = 2
collide_with_areas = true
[node name="GPUParticles3D" type="GPUParticles3D" parent="."]
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, -0.7)

View File

@@ -32,5 +32,5 @@ libraries = {
}
[node name="RayCast3D" type="RayCast3D" parent="." index="2"]
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, -1.10108)
transform = Transform3D(1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, -0.6)
target_position = Vector3(0, 0, -1)

View File

@@ -0,0 +1,55 @@
#include "BoneCollisionShape.h"
using namespace godot;
namespace blitz {
void BoneCollisionShape::_bind_methods() {
ClassDB::bind_method(D_METHOD("get_head_damage"), &BoneCollisionShape::get_head_damage);
ClassDB::bind_method(D_METHOD("set_head_damage", "m_HeadDamage"), &BoneCollisionShape::set_head_damage);
ADD_PROPERTY(PropertyInfo(Variant::INT, "m_HeadDamage"), "set_head_damage", "get_head_damage");
ClassDB::bind_method(D_METHOD("get_body_damage"), &BoneCollisionShape::get_body_damage);
ClassDB::bind_method(D_METHOD("set_body_damage", "m_BodyDamage"), &BoneCollisionShape::set_body_damage);
ADD_PROPERTY(PropertyInfo(Variant::INT, "m_BodyDamage"), "set_head_damage", "get_body_damage");
ADD_SIGNAL(MethodInfo("a_ZombieHeadShotHit", PropertyInfo(Variant::INT, "dam")));
ADD_SIGNAL(MethodInfo("a_ZombieBodyShotHit", PropertyInfo(Variant::INT, "dam")));
ClassDB::bind_method(D_METHOD("headshot_hit"), &BoneCollisionShape::headshot_hit);
ClassDB::bind_method(D_METHOD("bodyshot_hit"), &BoneCollisionShape::bodyshot_hit);
}
BoneCollisionShape::BoneCollisionShape() {}
BoneCollisionShape::~BoneCollisionShape() {}
void BoneCollisionShape::_ready() {}
void BoneCollisionShape::set_head_damage(int a_D) {
m_HeadDamage = a_D;
}
int BoneCollisionShape::get_head_damage() const {
return m_HeadDamage;
}
void BoneCollisionShape::set_body_damage(int a_D) {
m_BodyDamage = a_D;
}
int BoneCollisionShape::get_body_damage() const {
return m_BodyDamage;
}
void BoneCollisionShape::headshot_hit() {
ERR_PRINT("zombie headshot hit");
emit_signal("a_ZombieHeadShotHit", m_HeadDamage);
}
void BoneCollisionShape::bodyshot_hit() {
ERR_PRINT("zombie body hit");
emit_signal("a_ZombieBodyShotHit", m_BodyDamage);
}
} // namespace blitz

30
src/BoneCollisionShape.h Normal file
View File

@@ -0,0 +1,30 @@
#pragma once
#include <godot_cpp/classes/area3d.hpp>
namespace blitz {
class BoneCollisionShape : public godot::Area3D {
GDCLASS(BoneCollisionShape, godot::Area3D)
protected:
static void _bind_methods();
public:
BoneCollisionShape();
~BoneCollisionShape();
void _ready();
void headshot_hit();
void bodyshot_hit();
private:
int m_HeadDamage = 2;
int m_BodyDamage = 1;
void set_head_damage(int d);
int get_head_damage() const;
void set_body_damage(int d);
int get_body_damage() const;
};
} // namespace blitz

View File

@@ -1,4 +1,5 @@
#include "Bullet.h"
#include "BoneCollisionShape.h"
using namespace godot;
@@ -33,6 +34,19 @@ void Bullet::_physics_process(float a_Delta) {
if (m_Ray->is_colliding()) {
m_Mesh->set_visible(false);
m_Particles->set_emitting(true);
m_Ray->set_enabled(false);
Object* collider = m_Ray->get_collider();
if (!collider)
return;
auto* area_collider = Object::cast_to<BoneCollisionShape>(collider);
if (!(area_collider && area_collider->is_in_group("enemy")))
return;
const StringName& area_name = area_collider->get_name();
area_collider->call(area_name.match("HeadArea3D") ? "headshot_hit" : "bodyshot_hit");
m_Timer->set_wait_time(1.0);
m_Timer->start();
}

View File

@@ -1,6 +1,7 @@
#include "World.h"
#include "FirstPersonPlayer.h"
#include <godot_cpp/variant/utility_functions.hpp>
#include <godot_cpp/classes/engine.hpp>
using namespace godot;
@@ -29,14 +30,19 @@ void World::_ready() {
}
void World::_on_first_person_player_hit() {
#if DEBUG_ENABLED
if (Engine::get_singleton()->is_editor_hint()) {
return;
}
#endif
UtilityFunctions::print("Player hit detected in World.");
m_RedRect->set_visible(true);
m_Timer->set_wait_time(0.2);
m_RedRect->set_visible(true);
m_Timer->set_wait_time(0.2);
m_Timer->start();
}
void World::_on_timer_timeout() {
m_RedRect->set_visible(false);
m_RedRect->set_visible(false);
}
} // namespace blitz

View File

@@ -14,6 +14,8 @@ void Zombie::_bind_methods() {
ClassDB::bind_method(D_METHOD("set_m_PlayerPath", "m_PlayerPath"), &Zombie::set_m_PlayerPath);
ClassDB::bind_method(D_METHOD("get_m_PlayerPath"), &Zombie::get_m_PlayerPath);
ClassDB::bind_method(D_METHOD("hit_finished"), &Zombie::hit_finished);
ClassDB::bind_method(D_METHOD("_on_area_3d_a_zombie_head_shot_hit", "m_Health"), &Zombie::_on_area_3d_a_zombie_head_shot_hit);
ClassDB::bind_method(D_METHOD("_on_area_3d_a_zombie_body_shot_hit", "m_Health"), &Zombie::_on_area_3d_a_zombie_body_shot_hit);
ADD_PROPERTY(PropertyInfo(Variant::NODE_PATH, "m_PlayerPath"), "set_m_PlayerPath", "get_m_PlayerPath");
}
@@ -38,6 +40,10 @@ void Zombie::_ready() {
m_StateMachine = Object::cast_to<AnimationNodeStateMachinePlayback>(m_AnimationTree->get("parameters/playback"));
DEV_ASSERT(m_StateMachine);
this->set_velocity(Vector3(0, 0, 0));
m_HeadCollision = Object::cast_to<BoneCollisionShape>(find_child("HeadArea3D"));
DEV_ASSERT(m_HeadCollision);
m_HeadCollision->connect("a_ZombieHeadShotHit", Callable(this, "_on_area_3d_a_zombie_head_shot_hit"));
connect_collision_shapes(m_BodyPartsCollision);
}
void Zombie::_process(float a_Delta) {
@@ -82,4 +88,29 @@ void Zombie::hit_finished() {
m_Player->hit(dir);
}
}
void Zombie::apply_damage(int dam) {
m_Health -= dam;
if (m_Health <= 0) {
queue_free();
}
}
void Zombie::_on_area_3d_a_zombie_head_shot_hit(int dam) {
apply_damage(dam);
}
void Zombie::_on_area_3d_a_zombie_body_shot_hit(int dam) {
apply_damage(dam);
}
void Zombie::connect_collision_shapes(const std::vector<StringName>& body_parts) {
for (const StringName& part : body_parts) {
StringName area_name = String(part) + "Area3D";
BoneCollisionShape* collision_shape = Object::cast_to<BoneCollisionShape>(find_child(area_name));
DEV_ASSERT(collision_shape);
collision_shape->connect("a_ZombieBodyShotHit", Callable(this, "_on_area_3d_a_zombie_body_shot_hit"));
}
}
} // namespace blitz

View File

@@ -1,11 +1,13 @@
#pragma once
#include "BoneCollisionShape.h"
#include "FirstPersonPlayer.h"
#include <godot_cpp/classes/animation_node_state_machine_playback.hpp>
#include <godot_cpp/classes/animation_tree.hpp>
#include <godot_cpp/classes/character_body3d.hpp>
#include <godot_cpp/classes/navigation_agent3d.hpp>
#include <godot_cpp/variant/node_path.hpp>
#include <godot_cpp/variant/string_name.hpp>
namespace blitz {
@@ -21,6 +23,8 @@ class Zombie : public godot::CharacterBody3D {
void _ready();
void _process(float delta);
bool _target_in_range();
void _on_area_3d_a_zombie_head_shot_hit(int dam);
void _on_area_3d_a_zombie_body_shot_hit(int dam);
private:
godot::NavigationAgent3D* m_NavigationAgent;
@@ -29,10 +33,16 @@ class Zombie : public godot::CharacterBody3D {
godot::Vector3 m_Velocity;
godot::AnimationTree* m_AnimationTree;
godot::AnimationNodeStateMachinePlayback* m_StateMachine;
BoneCollisionShape* m_HeadCollision;
std::vector<godot::StringName> m_BodyPartsCollision = {"Neck", "Spine", "Hips", "LeftArm", "LeftForearm", "LeftHand", "RightArm",
"RightForearm", "RightHand", "LeftUpLeg", "RightUpLeg", "LeftLeg", "RightLeg", "LeftFoot", "RightFoot"};
int m_Health = 6;
void set_m_PlayerPath(const godot::NodePath& path);
godot::NodePath get_m_PlayerPath() const;
void hit_finished();
void apply_damage(int dam);
void connect_collision_shapes(const std::vector<godot::StringName>& body_parts);
};
} // namespace blitz

View File

@@ -1,11 +1,12 @@
#include "register_types.h"
#include "BoneCollisionShape.h"
#include "Bullet.h"
#include "FirstPersonPlayer.h"
#include "Player.h"
#include "SpringArmPivot.h"
#include "Zombie.h"
#include "World.h"
#include "Zombie.h"
#include <gdextension_interface.h>
#include <godot_cpp/core/defs.hpp>
@@ -23,6 +24,7 @@ void initialize_example_module(ModuleInitializationLevel p_level) {
ClassDB::register_class<blitz::FirstPersonPlayer>();
ClassDB::register_class<blitz::Bullet>();
ClassDB::register_class<blitz::Zombie>();
ClassDB::register_class<blitz::BoneCollisionShape>();
ClassDB::register_class<blitz::World>();
}