//Used to get spine event private void SpineAnimationState_Event(Spine.TrackEntry trackEntry, Spine.Event e) { CastLoopImpactAudioClipInfoClass attackTypeAudioInfo = CharOwner.GetAttackAudio(); if (e.Data.Name.Contains("StopDefending")) { SetAnimationSpeed(0); } else if (e.Data.Name.Contains("FireArrivingParticle")) { CharOwner.ArrivingEvent(); } else if (e.Data.Name.Contains("FireCastParticle")) { if (attackTypeAudioInfo != null) { AudioManagerMk2.Instance.PlaySound(AudioSourceType.Game, attackTypeAudioInfo.Cast, AudioBus.LowPriority, CharOwner.transform); } CharOwner.currentAttackPhase = CurrentAnim.Contains("Atk1") ? AttackPhasesType.Cast_Rapid : AttackPhasesType.Cast_Powerful; CharOwner.FireCastParticles(); } else if (e.Data.Name.Contains("FireBulletParticle")) { if (CharOwner.CharInfo.BaseCharacterType == BaseCharType.CharacterType_Script) { CharOwner.currentAttackPhase = CurrentAnim.Contains("Atk1") ? AttackPhasesType.Bullet_Rapid : AttackPhasesType.Bullet_Powerful; CharOwner.CreateParticleAttack(); } } else if (e.Data.Name.Contains("FireTileAttack") && !trackEntry.Animation.Name.Contains("Loop")) { if (CharOwner.CharInfo.BaseCharacterType != BaseCharType.CharacterType_Script) { CharOwner.currentAttackPhase = CurrentAnim.Contains("Atk1") ? AttackPhasesType.Bullet_Rapid : AttackPhasesType.Bullet_Powerful; CharOwner.CreateTileAttack(); } } }