Zombie tie

This commit is contained in:
Rendo 2025-07-12 04:15:10 +05:00
commit 32f1538b0d
6 changed files with 105 additions and 66 deletions

View file

@ -8,6 +8,11 @@
config_version=5
[animation]
warnings/check_invalid_track_paths=false
warnings/check_angle_interpolation_type_conflicting=false
[application]
config/name="Liberation of the Neighbourville"

View file

@ -43,55 +43,71 @@ mult_value = 1.0
[node name="CanvasGroup" parent="." index="0"]
material = SubResource("ShaderMaterial_wdi07")
[node name="Zombie" parent="CanvasGroup/basic_zombie_walk" index="0"]
use_parent_material = false
[node name="Butt" parent="CanvasGroup/basic_zombie_walk/Zombie" index="0"]
use_parent_material = false
scale = Vector2(0.999912, 0.999912)
[node name="Butt" parent="CanvasGroup/basic_zombie_walk/Zombie/Butt" index="0"]
use_parent_material = false
[node name="RightUpperLeg" parent="CanvasGroup/basic_zombie_walk/Zombie/Butt" index="1"]
scale = Vector2(0.999831, 0.999831)
use_parent_material = false
scale = Vector2(0.999837, 0.999837)
[node name="RightLowerLeg" parent="CanvasGroup/basic_zombie_walk/Zombie/Butt/RightUpperLeg" index="1"]
scale = Vector2(0.999833, 0.999833)
scale = Vector2(0.999834, 0.999834)
[node name="RightFoot" parent="CanvasGroup/basic_zombie_walk/Zombie/Butt/RightUpperLeg/RightLowerLeg" index="0"]
scale = Vector2(0.999833, 0.999833)
[node name="LeftUpperLeg" parent="CanvasGroup/basic_zombie_walk/Zombie/Butt" index="2"]
scale = Vector2(0.999834, 0.999834)
use_parent_material = false
scale = Vector2(0.999838, 0.999838)
[node name="LeftLowerLeg" parent="CanvasGroup/basic_zombie_walk/Zombie/Butt/LeftUpperLeg" index="1"]
scale = Vector2(0.999836, 0.999836)
scale = Vector2(0.999831, 0.999831)
[node name="LeftFoot" parent="CanvasGroup/basic_zombie_walk/Zombie/Butt/LeftUpperLeg/LeftLowerLeg" index="1"]
scale = Vector2(0.99983, 0.99983)
scale = Vector2(0.999831, 0.999831)
[node name="Body" parent="CanvasGroup/basic_zombie_walk/Zombie/Butt" index="3"]
scale = Vector2(0.99983, 0.99983)
[node name="RightUpperArm" parent="CanvasGroup/basic_zombie_walk/Zombie/Butt/Body" index="0"]
use_parent_material = false
scale = Vector2(0.999828, 0.999828)
[node name="RightUpperArm" parent="CanvasGroup/basic_zombie_walk/Zombie/Butt/Body" index="0"]
use_parent_material = false
scale = Vector2(0.99982, 0.99982)
[node name="RightLowerArm" parent="CanvasGroup/basic_zombie_walk/Zombie/Butt/Body/RightUpperArm" index="1"]
scale = Vector2(0.999829, 0.999829)
scale = Vector2(0.99983, 0.99983)
[node name="RightHand" parent="CanvasGroup/basic_zombie_walk/Zombie/Butt/Body/RightUpperArm/RightLowerArm" index="0"]
scale = Vector2(0.999829, 0.999829)
scale = Vector2(0.999823, 0.999823)
[node name="Tie" parent="CanvasGroup/basic_zombie_walk/Zombie/Butt/Body" index="2"]
rotation = 0.0307433
rotation = 0.0582635
scale = Vector2(1, 1)
skew = -0.000132799
[node name="Head" parent="CanvasGroup/basic_zombie_walk/Zombie/Butt/Body" index="3"]
scale = Vector2(0.999827, 0.999827)
scale = Vector2(0.999833, 0.999833)
[node name="Right_Eye" parent="CanvasGroup/basic_zombie_walk/Zombie/Butt/Body/Head/HeadParticle/Head" index="0"]
position = Vector2(-16, -8)
[node name="Left_Eye" parent="CanvasGroup/basic_zombie_walk/Zombie/Butt/Body/Head/HeadParticle/Head" index="1"]
position = Vector2(-4, -9)
[node name="Jaw" parent="CanvasGroup/basic_zombie_walk/Zombie/Butt/Body/Head/HeadParticle/Head" index="2"]
position = Vector2(-2.77911, 2.46402)
rotation = 0.0242566
scale = Vector2(0.999828, 0.999828)
position = Vector2(-3.00071, 2.99879)
rotation = 0.00565429
scale = Vector2(0.999831, 0.999831)
[node name="Jaw" parent="CanvasGroup/basic_zombie_walk/Zombie/Butt/Body/Head" index="1"]
scale = Vector2(0.999828, 0.999828)
scale = Vector2(0.999831, 0.999831)
[node name="Hat" parent="CanvasGroup/basic_zombie_walk/Zombie/Butt/Body/Head" index="4"]
position = Vector2(-6, -8)
@ -102,23 +118,23 @@ texture = ExtResource("3_0nlp0")
degradationStages = Array[Texture]([ExtResource("3_0nlp0"), ExtResource("4_xx7fu"), ExtResource("5_v1iwd")])
[node name="LeftUpperArm" parent="CanvasGroup/basic_zombie_walk/Zombie/Butt/Body" index="4"]
scale = Vector2(0.999829, 0.999829)
scale = Vector2(0.999831, 0.999831)
[node name="Left_Lower_Arm" parent="CanvasGroup/basic_zombie_walk/Zombie/Butt/Body/LeftUpperArm/HandProjectile" index="0"]
rotation = 0.124474
scale = Vector2(0.999997, 0.999997)
rotation = 0.0547805
scale = Vector2(1.00001, 1.00001)
[node name="Left_Hand" parent="CanvasGroup/basic_zombie_walk/Zombie/Butt/Body/LeftUpperArm/HandProjectile/Left_Lower_Arm" index="0"]
show_behind_parent = false
position = Vector2(-0.99983, 12.9978)
rotation = -0.103717
scale = Vector2(0.999656, 0.999656)
rotation = -0.0241767
scale = Vector2(0.999661, 0.999661)
[node name="LeftLowerArm" parent="CanvasGroup/basic_zombie_walk/Zombie/Butt/Body/LeftUpperArm" index="2"]
scale = Vector2(0.999828, 0.999828)
scale = Vector2(0.999835, 0.999835)
[node name="LeftHand" parent="CanvasGroup/basic_zombie_walk/Zombie/Butt/Body/LeftUpperArm/LeftLowerArm" index="0"]
scale = Vector2(0.999826, 0.999826)
scale = Vector2(0.999831, 0.999831)
[node name="Left_Hand" type="Sprite2D" parent="CanvasGroup/basic_zombie_walk/Zombie/Butt/Body/LeftUpperArm/LeftLowerArm/LeftHand" index="0"]
texture = SubResource("AtlasTexture_wfem3")
@ -137,7 +153,7 @@ _damage = SubResource("Resource_2bm8y")
[node name="Mover" parent="." index="4"]
_speed = SubResource("Resource_lt6ps")
_speedControlMult = 0.806369
_speedControlMult = 0.187967
[node name="Armor" parent="." index="6"]
MaxHP = 375.0

