internal static void PlayMeleeAttack(int weaponId, AudioGrp_MeleeAttack op, AkGameObj target, ref int audioEventId) { AudioEventItem evtConfig = SingletonManager.Get <AudioWeaponManager>().FindById(weaponId, FilterLeft1); if (evtConfig != null) { AudioEntry.Dispatcher.SetSwitch(target, op); AudioEntry.Dispatcher.PostEvent(evtConfig, target, true); audioEventId = evtConfig.Id; } else { AudioEntry.Logger.ErrorFormat("Audio Post event failed,target:{0},evtCfg:{1}", target, weaponId); } }
internal void SetSwitch(AkGameObj target, AudioGrp_MeleeAttack meleeAttack) { SetSwitch(target, (int)AudioGrp_MeleeAttack.Id, (int)meleeAttack); }