コード例 #1
0
        public static List <AKEventCfg> Gather()
        {
            if (dict.Count == 0)
            {
                dict.Add(1, AudioConfigSimulator.SimAKEventCfg1());

                dict.Add(2, AudioConfigSimulator.SimAKEventCfg2());
            }

            return(dict.Values.ToList <AKEventCfg>());
        }
コード例 #2
0
        /// <summary>
        /// 枪械模式更换
        /// </summary>
        /// <param name="weaponState"></param>
        public static void PerformOnGunModelSwitch(CommonFireConfig comCfg, WeaponLogic.IPlayerWeaponState weaponState)
        {
            if (AudioInfluence.IsForbidden || AKAudioEntry.Dispatcher == null)
            {
                return;
            }
            // NewWeaponConfigItem weaponCfg = WeaponConfigManager.Instance.GetConfigById(weaponState.CurrentWeapon);
            //   var fireModelCfg = WeaponConfigManager.Instance.GetFireModeCountById(weaponState.CurrentWeapon);
            AKEventCfg evtCfg = AudioConfigSimulator.SimAKEventCfg1();

            testWeaponModel = testWeaponModel == "Gun_shot_mode_type_single" ? "Gun_shot_mode_type_triple" : "Gun_shot_mode_type_single";
            AKAudioEntry.Dispatcher.VarySwitchState(evtCfg.switchGroup, testWeaponModel, weaponState.CurrentWeaponGo);
        }