View file

@ -44,13 +44,13 @@ material = SubResource("ShaderMaterial_sat5k")
scale = Vector2(0.999833, 0.999833)
[node name="RightLowerLeg" parent="CanvasGroup/basic_zombie_walk/Zombie/Butt/RightUpperLeg" index="1"]
scale = Vector2(0.999833, 0.999833)
scale = Vector2(0.999834, 0.999834)
[node name="RightFoot" parent="CanvasGroup/basic_zombie_walk/Zombie/Butt/RightUpperLeg/RightLowerLeg" index="0"]
scale = Vector2(0.99983, 0.99983)
[node name="LeftUpperLeg" parent="CanvasGroup/basic_zombie_walk/Zombie/Butt" index="2"]
scale = Vector2(0.999834, 0.999834)
scale = Vector2(0.999835, 0.999835)
[node name="LeftLowerLeg" parent="CanvasGroup/basic_zombie_walk/Zombie/Butt/LeftUpperLeg" index="1"]
scale = Vector2(0.999833, 0.999833)
@ -59,7 +59,7 @@ scale = Vector2(0.999833, 0.999833)
scale = Vector2(0.999829, 0.999829)
[node name="Body" parent="CanvasGroup/basic_zombie_walk/Zombie/Butt" index="3"]
scale = Vector2(0.999829, 0.999829)
scale = Vector2(0.999828, 0.999828)
[node name="RightUpperArm" parent="CanvasGroup/basic_zombie_walk/Zombie/Butt/Body" index="0"]
scale = Vector2(0.999828, 0.999828)
@ -71,24 +71,19 @@ scale = Vector2(0.999827, 0.999827)
scale = Vector2(0.999828, 0.999828)
[node name="Tie" parent="CanvasGroup/basic_zombie_walk/Zombie/Butt/Body" index="2"]
rotation = -0.135116
scale = Vector2(1e-05, 1e-05)
skew = -9.46522e-05
rotation = -0.0474381
scale = Vector2(1, 1)
skew = -9.50098e-05
[node name="Head" parent="CanvasGroup/basic_zombie_walk/Zombie/Butt/Body" index="3"]
scale = Vector2(0.999828, 0.999828)
[node name="Right_Eye" parent="CanvasGroup/basic_zombie_walk/Zombie/Butt/Body/Head/HeadParticle/Head" index="0"]
position = Vector2(-16, -7.99999)
scale = Vector2(1, 1)
scale = Vector2(0.999827, 0.999827)
[node name="Left_Eye" parent="CanvasGroup/basic_zombie_walk/Zombie/Butt/Body/Head/HeadParticle/Head" index="1"]
position = Vector2(-4, -9)
scale = Vector2(1, 1)
[node name="Jaw" parent="CanvasGroup/basic_zombie_walk/Zombie/Butt/Body/Head/HeadParticle/Head" index="2"]
position = Vector2(-2.8322, 2.59502)
rotation = -0.094379
position = Vector2(-2.94109, 2.85781)
rotation = -0.0331358
scale = Vector2(0.999828, 0.999828)
[node name="Jaw" parent="CanvasGroup/basic_zombie_walk/Zombie/Butt/Body/Head" index="1"]
@ -125,26 +120,26 @@ shape = SubResource("CircleShape2D_67t4t")
scale = Vector2(0.999828, 0.999828)
[node name="Left_Lower_Arm" parent="CanvasGroup/basic_zombie_walk/Zombie/Butt/Body/LeftUpperArm/HandProjectile" index="0"]
rotation = -0.143211
rotation = -0.0502802
scale = Vector2(1, 1)
[node name="Left_Hand" parent="CanvasGroup/basic_zombie_walk/Zombie/Butt/Body/LeftUpperArm/HandProjectile/Left_Lower_Arm" index="0"]
position = Vector2(-0.999832, 12.9978)
rotation = -0.118048
scale = Vector2(0.999656, 0.999656)
position = Vector2(-0.99983, 12.9978)
rotation = -0.0414459
scale = Vector2(0.999655, 0.999655)
[node name="LeftLowerArm" parent="CanvasGroup/basic_zombie_walk/Zombie/Butt/Body/LeftUpperArm" index="2"]
scale = Vector2(0.999831, 0.999831)
scale = Vector2(0.99983, 0.99983)
[node name="LeftHand" parent="CanvasGroup/basic_zombie_walk/Zombie/Butt/Body/LeftUpperArm/LeftLowerArm" index="0"]
scale = Vector2(0.999826, 0.999826)
scale = Vector2(0.999825, 0.999825)
[node name="Eatbox" parent="." index="2"]
_damage = SubResource("Resource_w70im")
[node name="Mover" parent="." index="4"]
_speed = SubResource("Resource_qof5v")
_speedControlMult = 0.965834
_speedControlMult = 0.339097
[node name="Armor" type="Node" parent="." index="6"]
script = ExtResource("3_5s7in")

