Try to get Chinthe to stop jumping upon reaching player
This commit is contained in:
@@ -44,10 +44,6 @@ public abstract partial class Enemy2D : Enemy
|
|||||||
{
|
{
|
||||||
Velocity = safeVelocity;
|
Velocity = safeVelocity;
|
||||||
LookAtTarget(safeVelocity);
|
LookAtTarget(safeVelocity);
|
||||||
if (Velocity > Vector3.Zero)
|
|
||||||
_enemyLogic.Input(new EnemyLogic.Input.Move());
|
|
||||||
else
|
|
||||||
_enemyLogic.Input(new EnemyLogic.Input.Idle());
|
|
||||||
MoveAndSlide();
|
MoveAndSlide();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -12,6 +12,7 @@ public abstract partial class EnemyModelView : Node3D, IEnemyModelView
|
|||||||
|
|
||||||
private readonly string _idleName = "Idle";
|
private readonly string _idleName = "Idle";
|
||||||
private readonly string _walkingName = "Walking";
|
private readonly string _walkingName = "Walking";
|
||||||
|
private readonly string _stopWalkName = "Stop Walk";
|
||||||
private readonly string _primaryAttackName = "Primary Attack";
|
private readonly string _primaryAttackName = "Primary Attack";
|
||||||
private readonly string _secondaryAttackName = "Secondary Attack";
|
private readonly string _secondaryAttackName = "Secondary Attack";
|
||||||
private readonly string _activateName = "Activate";
|
private readonly string _activateName = "Activate";
|
||||||
@@ -50,6 +51,8 @@ public abstract partial class EnemyModelView : Node3D, IEnemyModelView
|
|||||||
|
|
||||||
public virtual void PlayWalkAnimation() => _stateMachine.Travel(_walkingName);
|
public virtual void PlayWalkAnimation() => _stateMachine.Travel(_walkingName);
|
||||||
|
|
||||||
|
public virtual void PlayStopWalkAnimation() => _stateMachine.Travel(_stopWalkName);
|
||||||
|
|
||||||
public virtual void PlayActivateAnimation() => _stateMachine.Travel(_activateName);
|
public virtual void PlayActivateAnimation() => _stateMachine.Travel(_activateName);
|
||||||
|
|
||||||
public virtual void PlayDeathAnimation() => throw new System.NotImplementedException();
|
public virtual void PlayDeathAnimation() => throw new System.NotImplementedException();
|
||||||
|
|||||||
@@ -9,6 +9,8 @@ public interface IEnemyModelView : INode3D
|
|||||||
|
|
||||||
public void PlayWalkAnimation();
|
public void PlayWalkAnimation();
|
||||||
|
|
||||||
|
public void PlayStopWalkAnimation();
|
||||||
|
|
||||||
public void PlayPrimaryAttackAnimation();
|
public void PlayPrimaryAttackAnimation();
|
||||||
|
|
||||||
public void PlaySecondaryAttackAnimation();
|
public void PlaySecondaryAttackAnimation();
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
[gd_resource type="AnimationNodeStateMachine" load_steps=18 format=3 uid="uid://bh0hsg4in5bkt"]
|
[gd_resource type="AnimationNodeStateMachine" load_steps=22 format=3 uid="uid://bh0hsg4in5bkt"]
|
||||||
|
|
||||||
[sub_resource type="AnimationNodeAnimation" id="AnimationNodeAnimation_ivy74"]
|
[sub_resource type="AnimationNodeAnimation" id="AnimationNodeAnimation_ivy74"]
|
||||||
animation = &"activated_idle_back"
|
animation = &"activated_idle_back"
|
||||||
@@ -75,6 +75,18 @@ switch_mode = 1
|
|||||||
advance_mode = 2
|
advance_mode = 2
|
||||||
advance_expression = "_enemyDirection == 1"
|
advance_expression = "_enemyDirection == 1"
|
||||||
|
|
||||||
|
[sub_resource type="AnimationNodeStateMachineTransition" id="AnimationNodeStateMachineTransition_26rpk"]
|
||||||
|
switch_mode = 2
|
||||||
|
|
||||||
|
[sub_resource type="AnimationNodeStateMachineTransition" id="AnimationNodeStateMachineTransition_164gf"]
|
||||||
|
switch_mode = 2
|
||||||
|
|
||||||
|
[sub_resource type="AnimationNodeStateMachineTransition" id="AnimationNodeStateMachineTransition_hsg0y"]
|
||||||
|
switch_mode = 2
|
||||||
|
|
||||||
|
[sub_resource type="AnimationNodeStateMachineTransition" id="AnimationNodeStateMachineTransition_8dcca"]
|
||||||
|
switch_mode = 2
|
||||||
|
|
||||||
[resource]
|
[resource]
|
||||||
states/End/position = Vector2(910, 100)
|
states/End/position = Vector2(910, 100)
|
||||||
states/back/node = SubResource("AnimationNodeAnimation_ivy74")
|
states/back/node = SubResource("AnimationNodeAnimation_ivy74")
|
||||||
@@ -85,4 +97,5 @@ states/left/node = SubResource("AnimationNodeAnimation_djeua")
|
|||||||
states/left/position = Vector2(378, 179)
|
states/left/position = Vector2(378, 179)
|
||||||
states/right/node = SubResource("AnimationNodeAnimation_8wbs7")
|
states/right/node = SubResource("AnimationNodeAnimation_8wbs7")
|
||||||
states/right/position = Vector2(701, 179)
|
states/right/position = Vector2(701, 179)
|
||||||
transitions = ["Start", "forward", SubResource("AnimationNodeStateMachineTransition_ivy74"), "forward", "left", SubResource("AnimationNodeStateMachineTransition_x7uye"), "left", "forward", SubResource("AnimationNodeStateMachineTransition_djeua"), "forward", "back", SubResource("AnimationNodeStateMachineTransition_8wbs7"), "back", "forward", SubResource("AnimationNodeStateMachineTransition_mnr4r"), "left", "right", SubResource("AnimationNodeStateMachineTransition_l2wq1"), "right", "left", SubResource("AnimationNodeStateMachineTransition_jwlar"), "back", "left", SubResource("AnimationNodeStateMachineTransition_fdoul"), "left", "back", SubResource("AnimationNodeStateMachineTransition_kpotx"), "forward", "right", SubResource("AnimationNodeStateMachineTransition_lfuuf"), "right", "forward", SubResource("AnimationNodeStateMachineTransition_dfvqa"), "right", "back", SubResource("AnimationNodeStateMachineTransition_dnvt3"), "back", "right", SubResource("AnimationNodeStateMachineTransition_m7aft")]
|
transitions = ["Start", "forward", SubResource("AnimationNodeStateMachineTransition_ivy74"), "forward", "left", SubResource("AnimationNodeStateMachineTransition_x7uye"), "left", "forward", SubResource("AnimationNodeStateMachineTransition_djeua"), "forward", "back", SubResource("AnimationNodeStateMachineTransition_8wbs7"), "back", "forward", SubResource("AnimationNodeStateMachineTransition_mnr4r"), "left", "right", SubResource("AnimationNodeStateMachineTransition_l2wq1"), "right", "left", SubResource("AnimationNodeStateMachineTransition_jwlar"), "back", "left", SubResource("AnimationNodeStateMachineTransition_fdoul"), "left", "back", SubResource("AnimationNodeStateMachineTransition_kpotx"), "forward", "right", SubResource("AnimationNodeStateMachineTransition_lfuuf"), "right", "forward", SubResource("AnimationNodeStateMachineTransition_dfvqa"), "right", "back", SubResource("AnimationNodeStateMachineTransition_dnvt3"), "back", "right", SubResource("AnimationNodeStateMachineTransition_m7aft"), "forward", "End", SubResource("AnimationNodeStateMachineTransition_26rpk"), "right", "End", SubResource("AnimationNodeStateMachineTransition_164gf"), "left", "End", SubResource("AnimationNodeStateMachineTransition_hsg0y"), "back", "End", SubResource("AnimationNodeStateMachineTransition_8dcca")]
|
||||||
|
graph_offset = Vector2(0, 97.0247)
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
[gd_resource type="AnimationNodeStateMachine" load_steps=18 format=3 uid="uid://cy2ngl55c0rws"]
|
[gd_resource type="AnimationNodeStateMachine" load_steps=22 format=3 uid="uid://cy2ngl55c0rws"]
|
||||||
|
|
||||||
[sub_resource type="AnimationNodeAnimation" id="AnimationNodeAnimation_ivy74"]
|
[sub_resource type="AnimationNodeAnimation" id="AnimationNodeAnimation_ivy74"]
|
||||||
animation = &"idle_back_walk"
|
animation = &"idle_back_walk"
|
||||||
@@ -75,16 +75,36 @@ switch_mode = 1
|
|||||||
advance_mode = 2
|
advance_mode = 2
|
||||||
advance_expression = "_enemyDirection == 1"
|
advance_expression = "_enemyDirection == 1"
|
||||||
|
|
||||||
|
[sub_resource type="AnimationNodeStateMachineTransition" id="AnimationNodeStateMachineTransition_v537b"]
|
||||||
|
break_loop_at_end = true
|
||||||
|
reset = false
|
||||||
|
switch_mode = 2
|
||||||
|
|
||||||
|
[sub_resource type="AnimationNodeStateMachineTransition" id="AnimationNodeStateMachineTransition_11ejb"]
|
||||||
|
break_loop_at_end = true
|
||||||
|
reset = false
|
||||||
|
switch_mode = 2
|
||||||
|
|
||||||
|
[sub_resource type="AnimationNodeStateMachineTransition" id="AnimationNodeStateMachineTransition_ear7g"]
|
||||||
|
break_loop_at_end = true
|
||||||
|
reset = false
|
||||||
|
switch_mode = 2
|
||||||
|
|
||||||
|
[sub_resource type="AnimationNodeStateMachineTransition" id="AnimationNodeStateMachineTransition_bxbbg"]
|
||||||
|
break_loop_at_end = true
|
||||||
|
reset = false
|
||||||
|
switch_mode = 2
|
||||||
|
|
||||||
[resource]
|
[resource]
|
||||||
states/End/position = Vector2(910, 100)
|
states/End/position = Vector2(910, 100)
|
||||||
states/Start/position = Vector2(102, 111)
|
states/Start/position = Vector2(102, 111)
|
||||||
states/back/node = SubResource("AnimationNodeAnimation_ivy74")
|
states/back/node = SubResource("AnimationNodeAnimation_ivy74")
|
||||||
states/back/position = Vector2(542, 276)
|
states/back/position = Vector2(542, 276)
|
||||||
states/forward/node = SubResource("AnimationNodeAnimation_x7uye")
|
states/forward/node = SubResource("AnimationNodeAnimation_x7uye")
|
||||||
states/forward/position = Vector2(542, 68)
|
states/forward/position = Vector2(542, 67)
|
||||||
states/left/node = SubResource("AnimationNodeAnimation_djeua")
|
states/left/node = SubResource("AnimationNodeAnimation_djeua")
|
||||||
states/left/position = Vector2(378, 179)
|
states/left/position = Vector2(378, 179)
|
||||||
states/right/node = SubResource("AnimationNodeAnimation_8wbs7")
|
states/right/node = SubResource("AnimationNodeAnimation_8wbs7")
|
||||||
states/right/position = Vector2(701, 179)
|
states/right/position = Vector2(701, 179)
|
||||||
transitions = ["Start", "forward", SubResource("AnimationNodeStateMachineTransition_ivy74"), "forward", "left", SubResource("AnimationNodeStateMachineTransition_x7uye"), "left", "forward", SubResource("AnimationNodeStateMachineTransition_djeua"), "forward", "back", SubResource("AnimationNodeStateMachineTransition_8wbs7"), "back", "forward", SubResource("AnimationNodeStateMachineTransition_mnr4r"), "left", "right", SubResource("AnimationNodeStateMachineTransition_l2wq1"), "right", "left", SubResource("AnimationNodeStateMachineTransition_jwlar"), "back", "left", SubResource("AnimationNodeStateMachineTransition_fdoul"), "left", "back", SubResource("AnimationNodeStateMachineTransition_kpotx"), "forward", "right", SubResource("AnimationNodeStateMachineTransition_lfuuf"), "right", "forward", SubResource("AnimationNodeStateMachineTransition_dfvqa"), "right", "back", SubResource("AnimationNodeStateMachineTransition_dnvt3"), "back", "right", SubResource("AnimationNodeStateMachineTransition_m7aft")]
|
transitions = ["Start", "forward", SubResource("AnimationNodeStateMachineTransition_ivy74"), "forward", "left", SubResource("AnimationNodeStateMachineTransition_x7uye"), "left", "forward", SubResource("AnimationNodeStateMachineTransition_djeua"), "forward", "back", SubResource("AnimationNodeStateMachineTransition_8wbs7"), "back", "forward", SubResource("AnimationNodeStateMachineTransition_mnr4r"), "left", "right", SubResource("AnimationNodeStateMachineTransition_l2wq1"), "right", "left", SubResource("AnimationNodeStateMachineTransition_jwlar"), "back", "left", SubResource("AnimationNodeStateMachineTransition_fdoul"), "left", "back", SubResource("AnimationNodeStateMachineTransition_kpotx"), "forward", "right", SubResource("AnimationNodeStateMachineTransition_lfuuf"), "right", "forward", SubResource("AnimationNodeStateMachineTransition_dfvqa"), "right", "back", SubResource("AnimationNodeStateMachineTransition_dnvt3"), "back", "right", SubResource("AnimationNodeStateMachineTransition_m7aft"), "forward", "End", SubResource("AnimationNodeStateMachineTransition_v537b"), "right", "End", SubResource("AnimationNodeStateMachineTransition_11ejb"), "left", "End", SubResource("AnimationNodeStateMachineTransition_ear7g"), "back", "End", SubResource("AnimationNodeStateMachineTransition_bxbbg")]
|
||||||
graph_offset = Vector2(-372.546, -3.34571)
|
graph_offset = Vector2(-372.546, -6.6914)
|
||||||
|
|||||||
@@ -37,9 +37,14 @@ public partial class Chinthe : Enemy2D, IHaveEngagePlayerBehavior, IHaveFollowBe
|
|||||||
EnemyModelView.PlayActivateAnimation();
|
EnemyModelView.PlayActivateAnimation();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public override void Idle()
|
||||||
|
{
|
||||||
|
EnemyModelView.PlayIdleAnimation();
|
||||||
|
EnemyModelView.PlayIdleAnimation();
|
||||||
|
}
|
||||||
|
|
||||||
public void OnChintheVelocityComputed(Vector3 safeVelocity)
|
public void OnChintheVelocityComputed(Vector3 safeVelocity)
|
||||||
{
|
{
|
||||||
_enemyLogic.Input(new EnemyLogic.Input.Move());
|
|
||||||
Velocity = safeVelocity;
|
Velocity = safeVelocity;
|
||||||
LookAtTarget(safeVelocity);
|
LookAtTarget(safeVelocity);
|
||||||
if (((EnemyModelView)EnemyModelView).CanMove)
|
if (((EnemyModelView)EnemyModelView).CanMove)
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
[gd_scene load_steps=475 format=3 uid="uid://byd7cwxq1be6f"]
|
[gd_scene load_steps=502 format=3 uid="uid://byd7cwxq1be6f"]
|
||||||
|
|
||||||
[ext_resource type="Script" uid="uid://cvr1qimxpignl" path="res://src/enemy/EnemyModelView2D.cs" id="1_6dej3"]
|
[ext_resource type="Script" uid="uid://cvr1qimxpignl" path="res://src/enemy/EnemyModelView2D.cs" id="1_6dej3"]
|
||||||
[ext_resource type="Texture2D" uid="uid://dnd6d5cx7x7i8" path="res://src/enemy/enemy_types/07. chinthe/animations/CHINTHE - RERENDER/BACK/0400.png" id="2_3sdh3"]
|
[ext_resource type="Texture2D" uid="uid://dnd6d5cx7x7i8" path="res://src/enemy/enemy_types/07. chinthe/animations/CHINTHE - RERENDER/BACK/0400.png" id="2_3sdh3"]
|
||||||
@@ -2884,6 +2884,242 @@ tracks/6/keys = {
|
|||||||
"values": [Color(1, 1, 1, 1), Color(100, 100, 100, 1), Color(1, 1, 1, 1)]
|
"values": [Color(1, 1, 1, 1), Color(100, 100, 100, 1), Color(1, 1, 1, 1)]
|
||||||
}
|
}
|
||||||
|
|
||||||
|
[sub_resource type="Animation" id="Animation_jbhro"]
|
||||||
|
resource_name = "stop_walk_front"
|
||||||
|
length = 1.41668
|
||||||
|
step = 0.0833333
|
||||||
|
tracks/0/type = "value"
|
||||||
|
tracks/0/imported = false
|
||||||
|
tracks/0/enabled = true
|
||||||
|
tracks/0/path = NodePath("Sprite3D/SubViewportContainer/SubViewport/AnimatedSprite:animation")
|
||||||
|
tracks/0/interp = 1
|
||||||
|
tracks/0/loop_wrap = true
|
||||||
|
tracks/0/keys = {
|
||||||
|
"times": PackedFloat32Array(0),
|
||||||
|
"transitions": PackedFloat32Array(1),
|
||||||
|
"update": 1,
|
||||||
|
"values": [&"idle_front_walk"]
|
||||||
|
}
|
||||||
|
tracks/1/type = "value"
|
||||||
|
tracks/1/imported = false
|
||||||
|
tracks/1/enabled = true
|
||||||
|
tracks/1/path = NodePath("Sprite3D/SubViewportContainer/SubViewport/AnimatedSprite:frame")
|
||||||
|
tracks/1/interp = 1
|
||||||
|
tracks/1/loop_wrap = true
|
||||||
|
tracks/1/keys = {
|
||||||
|
"times": PackedFloat32Array(0, 1.41667),
|
||||||
|
"transitions": PackedFloat32Array(1, 1),
|
||||||
|
"update": 0,
|
||||||
|
"values": [0, 17]
|
||||||
|
}
|
||||||
|
tracks/2/type = "value"
|
||||||
|
tracks/2/imported = false
|
||||||
|
tracks/2/enabled = true
|
||||||
|
tracks/2/path = NodePath("Sprite3D:position")
|
||||||
|
tracks/2/interp = 1
|
||||||
|
tracks/2/loop_wrap = true
|
||||||
|
tracks/2/keys = {
|
||||||
|
"times": PackedFloat32Array(0, 0.166667, 0.416667),
|
||||||
|
"transitions": PackedFloat32Array(1, 5.46418, 1),
|
||||||
|
"update": 0,
|
||||||
|
"values": [Vector3(0, 0, 0), Vector3(0, 1.5, 0), Vector3(0, 0, 0)]
|
||||||
|
}
|
||||||
|
tracks/3/type = "value"
|
||||||
|
tracks/3/imported = false
|
||||||
|
tracks/3/enabled = true
|
||||||
|
tracks/3/path = NodePath(".:CanMove")
|
||||||
|
tracks/3/interp = 1
|
||||||
|
tracks/3/loop_wrap = true
|
||||||
|
tracks/3/keys = {
|
||||||
|
"times": PackedFloat32Array(0, 0.0833333, 0.416667),
|
||||||
|
"transitions": PackedFloat32Array(1, 1, 1),
|
||||||
|
"update": 1,
|
||||||
|
"values": [false, true, false]
|
||||||
|
}
|
||||||
|
|
||||||
|
[sub_resource type="Animation" id="Animation_keq07"]
|
||||||
|
resource_name = "stop_back_walk"
|
||||||
|
length = 1.41668
|
||||||
|
step = 0.0833333
|
||||||
|
tracks/0/type = "value"
|
||||||
|
tracks/0/imported = false
|
||||||
|
tracks/0/enabled = true
|
||||||
|
tracks/0/path = NodePath("Sprite3D/SubViewportContainer/SubViewport/AnimatedSprite:animation")
|
||||||
|
tracks/0/interp = 1
|
||||||
|
tracks/0/loop_wrap = true
|
||||||
|
tracks/0/keys = {
|
||||||
|
"times": PackedFloat32Array(0),
|
||||||
|
"transitions": PackedFloat32Array(1),
|
||||||
|
"update": 1,
|
||||||
|
"values": [&"idle_back_walk"]
|
||||||
|
}
|
||||||
|
tracks/1/type = "value"
|
||||||
|
tracks/1/imported = false
|
||||||
|
tracks/1/enabled = true
|
||||||
|
tracks/1/path = NodePath("Sprite3D/SubViewportContainer/SubViewport/AnimatedSprite:frame")
|
||||||
|
tracks/1/interp = 1
|
||||||
|
tracks/1/loop_wrap = true
|
||||||
|
tracks/1/keys = {
|
||||||
|
"times": PackedFloat32Array(0, 1.41667),
|
||||||
|
"transitions": PackedFloat32Array(1, 1),
|
||||||
|
"update": 0,
|
||||||
|
"values": [0, 17]
|
||||||
|
}
|
||||||
|
tracks/2/type = "value"
|
||||||
|
tracks/2/imported = false
|
||||||
|
tracks/2/enabled = true
|
||||||
|
tracks/2/path = NodePath("Sprite3D:position")
|
||||||
|
tracks/2/interp = 1
|
||||||
|
tracks/2/loop_wrap = true
|
||||||
|
tracks/2/keys = {
|
||||||
|
"times": PackedFloat32Array(0, 0.166667, 0.416667),
|
||||||
|
"transitions": PackedFloat32Array(1, 5.46418, 1),
|
||||||
|
"update": 0,
|
||||||
|
"values": [Vector3(0, 0, 0), Vector3(0, 1.5, 0), Vector3(0, 0, 0)]
|
||||||
|
}
|
||||||
|
tracks/3/type = "value"
|
||||||
|
tracks/3/imported = false
|
||||||
|
tracks/3/enabled = true
|
||||||
|
tracks/3/path = NodePath(".:CanMove")
|
||||||
|
tracks/3/interp = 1
|
||||||
|
tracks/3/loop_wrap = true
|
||||||
|
tracks/3/keys = {
|
||||||
|
"times": PackedFloat32Array(0, 0.167921, 0.417721),
|
||||||
|
"transitions": PackedFloat32Array(1, 1, 1),
|
||||||
|
"update": 1,
|
||||||
|
"values": [false, true, false]
|
||||||
|
}
|
||||||
|
|
||||||
|
[sub_resource type="Animation" id="Animation_w4c47"]
|
||||||
|
resource_name = "stop_left_walk"
|
||||||
|
length = 1.41668
|
||||||
|
step = 0.0833333
|
||||||
|
tracks/0/type = "value"
|
||||||
|
tracks/0/imported = false
|
||||||
|
tracks/0/enabled = true
|
||||||
|
tracks/0/path = NodePath("Sprite3D/SubViewportContainer/SubViewport/AnimatedSprite:animation")
|
||||||
|
tracks/0/interp = 1
|
||||||
|
tracks/0/loop_wrap = true
|
||||||
|
tracks/0/keys = {
|
||||||
|
"times": PackedFloat32Array(0),
|
||||||
|
"transitions": PackedFloat32Array(1),
|
||||||
|
"update": 1,
|
||||||
|
"values": [&"idle_left_walk"]
|
||||||
|
}
|
||||||
|
tracks/1/type = "value"
|
||||||
|
tracks/1/imported = false
|
||||||
|
tracks/1/enabled = true
|
||||||
|
tracks/1/path = NodePath("Sprite3D/SubViewportContainer/SubViewport/AnimatedSprite:frame")
|
||||||
|
tracks/1/interp = 1
|
||||||
|
tracks/1/loop_wrap = true
|
||||||
|
tracks/1/keys = {
|
||||||
|
"times": PackedFloat32Array(0, 1.41667),
|
||||||
|
"transitions": PackedFloat32Array(1, 1),
|
||||||
|
"update": 0,
|
||||||
|
"values": [0, 17]
|
||||||
|
}
|
||||||
|
tracks/2/type = "value"
|
||||||
|
tracks/2/imported = false
|
||||||
|
tracks/2/enabled = true
|
||||||
|
tracks/2/path = NodePath("Sprite3D:position")
|
||||||
|
tracks/2/interp = 1
|
||||||
|
tracks/2/loop_wrap = true
|
||||||
|
tracks/2/keys = {
|
||||||
|
"times": PackedFloat32Array(0, 0.166667, 0.416667),
|
||||||
|
"transitions": PackedFloat32Array(1, 5.46418, 1),
|
||||||
|
"update": 0,
|
||||||
|
"values": [Vector3(0, 0, 0), Vector3(0, 1.5, 0), Vector3(0, 0, 0)]
|
||||||
|
}
|
||||||
|
tracks/3/type = "value"
|
||||||
|
tracks/3/imported = false
|
||||||
|
tracks/3/enabled = true
|
||||||
|
tracks/3/path = NodePath("Sprite3D:flip_h")
|
||||||
|
tracks/3/interp = 1
|
||||||
|
tracks/3/loop_wrap = true
|
||||||
|
tracks/3/keys = {
|
||||||
|
"times": PackedFloat32Array(0),
|
||||||
|
"transitions": PackedFloat32Array(1),
|
||||||
|
"update": 1,
|
||||||
|
"values": [true]
|
||||||
|
}
|
||||||
|
tracks/4/type = "value"
|
||||||
|
tracks/4/imported = false
|
||||||
|
tracks/4/enabled = true
|
||||||
|
tracks/4/path = NodePath(".:CanMove")
|
||||||
|
tracks/4/interp = 1
|
||||||
|
tracks/4/loop_wrap = true
|
||||||
|
tracks/4/keys = {
|
||||||
|
"times": PackedFloat32Array(0, 0.167921, 0.417721),
|
||||||
|
"transitions": PackedFloat32Array(1, 1, 1),
|
||||||
|
"update": 1,
|
||||||
|
"values": [false, true, false]
|
||||||
|
}
|
||||||
|
|
||||||
|
[sub_resource type="Animation" id="Animation_5lbxl"]
|
||||||
|
resource_name = "stop_right_walk"
|
||||||
|
length = 1.41667
|
||||||
|
step = 0.0833333
|
||||||
|
tracks/0/type = "value"
|
||||||
|
tracks/0/imported = false
|
||||||
|
tracks/0/enabled = true
|
||||||
|
tracks/0/path = NodePath("Sprite3D/SubViewportContainer/SubViewport/AnimatedSprite:animation")
|
||||||
|
tracks/0/interp = 1
|
||||||
|
tracks/0/loop_wrap = true
|
||||||
|
tracks/0/keys = {
|
||||||
|
"times": PackedFloat32Array(0),
|
||||||
|
"transitions": PackedFloat32Array(1),
|
||||||
|
"update": 1,
|
||||||
|
"values": [&"idle_left_walk"]
|
||||||
|
}
|
||||||
|
tracks/1/type = "value"
|
||||||
|
tracks/1/imported = false
|
||||||
|
tracks/1/enabled = true
|
||||||
|
tracks/1/path = NodePath("Sprite3D/SubViewportContainer/SubViewport/AnimatedSprite:frame")
|
||||||
|
tracks/1/interp = 1
|
||||||
|
tracks/1/loop_wrap = true
|
||||||
|
tracks/1/keys = {
|
||||||
|
"times": PackedFloat32Array(0, 1.41667),
|
||||||
|
"transitions": PackedFloat32Array(1, 1),
|
||||||
|
"update": 0,
|
||||||
|
"values": [0, 17]
|
||||||
|
}
|
||||||
|
tracks/2/type = "value"
|
||||||
|
tracks/2/imported = false
|
||||||
|
tracks/2/enabled = true
|
||||||
|
tracks/2/path = NodePath("Sprite3D:position")
|
||||||
|
tracks/2/interp = 1
|
||||||
|
tracks/2/loop_wrap = true
|
||||||
|
tracks/2/keys = {
|
||||||
|
"times": PackedFloat32Array(0, 0.166667, 0.416667),
|
||||||
|
"transitions": PackedFloat32Array(1, 5.46418, 1),
|
||||||
|
"update": 0,
|
||||||
|
"values": [Vector3(0, 0, 0), Vector3(0, 1.5, 0), Vector3(0, 0, 0)]
|
||||||
|
}
|
||||||
|
tracks/3/type = "value"
|
||||||
|
tracks/3/imported = false
|
||||||
|
tracks/3/enabled = true
|
||||||
|
tracks/3/path = NodePath("Sprite3D:flip_h")
|
||||||
|
tracks/3/interp = 1
|
||||||
|
tracks/3/loop_wrap = true
|
||||||
|
tracks/3/keys = {
|
||||||
|
"times": PackedFloat32Array(0),
|
||||||
|
"transitions": PackedFloat32Array(1),
|
||||||
|
"update": 1,
|
||||||
|
"values": [false]
|
||||||
|
}
|
||||||
|
tracks/4/type = "value"
|
||||||
|
tracks/4/imported = false
|
||||||
|
tracks/4/enabled = true
|
||||||
|
tracks/4/path = NodePath(".:CanMove")
|
||||||
|
tracks/4/interp = 1
|
||||||
|
tracks/4/loop_wrap = true
|
||||||
|
tracks/4/keys = {
|
||||||
|
"times": PackedFloat32Array(0, 0.167921, 0.417721),
|
||||||
|
"transitions": PackedFloat32Array(1, 1, 1),
|
||||||
|
"update": 1,
|
||||||
|
"values": [false, true, false]
|
||||||
|
}
|
||||||
|
|
||||||
[sub_resource type="AnimationLibrary" id="AnimationLibrary_46p8q"]
|
[sub_resource type="AnimationLibrary" id="AnimationLibrary_46p8q"]
|
||||||
_data = {
|
_data = {
|
||||||
&"RESET": SubResource("Animation_46p8q"),
|
&"RESET": SubResource("Animation_46p8q"),
|
||||||
@@ -2910,6 +3146,10 @@ _data = {
|
|||||||
&"secondary_attack": SubResource("Animation_6avl1"),
|
&"secondary_attack": SubResource("Animation_6avl1"),
|
||||||
&"secondary_attack_back": SubResource("Animation_nusgj"),
|
&"secondary_attack_back": SubResource("Animation_nusgj"),
|
||||||
&"secondary_attack_left": SubResource("Animation_ixs6i"),
|
&"secondary_attack_left": SubResource("Animation_ixs6i"),
|
||||||
|
&"stop_back_walk": SubResource("Animation_keq07"),
|
||||||
|
&"stop_left_walk": SubResource("Animation_w4c47"),
|
||||||
|
&"stop_right_walk": SubResource("Animation_5lbxl"),
|
||||||
|
&"stop_walk_front": SubResource("Animation_jbhro"),
|
||||||
&"teleport": SubResource("Animation_6dej3"),
|
&"teleport": SubResource("Animation_6dej3"),
|
||||||
&"teleport in": SubResource("Animation_3sdh3")
|
&"teleport in": SubResource("Animation_3sdh3")
|
||||||
}
|
}
|
||||||
@@ -2917,6 +3157,97 @@ _data = {
|
|||||||
[sub_resource type="AnimationNodeAnimation" id="AnimationNodeAnimation_op3hf"]
|
[sub_resource type="AnimationNodeAnimation" id="AnimationNodeAnimation_op3hf"]
|
||||||
animation = &"teleport"
|
animation = &"teleport"
|
||||||
|
|
||||||
|
[sub_resource type="AnimationNodeAnimation" id="AnimationNodeAnimation_jbhro"]
|
||||||
|
animation = &"stop_back_walk"
|
||||||
|
|
||||||
|
[sub_resource type="AnimationNodeAnimation" id="AnimationNodeAnimation_keq07"]
|
||||||
|
animation = &"stop_left_walk"
|
||||||
|
|
||||||
|
[sub_resource type="AnimationNodeAnimation" id="AnimationNodeAnimation_w4c47"]
|
||||||
|
animation = &"stop_right_walk"
|
||||||
|
|
||||||
|
[sub_resource type="AnimationNodeAnimation" id="AnimationNodeAnimation_5lbxl"]
|
||||||
|
animation = &"stop_walk_front"
|
||||||
|
|
||||||
|
[sub_resource type="AnimationNodeStateMachineTransition" id="AnimationNodeStateMachineTransition_yu6fp"]
|
||||||
|
reset = false
|
||||||
|
advance_mode = 2
|
||||||
|
|
||||||
|
[sub_resource type="AnimationNodeStateMachineTransition" id="AnimationNodeStateMachineTransition_djlpo"]
|
||||||
|
advance_mode = 2
|
||||||
|
advance_expression = "_enemyDirection == 0"
|
||||||
|
|
||||||
|
[sub_resource type="AnimationNodeStateMachineTransition" id="AnimationNodeStateMachineTransition_t2war"]
|
||||||
|
advance_mode = 2
|
||||||
|
advance_expression = "_enemyDirection == 2"
|
||||||
|
|
||||||
|
[sub_resource type="AnimationNodeStateMachineTransition" id="AnimationNodeStateMachineTransition_b16jm"]
|
||||||
|
advance_mode = 2
|
||||||
|
advance_expression = "_enemyDirection == 3"
|
||||||
|
|
||||||
|
[sub_resource type="AnimationNodeStateMachineTransition" id="AnimationNodeStateMachineTransition_d1ogr"]
|
||||||
|
advance_mode = 2
|
||||||
|
advance_expression = "_enemyDirection == 2"
|
||||||
|
|
||||||
|
[sub_resource type="AnimationNodeStateMachineTransition" id="AnimationNodeStateMachineTransition_7dl50"]
|
||||||
|
advance_mode = 2
|
||||||
|
advance_expression = "_enemyDirection == 1"
|
||||||
|
|
||||||
|
[sub_resource type="AnimationNodeStateMachineTransition" id="AnimationNodeStateMachineTransition_y2ova"]
|
||||||
|
advance_mode = 2
|
||||||
|
advance_expression = "_enemyDirection == 2"
|
||||||
|
|
||||||
|
[sub_resource type="AnimationNodeStateMachineTransition" id="AnimationNodeStateMachineTransition_8vs7h"]
|
||||||
|
advance_mode = 2
|
||||||
|
advance_expression = "_enemyDirection == 1"
|
||||||
|
|
||||||
|
[sub_resource type="AnimationNodeStateMachineTransition" id="AnimationNodeStateMachineTransition_rgja2"]
|
||||||
|
advance_mode = 2
|
||||||
|
advance_expression = "_enemyDirection == 3"
|
||||||
|
|
||||||
|
[sub_resource type="AnimationNodeStateMachineTransition" id="AnimationNodeStateMachineTransition_syao6"]
|
||||||
|
advance_mode = 2
|
||||||
|
advance_expression = "_enemyDirection == 0"
|
||||||
|
|
||||||
|
[sub_resource type="AnimationNodeStateMachineTransition" id="AnimationNodeStateMachineTransition_3iqav"]
|
||||||
|
advance_mode = 2
|
||||||
|
advance_expression = "_enemyDirection == 3"
|
||||||
|
|
||||||
|
[sub_resource type="AnimationNodeStateMachineTransition" id="AnimationNodeStateMachineTransition_ii52r"]
|
||||||
|
advance_mode = 2
|
||||||
|
advance_expression = "_enemyDirection == 1"
|
||||||
|
|
||||||
|
[sub_resource type="AnimationNodeStateMachineTransition" id="AnimationNodeStateMachineTransition_v8fg0"]
|
||||||
|
advance_mode = 2
|
||||||
|
advance_expression = "_enemyDirection == 0"
|
||||||
|
|
||||||
|
[sub_resource type="AnimationNodeStateMachineTransition" id="AnimationNodeStateMachineTransition_r44fx"]
|
||||||
|
switch_mode = 2
|
||||||
|
advance_mode = 2
|
||||||
|
|
||||||
|
[sub_resource type="AnimationNodeStateMachineTransition" id="AnimationNodeStateMachineTransition_dhuhq"]
|
||||||
|
switch_mode = 2
|
||||||
|
advance_mode = 2
|
||||||
|
|
||||||
|
[sub_resource type="AnimationNodeStateMachineTransition" id="AnimationNodeStateMachineTransition_y4bdd"]
|
||||||
|
switch_mode = 2
|
||||||
|
advance_mode = 2
|
||||||
|
|
||||||
|
[sub_resource type="AnimationNodeStateMachineTransition" id="AnimationNodeStateMachineTransition_syb4h"]
|
||||||
|
switch_mode = 2
|
||||||
|
advance_mode = 2
|
||||||
|
|
||||||
|
[sub_resource type="AnimationNodeStateMachine" id="AnimationNodeStateMachine_8u7he"]
|
||||||
|
states/stop_back_walk/node = SubResource("AnimationNodeAnimation_jbhro")
|
||||||
|
states/stop_back_walk/position = Vector2(516, 203)
|
||||||
|
states/stop_left_walk/node = SubResource("AnimationNodeAnimation_keq07")
|
||||||
|
states/stop_left_walk/position = Vector2(354, 135)
|
||||||
|
states/stop_right_walk/node = SubResource("AnimationNodeAnimation_w4c47")
|
||||||
|
states/stop_right_walk/position = Vector2(687, 135)
|
||||||
|
states/stop_walk_front/node = SubResource("AnimationNodeAnimation_5lbxl")
|
||||||
|
states/stop_walk_front/position = Vector2(516, 72)
|
||||||
|
transitions = ["Start", "stop_walk_front", SubResource("AnimationNodeStateMachineTransition_yu6fp"), "stop_walk_front", "stop_left_walk", SubResource("AnimationNodeStateMachineTransition_djlpo"), "stop_left_walk", "stop_walk_front", SubResource("AnimationNodeStateMachineTransition_t2war"), "stop_walk_front", "stop_back_walk", SubResource("AnimationNodeStateMachineTransition_b16jm"), "stop_back_walk", "stop_walk_front", SubResource("AnimationNodeStateMachineTransition_d1ogr"), "stop_walk_front", "stop_right_walk", SubResource("AnimationNodeStateMachineTransition_7dl50"), "stop_right_walk", "stop_walk_front", SubResource("AnimationNodeStateMachineTransition_y2ova"), "stop_back_walk", "stop_right_walk", SubResource("AnimationNodeStateMachineTransition_8vs7h"), "stop_right_walk", "stop_back_walk", SubResource("AnimationNodeStateMachineTransition_rgja2"), "stop_back_walk", "stop_left_walk", SubResource("AnimationNodeStateMachineTransition_syao6"), "stop_left_walk", "stop_back_walk", SubResource("AnimationNodeStateMachineTransition_3iqav"), "stop_left_walk", "stop_right_walk", SubResource("AnimationNodeStateMachineTransition_ii52r"), "stop_right_walk", "stop_left_walk", SubResource("AnimationNodeStateMachineTransition_v8fg0"), "stop_right_walk", "End", SubResource("AnimationNodeStateMachineTransition_r44fx"), "stop_walk_front", "End", SubResource("AnimationNodeStateMachineTransition_dhuhq"), "stop_back_walk", "End", SubResource("AnimationNodeStateMachineTransition_y4bdd"), "stop_left_walk", "End", SubResource("AnimationNodeStateMachineTransition_syb4h")]
|
||||||
|
|
||||||
[sub_resource type="AnimationNodeStateMachineTransition" id="AnimationNodeStateMachineTransition_umemc"]
|
[sub_resource type="AnimationNodeStateMachineTransition" id="AnimationNodeStateMachineTransition_umemc"]
|
||||||
advance_mode = 2
|
advance_mode = 2
|
||||||
|
|
||||||
@@ -2940,15 +3271,18 @@ advance_mode = 2
|
|||||||
|
|
||||||
[sub_resource type="AnimationNodeStateMachineTransition" id="AnimationNodeStateMachineTransition_w4c47"]
|
[sub_resource type="AnimationNodeStateMachineTransition" id="AnimationNodeStateMachineTransition_w4c47"]
|
||||||
|
|
||||||
[sub_resource type="AnimationNodeStateMachineTransition" id="AnimationNodeStateMachineTransition_5lbxl"]
|
|
||||||
xfade_time = 0.2
|
|
||||||
break_loop_at_end = true
|
|
||||||
switch_mode = 1
|
|
||||||
|
|
||||||
[sub_resource type="AnimationNodeStateMachineTransition" id="AnimationNodeStateMachineTransition_li182"]
|
[sub_resource type="AnimationNodeStateMachineTransition" id="AnimationNodeStateMachineTransition_li182"]
|
||||||
|
|
||||||
[sub_resource type="AnimationNodeStateMachineTransition" id="AnimationNodeStateMachineTransition_sgkk0"]
|
[sub_resource type="AnimationNodeStateMachineTransition" id="AnimationNodeStateMachineTransition_sgkk0"]
|
||||||
|
|
||||||
|
[sub_resource type="AnimationNodeStateMachineTransition" id="AnimationNodeStateMachineTransition_8u7he"]
|
||||||
|
reset = false
|
||||||
|
switch_mode = 1
|
||||||
|
|
||||||
|
[sub_resource type="AnimationNodeStateMachineTransition" id="AnimationNodeStateMachineTransition_8e7of"]
|
||||||
|
switch_mode = 2
|
||||||
|
advance_mode = 2
|
||||||
|
|
||||||
[sub_resource type="AnimationNodeStateMachine" id="AnimationNodeStateMachine_nvqie"]
|
[sub_resource type="AnimationNodeStateMachine" id="AnimationNodeStateMachine_nvqie"]
|
||||||
states/Activate/node = ExtResource("243_5jjkq")
|
states/Activate/node = ExtResource("243_5jjkq")
|
||||||
states/Activate/position = Vector2(583, 100)
|
states/Activate/position = Vector2(583, 100)
|
||||||
@@ -2959,12 +3293,14 @@ states/Idle/position = Vector2(348, 285)
|
|||||||
"states/Secondary Attack/node" = SubResource("AnimationNodeAnimation_op3hf")
|
"states/Secondary Attack/node" = SubResource("AnimationNodeAnimation_op3hf")
|
||||||
"states/Secondary Attack/position" = Vector2(583, 404)
|
"states/Secondary Attack/position" = Vector2(583, 404)
|
||||||
states/Start/position = Vector2(199, 100)
|
states/Start/position = Vector2(199, 100)
|
||||||
|
"states/Stop Walk/node" = SubResource("AnimationNodeStateMachine_8u7he")
|
||||||
|
"states/Stop Walk/position" = Vector2(132.437, 323.65)
|
||||||
"states/Unactivated Idle/node" = ExtResource("245_gr3tp")
|
"states/Unactivated Idle/node" = ExtResource("245_gr3tp")
|
||||||
"states/Unactivated Idle/position" = Vector2(357, 100)
|
"states/Unactivated Idle/position" = Vector2(357, 100)
|
||||||
states/Walking/node = ExtResource("395_jbhro")
|
states/Walking/node = ExtResource("395_jbhro")
|
||||||
states/Walking/position = Vector2(348, 398.498)
|
states/Walking/position = Vector2(348, 398.498)
|
||||||
transitions = ["Start", "Unactivated Idle", SubResource("AnimationNodeStateMachineTransition_umemc"), "Unactivated Idle", "Activate", SubResource("AnimationNodeStateMachineTransition_t3xhd"), "Activate", "Idle", SubResource("AnimationNodeStateMachineTransition_5jjkq"), "Idle", "Secondary Attack", SubResource("AnimationNodeStateMachineTransition_gr3tp"), "Secondary Attack", "Idle", SubResource("AnimationNodeStateMachineTransition_ixs6i"), "Idle", "Primary Attack", SubResource("AnimationNodeStateMachineTransition_jbhro"), "Primary Attack", "Idle", SubResource("AnimationNodeStateMachineTransition_keq07"), "Idle", "Walking", SubResource("AnimationNodeStateMachineTransition_w4c47"), "Walking", "Idle", SubResource("AnimationNodeStateMachineTransition_5lbxl"), "Walking", "Primary Attack", SubResource("AnimationNodeStateMachineTransition_li182"), "Walking", "Secondary Attack", SubResource("AnimationNodeStateMachineTransition_sgkk0")]
|
transitions = ["Start", "Unactivated Idle", SubResource("AnimationNodeStateMachineTransition_umemc"), "Unactivated Idle", "Activate", SubResource("AnimationNodeStateMachineTransition_t3xhd"), "Activate", "Idle", SubResource("AnimationNodeStateMachineTransition_5jjkq"), "Idle", "Secondary Attack", SubResource("AnimationNodeStateMachineTransition_gr3tp"), "Secondary Attack", "Idle", SubResource("AnimationNodeStateMachineTransition_ixs6i"), "Idle", "Primary Attack", SubResource("AnimationNodeStateMachineTransition_jbhro"), "Primary Attack", "Idle", SubResource("AnimationNodeStateMachineTransition_keq07"), "Idle", "Walking", SubResource("AnimationNodeStateMachineTransition_w4c47"), "Walking", "Primary Attack", SubResource("AnimationNodeStateMachineTransition_li182"), "Walking", "Secondary Attack", SubResource("AnimationNodeStateMachineTransition_sgkk0"), "Walking", "Stop Walk", SubResource("AnimationNodeStateMachineTransition_8u7he"), "Stop Walk", "Idle", SubResource("AnimationNodeStateMachineTransition_8e7of")]
|
||||||
graph_offset = Vector2(-196.563, 205.778)
|
graph_offset = Vector2(-196.563, 209.65)
|
||||||
|
|
||||||
[sub_resource type="AtlasTexture" id="AtlasTexture_tawq7"]
|
[sub_resource type="AtlasTexture" id="AtlasTexture_tawq7"]
|
||||||
atlas = ExtResource("395_ymova")
|
atlas = ExtResource("395_ymova")
|
||||||
|
|||||||
@@ -19,7 +19,7 @@ public partial class EnemyLogic
|
|||||||
return To<Idle>();
|
return To<Idle>();
|
||||||
}
|
}
|
||||||
|
|
||||||
public Transition On(in Input.Defeated input) => To<State.Defeated>();
|
public Transition On(in Input.Defeated input) => To<Defeated>();
|
||||||
|
|
||||||
public Transition On(in Input.Idle input)
|
public Transition On(in Input.Idle input)
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -16,14 +16,19 @@ public partial class EnemyLogic
|
|||||||
{
|
{
|
||||||
var enemy = Get<IEnemy>();
|
var enemy = Get<IEnemy>();
|
||||||
if (enemy is IHaveEngagePlayerBehavior engagePlayerEnemy)
|
if (enemy is IHaveEngagePlayerBehavior engagePlayerEnemy)
|
||||||
|
{
|
||||||
engagePlayerEnemy.EngagePlayerBehavior.Engage();
|
engagePlayerEnemy.EngagePlayerBehavior.Engage();
|
||||||
enemy.Idle();
|
Input(new Input.Idle());
|
||||||
|
}
|
||||||
});
|
});
|
||||||
OnDetach(() =>
|
OnDetach(() =>
|
||||||
{
|
{
|
||||||
var enemy = Get<IEnemy>();
|
var enemy = Get<IEnemy>();
|
||||||
if (enemy is IHaveEngagePlayerBehavior engagePlayerEnemy)
|
if (enemy is IHaveEngagePlayerBehavior engagePlayerEnemy)
|
||||||
|
{
|
||||||
engagePlayerEnemy.EngagePlayerBehavior.Disengage();
|
engagePlayerEnemy.EngagePlayerBehavior.Disengage();
|
||||||
|
Input(new Input.Idle());
|
||||||
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -16,13 +16,19 @@ public partial class EnemyLogic
|
|||||||
{
|
{
|
||||||
var enemy = Get<IEnemy>();
|
var enemy = Get<IEnemy>();
|
||||||
if (enemy is IHaveFollowBehavior followEnemy)
|
if (enemy is IHaveFollowBehavior followEnemy)
|
||||||
|
{
|
||||||
followEnemy.FollowBehavior.StartFollow(followEnemy.NavigationAgent);
|
followEnemy.FollowBehavior.StartFollow(followEnemy.NavigationAgent);
|
||||||
|
Input(new Input.Move());
|
||||||
|
}
|
||||||
});
|
});
|
||||||
OnDetach(() =>
|
OnDetach(() =>
|
||||||
{
|
{
|
||||||
var enemy = Get<IEnemy>();
|
var enemy = Get<IEnemy>();
|
||||||
if (enemy is IHaveFollowBehavior followEnemy)
|
if (enemy is IHaveFollowBehavior followEnemy)
|
||||||
|
{
|
||||||
followEnemy.FollowBehavior.StopFollow();
|
followEnemy.FollowBehavior.StopFollow();
|
||||||
|
Input(new Input.Idle());
|
||||||
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -17,13 +17,19 @@ public partial class EnemyLogic
|
|||||||
{
|
{
|
||||||
var enemy = Get<IEnemy>();
|
var enemy = Get<IEnemy>();
|
||||||
if (enemy is IHavePatrolBehavior patrolEnemy)
|
if (enemy is IHavePatrolBehavior patrolEnemy)
|
||||||
|
{
|
||||||
patrolEnemy.PatrolBehavior.StartPatrol();
|
patrolEnemy.PatrolBehavior.StartPatrol();
|
||||||
|
Input(new Input.Move());
|
||||||
|
}
|
||||||
});
|
});
|
||||||
OnDetach(() =>
|
OnDetach(() =>
|
||||||
{
|
{
|
||||||
var enemy = Get<IEnemy>();
|
var enemy = Get<IEnemy>();
|
||||||
if (enemy is IHavePatrolBehavior patrolEnemy)
|
if (enemy is IHavePatrolBehavior patrolEnemy)
|
||||||
|
{
|
||||||
patrolEnemy.PatrolBehavior.StopPatrol();
|
patrolEnemy.PatrolBehavior.StopPatrol();
|
||||||
|
Input(new Input.Idle());
|
||||||
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -0,0 +1 @@
|
|||||||
|
uid://4a7kl281e3bx
|
||||||
1
Zennysoft.Game.Ma/src/map/SpecialFloorType.cs.uid
Normal file
1
Zennysoft.Game.Ma/src/map/SpecialFloorType.cs.uid
Normal file
@@ -0,0 +1 @@
|
|||||||
|
uid://dpxxgjbac71t3
|
||||||
Reference in New Issue
Block a user