Fix enemy scene setups
This commit is contained in:
@@ -7,6 +7,7 @@ script = ExtResource("1_qwonp")
|
||||
|
||||
[node name="NavAgent" type="NavigationAgent3D" parent="."]
|
||||
unique_name_in_owner = true
|
||||
target_desired_distance = 2.0
|
||||
path_max_distance = 3.01
|
||||
avoidance_enabled = true
|
||||
radius = 1.5
|
||||
|
||||
@@ -15,11 +15,11 @@ MaxAttack = 20
|
||||
MaxDefense = 1
|
||||
ExpFromDefeat = 50
|
||||
Luck = 0.05
|
||||
TelluricResistance = 0.0
|
||||
AeolicResistance = 0.0
|
||||
HydricResistance = 0.0
|
||||
IgneousResistance = 0.0
|
||||
FerrumResistance = 0.0
|
||||
_telluricResistance = 0.0
|
||||
_aeolicResistance = 0.0
|
||||
_hydricResistance = 0.0
|
||||
_igneousResistance = 0.0
|
||||
_ferrumResistance = 0.0
|
||||
DropsSoulGemChance = 0.75
|
||||
metadata/_custom_type_script = "uid://dnkmr0eq1sij0"
|
||||
|
||||
|
||||
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@@ -35,7 +35,7 @@ public partial class Chinthe : Enemy, IHasPrimaryAttack, ICanPatrol, ICanActivat
|
||||
if (_enemyLogic.Value is not EnemyLogic.State.Activated)
|
||||
return;
|
||||
|
||||
if (_enemyLogic.Value is EnemyLogic.State.FollowPlayer && GlobalPosition.DistanceTo(_player.CurrentPosition) < 2.5f)
|
||||
if (_enemyLogic.Value is EnemyLogic.State.FollowPlayer && GlobalPosition.DistanceTo(_player.CurrentPosition) < 4.5f)
|
||||
_enemyLogic.Input(new EnemyLogic.Input.StartAttacking());
|
||||
if (_enemyLogic.Value is EnemyLogic.State.FollowPlayer && GlobalPosition.DistanceTo(_player.CurrentPosition) > 45f)
|
||||
_enemyLogic.Input(new EnemyLogic.Input.LostPlayer());
|
||||
@@ -43,8 +43,6 @@ public partial class Chinthe : Enemy, IHasPrimaryAttack, ICanPatrol, ICanActivat
|
||||
_enemyLogic.Input(new EnemyLogic.Input.Alerted());
|
||||
|
||||
_navigationAgentClient.CalculateVelocity(GlobalPosition, EnemyModelView.CanMove);
|
||||
|
||||
base._PhysicsProcess(delta);
|
||||
}
|
||||
|
||||
public override void Die()
|
||||
|
||||
@@ -67,6 +67,8 @@ autostart = true
|
||||
unique_name_in_owner = true
|
||||
target_position = Vector3(0, 0, -5)
|
||||
collision_mask = 3
|
||||
debug_shape_custom_color = Color(0.60023, 7.84531e-06, 0.405364, 1)
|
||||
debug_shape_thickness = 5
|
||||
|
||||
[node name="EnemyModelView" parent="." instance=ExtResource("3_ncr2e")]
|
||||
unique_name_in_owner = true
|
||||
|
||||
@@ -1,8 +1,9 @@
|
||||
[gd_scene load_steps=7 format=3 uid="uid://b8ewfgcjv60es"]
|
||||
[gd_scene load_steps=8 format=3 uid="uid://b8ewfgcjv60es"]
|
||||
|
||||
[ext_resource type="Script" uid="uid://h6duv685n6eh" path="res://src/enemy/enemy_types/09. Agi/AgiDemon.cs" id="1_56f32"]
|
||||
[ext_resource type="Resource" uid="uid://2lflwab43lb0" path="res://src/enemy/enemy_types/09. Agi/AgiDemonStats.tres" id="2_qec65"]
|
||||
[ext_resource type="PackedScene" uid="uid://bls3mcsyld4vy" path="res://src/enemy/enemy_types/09. Agi/AgiDemonModelView.tscn" id="3_703e7"]
|
||||
[ext_resource type="PackedScene" uid="uid://pbnsngx5jvrh" path="res://src/enemy/NavigationAgentClient.tscn" id="4_uaeav"]
|
||||
|
||||
[sub_resource type="CapsuleShape3D" id="CapsuleShape3D_cwfph"]
|
||||
radius = 0.226425
|
||||
@@ -26,18 +27,11 @@ PrimaryAttackElementalType = 4
|
||||
SecondaryAttackElementalType = 4
|
||||
_enemyStatResource = ExtResource("2_qec65")
|
||||
|
||||
[node name="CollisionShape3D" type="CollisionShape3D" parent="."]
|
||||
[node name="CollisionShape" type="CollisionShape3D" parent="."]
|
||||
unique_name_in_owner = true
|
||||
transform = Transform3D(-1, 0, -8.74228e-08, 0, 1, 0, 8.74228e-08, 0, -1, 0, 0, 0)
|
||||
shape = SubResource("CapsuleShape3D_cwfph")
|
||||
|
||||
[node name="NavAgent" type="NavigationAgent3D" parent="."]
|
||||
unique_name_in_owner = true
|
||||
path_max_distance = 3.01
|
||||
simplify_path = true
|
||||
avoidance_enabled = true
|
||||
radius = 2.0
|
||||
debug_path_custom_color = Color(1, 0, 0, 1)
|
||||
|
||||
[node name="LineOfSight" type="Area3D" parent="."]
|
||||
unique_name_in_owner = true
|
||||
transform = Transform3D(-1, 0, -8.74228e-08, 0, 1, 0, 8.74228e-08, 0, -1, 0, 0, 0)
|
||||
@@ -71,3 +65,7 @@ collision_mask = 0
|
||||
shape = SubResource("SphereShape3D_8vcnq")
|
||||
|
||||
[node name="EnemyModelView" parent="." instance=ExtResource("3_703e7")]
|
||||
unique_name_in_owner = true
|
||||
|
||||
[node name="NavigationAgentClient" parent="." instance=ExtResource("4_uaeav")]
|
||||
unique_name_in_owner = true
|
||||
|
||||
@@ -1,8 +1,9 @@
|
||||
[gd_scene load_steps=8 format=3 uid="uid://dpq17ej06uah1"]
|
||||
[gd_scene load_steps=9 format=3 uid="uid://dpq17ej06uah1"]
|
||||
|
||||
[ext_resource type="Script" uid="uid://h6duv685n6eh" path="res://src/enemy/enemy_types/09. Agi/AgiDemon.cs" id="1_wbopj"]
|
||||
[ext_resource type="PackedScene" uid="uid://cu7n814hhtjwm" path="res://src/enemy/enemy_types/9b. Aqueos Demon/AqueosModelView.tscn" id="2_0hbxv"]
|
||||
[ext_resource type="Script" uid="uid://dnkmr0eq1sij0" path="res://src/enemy/EnemyStatResource.cs" id="2_wtipe"]
|
||||
[ext_resource type="PackedScene" uid="uid://pbnsngx5jvrh" path="res://src/enemy/NavigationAgentClient.tscn" id="4_m7ocm"]
|
||||
|
||||
[sub_resource type="Resource" id="Resource_m7ocm"]
|
||||
script = ExtResource("2_wtipe")
|
||||
@@ -47,18 +48,11 @@ SecondaryAttackElementalDamageBonus = null
|
||||
_enemyStatResource = SubResource("Resource_m7ocm")
|
||||
_movementSpeed = null
|
||||
|
||||
[node name="CollisionShape3D" type="CollisionShape3D" parent="."]
|
||||
[node name="CollisionShape" type="CollisionShape3D" parent="."]
|
||||
unique_name_in_owner = true
|
||||
transform = Transform3D(-1, 0, -8.74228e-08, 0, 1, 0, 8.74228e-08, 0, -1, 0, 0, 0)
|
||||
shape = SubResource("CapsuleShape3D_cwfph")
|
||||
|
||||
[node name="NavAgent" type="NavigationAgent3D" parent="."]
|
||||
unique_name_in_owner = true
|
||||
path_max_distance = 3.01
|
||||
simplify_path = true
|
||||
avoidance_enabled = true
|
||||
radius = 2.0
|
||||
debug_path_custom_color = Color(1, 0, 0, 1)
|
||||
|
||||
[node name="LineOfSight" type="Area3D" parent="."]
|
||||
unique_name_in_owner = true
|
||||
transform = Transform3D(-1, 0, -8.74228e-08, 0, 1, 0, 8.74228e-08, 0, -1, 0, 0, 0)
|
||||
@@ -93,3 +87,6 @@ shape = SubResource("SphereShape3D_8vcnq")
|
||||
|
||||
[node name="EnemyModelView" parent="." instance=ExtResource("2_0hbxv")]
|
||||
unique_name_in_owner = true
|
||||
|
||||
[node name="NavigationAgentClient" parent="." instance=ExtResource("4_m7ocm")]
|
||||
unique_name_in_owner = true
|
||||
|
||||
@@ -1,14 +1,14 @@
|
||||
@startuml EnemyLogic
|
||||
state "EnemyLogic State" as Zennysoft_Game_Ma_EnemyLogic_State {
|
||||
state "Defeated" as Zennysoft_Game_Ma_EnemyLogic_State_Defeated
|
||||
state "Alive" as Zennysoft_Game_Ma_EnemyLogic_State_Alive {
|
||||
state "Activated" as Zennysoft_Game_Ma_EnemyLogic_State_Activated {
|
||||
state "Attacking" as Zennysoft_Game_Ma_EnemyLogic_State_Attacking
|
||||
state "FollowPlayer" as Zennysoft_Game_Ma_EnemyLogic_State_FollowPlayer
|
||||
state "Attacking" as Zennysoft_Game_Ma_EnemyLogic_State_Attacking
|
||||
state "Patrolling" as Zennysoft_Game_Ma_EnemyLogic_State_Patrolling
|
||||
}
|
||||
state "Idle" as Zennysoft_Game_Ma_EnemyLogic_State_Idle
|
||||
}
|
||||
state "Defeated" as Zennysoft_Game_Ma_EnemyLogic_State_Defeated
|
||||
}
|
||||
|
||||
Zennysoft_Game_Ma_EnemyLogic_State_Alive --> Zennysoft_Game_Ma_EnemyLogic_State_Attacking : AttackTimer
|
||||
|
||||
Reference in New Issue
Block a user