View file

@ -735,6 +735,18 @@ tracks/43/keys = {
"update": 0,
"values": [Vector2(-4, -1)]
}
tracks/44/type = "value"
tracks/44/imported = false
tracks/44/enabled = true
tracks/44/path = NodePath("Zombie/Butt/Body/Tie:scale")
tracks/44/interp = 1
tracks/44/loop_wrap = true
tracks/44/keys = {
"times": PackedFloat32Array(0),
"transitions": PackedFloat32Array(1),
"update": 0,
"values": [Vector2(1, 1)]
}
[sub_resource type="AnimationLibrary" id="AnimationLibrary_x5uj2"]
_data = {
@ -757,7 +769,7 @@ size = Vector2(16, 48)
[sub_resource type="AnimationNodeTimeScale" id="AnimationNodeTimeScale_2q05d"]
[sub_resource type="AnimationNodeBlendTree" id="AnimationNodeBlendTree_ccrjo"]
graph_offset = Vector2(-427, 26)
graph_offset = Vector2(-606, 210)
nodes/TimeScale/node = SubResource("AnimationNodeTimeScale_2q05d")
nodes/TimeScale/position = Vector2(60, 120)
nodes/Tree/node = ExtResource("8_ckb7n")
@ -793,23 +805,27 @@ script = ExtResource("3_rao3m")
[node name="basic_zombie_walk" type="Node2D" parent="CanvasGroup"]
[node name="Zombie" type="Skeleton2D" parent="CanvasGroup/basic_zombie_walk"]
use_parent_material = true
modification_stack = SubResource("SkeletonModificationStack2D_wn68q")
[node name="Butt" type="Bone2D" parent="CanvasGroup/basic_zombie_walk/Zombie"]
use_parent_material = true
position = Vector2(5, -35)
scale = Vector2(0.999903, 0.999903)
rest = Transform2D(1, 0, 0, 1, 5, -35)
editor_settings/show_bone_gizmo = false
[node name="Butt" type="Sprite2D" parent="CanvasGroup/basic_zombie_walk/Zombie/Butt"]
use_parent_material = true
texture = SubResource("AtlasTexture_jvn5w")
centered = false
offset = Vector2(-10, -3)
metadata/_edit_lock_ = true
[node name="RightUpperLeg" type="Bone2D" parent="CanvasGroup/basic_zombie_walk/Zombie/Butt"]
use_parent_material = true
position = Vector2(-6, 3)
scale = Vector2(0.999834, 0.999834)
scale = Vector2(0.999831, 0.999831)
rest = Transform2D(1, 0, 0, 1, -6, 3)
editor_settings/show_bone_gizmo = false
@ -821,13 +837,13 @@ metadata/_edit_lock_ = true
[node name="RightLowerLeg" type="Bone2D" parent="CanvasGroup/basic_zombie_walk/Zombie/Butt/RightUpperLeg"]
position = Vector2(-2, 12)
scale = Vector2(0.99984, 0.99984)
scale = Vector2(0.999834, 0.999834)
rest = Transform2D(1, 0, 0, 1, -2, 12)
editor_settings/show_bone_gizmo = false
[node name="RightFoot" type="Bone2D" parent="CanvasGroup/basic_zombie_walk/Zombie/Butt/RightUpperLeg/RightLowerLeg"]
position = Vector2(-2, 14)
scale = Vector2(0.999831, 0.999831)
scale = Vector2(0.999834, 0.999834)
rest = Transform2D(1, 0, 0, 1, -2, 14)
auto_calculate_length_and_angle = false
length = 12.0
@ -848,8 +864,9 @@ offset = Vector2(12, 1)
metadata/_edit_lock_ = true
[node name="LeftUpperLeg" type="Bone2D" parent="CanvasGroup/basic_zombie_walk/Zombie/Butt"]
use_parent_material = true
position = Vector2(6, 4)
scale = Vector2(0.999835, 0.999835)
scale = Vector2(0.999834, 0.999834)
rest = Transform2D(1, 0, 0, 1, 6, 4)
editor_settings/show_bone_gizmo = false
@ -861,7 +878,7 @@ metadata/_edit_lock_ = true
[node name="LeftLowerLeg" type="Bone2D" parent="CanvasGroup/basic_zombie_walk/Zombie/Butt/LeftUpperLeg"]
position = Vector2(-1, 13)
scale = Vector2(0.999835, 0.999835)
scale = Vector2(0.999833, 0.999833)
rest = Transform2D(1, 0, 0, 1, -1, 13)
editor_settings/show_bone_gizmo = false
@ -873,7 +890,7 @@ metadata/_edit_lock_ = true
[node name="LeftFoot" type="Bone2D" parent="CanvasGroup/basic_zombie_walk/Zombie/Butt/LeftUpperLeg/LeftLowerLeg"]
position = Vector2(6, 10)
scale = Vector2(0.999833, 0.999833)
scale = Vector2(0.99983, 0.99983)
rest = Transform2D(1, 0, 0, 1, 6, 10)
auto_calculate_length_and_angle = false
length = 12.0
@ -887,15 +904,17 @@ offset = Vector2(-14, -3)
metadata/_edit_lock_ = true
[node name="Body" type="Bone2D" parent="CanvasGroup/basic_zombie_walk/Zombie/Butt"]
use_parent_material = true
position = Vector2(1, -2)
scale = Vector2(0.999833, 0.999833)
scale = Vector2(0.999827, 0.999827)
rest = Transform2D(1, 0, 0, 1, 1, -2)
editor_settings/show_bone_gizmo = false
[node name="RightUpperArm" type="Bone2D" parent="CanvasGroup/basic_zombie_walk/Zombie/Butt/Body"]
z_index = -1
use_parent_material = true
position = Vector2(-14, -23)
scale = Vector2(0.999827, 0.999827)
scale = Vector2(0.999829, 0.999829)
rest = Transform2D(1, 0, 0, 1, -14, -23)
editor_settings/show_bone_gizmo = false
@ -913,7 +932,7 @@ editor_settings/show_bone_gizmo = false
[node name="RightHand" type="Bone2D" parent="CanvasGroup/basic_zombie_walk/Zombie/Butt/Body/RightUpperArm/RightLowerArm"]
position = Vector2(-1, 13)
scale = Vector2(0.999829, 0.999829)
scale = Vector2(0.999828, 0.999828)
rest = Transform2D(1, 0, 0, 1, -1, 13)
auto_calculate_length_and_angle = false
length = 8.0
@ -941,8 +960,7 @@ metadata/_edit_lock_ = true
[node name="Tie" type="Bone2D" parent="CanvasGroup/basic_zombie_walk/Zombie/Butt/Body"]
position = Vector2(-9, -21)
scale = Vector2(0.999825, 0.999825)
skew = -0.000187755
skew = -0.000388026
rest = Transform2D(1, 0, 0, 1, -9, -21)
auto_calculate_length_and_angle = false
length = 24.0
@ -986,7 +1004,7 @@ offset = Vector2(-2, -2)
metadata/_edit_lock_ = true
[node name="Left_Eye" type="Sprite2D" parent="CanvasGroup/basic_zombie_walk/Zombie/Butt/Body/Head/HeadParticle/Head"]
position = Vector2(-4, -9)
position = Vector2(-4, -8.99999)
texture = SubResource("AtlasTexture_kto0i")
centered = false
offset = Vector2(-2, -2)
@ -994,7 +1012,7 @@ metadata/_edit_lock_ = true
[node name="Jaw" type="Sprite2D" parent="CanvasGroup/basic_zombie_walk/Zombie/Butt/Body/Head/HeadParticle/Head"]
position = Vector2(-3, 3)
scale = Vector2(0.999827, 0.999827)
scale = Vector2(0.999828, 0.999828)
texture = SubResource("AtlasTexture_x5uj2")
centered = false
offset = Vector2(-12, -2)
@ -1011,7 +1029,7 @@ _observedEntity = NodePath("../../../../../../../..")
[node name="Jaw" type="Bone2D" parent="CanvasGroup/basic_zombie_walk/Zombie/Butt/Body/Head"]
position = Vector2(-3, 3)
scale = Vector2(0.999827, 0.999827)
scale = Vector2(0.999828, 0.999828)
rest = Transform2D(1, 0, 0, 1, -3, 3)
auto_calculate_length_and_angle = false
length = 11.0
@ -1045,7 +1063,7 @@ remote_path = NodePath("../../HeadParticle/Head/Left_Eye")
[node name="LeftUpperArm" type="Bone2D" parent="CanvasGroup/basic_zombie_walk/Zombie/Butt/Body"]
position = Vector2(-1, -20)
scale = Vector2(0.999826, 0.999826)
scale = Vector2(0.999828, 0.999828)
rest = Transform2D(1, 0, 0, 1, -1, -20)
editor_settings/show_bone_gizmo = false
@ -1067,7 +1085,7 @@ minTorque = -45.0
maxTorque = 45.0
[node name="Left_Lower_Arm" type="Sprite2D" parent="CanvasGroup/basic_zombie_walk/Zombie/Butt/Body/LeftUpperArm/HandProjectile"]
scale = Vector2(1, 1)
scale = Vector2(0.999998, 0.999998)
texture = SubResource("AtlasTexture_auqeq")
centered = false
offset = Vector2(-5, 0)
@ -1092,7 +1110,7 @@ _observedEntity = NodePath("../../../../../../../..")
[node name="LeftLowerArm" type="Bone2D" parent="CanvasGroup/basic_zombie_walk/Zombie/Butt/Body/LeftUpperArm"]
position = Vector2(-2, 14)
scale = Vector2(0.99983, 0.99983)
scale = Vector2(0.999828, 0.999828)
rest = Transform2D(1, 0, 0, 1, -2, 14)
editor_settings/show_bone_gizmo = false
@ -1148,7 +1166,6 @@ entity = NodePath("..")
[node name="Mover" type="Node" parent="."]
script = ExtResource("4_u5syx")
_speed = SubResource("Resource_ckb7n")
_speedControlMult = 0.100826
[node name="ChompPlayer" type="Node" parent="."]
script = ExtResource("10_ruqsf")

View file

@ -13,6 +13,14 @@ public partial class RuntimeZombieData : Entity
[Signal] public delegate void HasBeenKilledEventHandler(RuntimeZombieData who);
public bool AbleToEat = true;
public override void _Ready()
{
base._Ready();
LocalTimescale += (float)GD.RandRange(-0.05, 0.05);
}
public override void Heal(float amount, Node origin)
{
if (_armor != null)

View file

@ -13,8 +13,6 @@ public partial class ZombieMover : Node
public override void _Ready()
{
_zombie = GetParent<Node2D>();
_speed = (FloatModifiers)_speed.Duplicate();
_speed.ChangePercentage((float)GD.RandRange(-0.05,0.05));
}
public override void _PhysicsProcess(double delta)