重做杂兵

This commit is contained in:
SoulliesOfficial
2026-05-11 15:22:30 -04:00
parent 59264706c3
commit 2e00676794
49 changed files with 139495 additions and 70824 deletions

View File

@@ -114,11 +114,11 @@ namespace Cielonos.MainGame.Characters
BattleManager.EnemySm.RemoveEnemy(this);
float deathProcessTime = 0f;
var deathFuncAnim = fullBodyFuncAnims.animDataList.Find(data => data.animInfo.animationName == "Death");
if (deathFuncAnim is not null)
if (deathFuncAnim != null)
{
animationSc.fullBodyFuncAnimSm.Play("Death");
behaviorSc.mainBehaviorTree.StopBehavior();
behaviorSc.navMeshAgent.isStopped = true;
behaviorSc.navMeshAgent.enabled = false;
collisionSc.DisableAllColliders();
deathProcessTime = deathFuncAnim.animationClip.length;
}

View File

@@ -26,6 +26,7 @@ namespace Cielonos.MainGame.Characters
{
base.InitializeSubmodules();
selfTimeSm.coolDownTimers["Attack"] = new Timer(5f);
selfTimeSm.coolDownTimers["NormalAttack"] = new Timer(5f);
selfTimeSm.coolDownTimers["Action"] = new Timer(4f);
selfTimeSm.coolDownTimers["Dodge"] = new Timer(5f);
selfTimeSm.coolDownTimers["Block"] = new Timer(5f);

View File

@@ -176,7 +176,7 @@ namespace Cielonos.MainGame.Characters
bulletSpawnerTransform.forward = (player.centerPoint.position - bulletSpawnerTransform.position).normalized;
vfxData.SpawnMuzzleVFX("NormalBullet", bulletSpawnerTransform);
audioSc.audioContainer.PlaySoundFX("NormalBullet_Shoot", bulletSpawnerTransform.position);
//audioSc.audioContainer.PlaySoundFX("NormalBullet_Shoot", bulletSpawnerTransform.position);
Projectile projectile = vfxData.SpawnVFX("NormalBullet", bulletSpawnerTransform).GetComponentInChildren<Projectile>();
projectile.Initialize(this, null, false, 1, Fraction.Player)
@@ -198,7 +198,7 @@ namespace Cielonos.MainGame.Characters
bulletSpawnerTransform.forward = (player.centerPoint.position - bulletSpawnerTransform.position).normalized;
vfxData.SpawnMuzzleVFX("ShockwaveMissile", bulletSpawnerTransform);
audioSc.audioContainer.PlaySoundFX("ShockwaveMissile_Shoot", bulletSpawnerTransform.position);
//audioSc.audioContainer.PlaySoundFX("ShockwaveMissile_Shoot", bulletSpawnerTransform.position);
Projectile projectile = vfxData.SpawnVFX("ShockwaveMissile", bulletSpawnerTransform).GetComponentInChildren<Projectile>();
projectile.Initialize(this, null, false, 1, Fraction.Player)
@@ -220,7 +220,7 @@ namespace Cielonos.MainGame.Characters
bulletSpawnerTransform.forward = (player.centerPoint.position - bulletSpawnerTransform.position).normalized;
vfxData.SpawnMuzzleVFX("PiercingBullet", bulletSpawnerTransform);
audioSc.audioContainer.PlaySoundFX("PiercingBullet_Shoot", bulletSpawnerTransform.position);
//audioSc.audioContainer.PlaySoundFX("PiercingBullet_Shoot", bulletSpawnerTransform.position);
Projectile projectile = vfxData.SpawnVFX("PiercingBullet", bulletSpawnerTransform).GetComponentInChildren<Projectile>();
projectile.Initialize(this, null, false, 1, Fraction.Player)

View File

@@ -42,7 +42,7 @@ namespace Cielonos.MainGame.Characters
{
float distanceVelocity = navMeshAgent.velocity.magnitude;
float angularVelocity = Vector3.Angle(lastDirection, transform.forward) / owner.selfTimeSm.DeltaTime;
moveSpeedZ.targetValue = distanceVelocity + (angularVelocity * 0.1f);
moveSpeedZ.targetValue = distanceVelocity + (angularVelocity * 0.02f);
}
else
{

View File

@@ -6,12 +6,11 @@ namespace Cielonos.MainGame.Characters
{
public class AudioSubcontroller : SubcontrollerBase<CharacterBase>
{
public AudioContainer audioContainer;
//public AudioContainer audioContainer;
public override void Initialize()
{
base.Initialize();
audioContainer ??= owner.GetComponent<AudioContainer>();
}
public void PlayFootStepSound(AnimationEvent animationEvent)