Merge branch 'master' of http://192.168.1.20:10010/r/Project_SG_scripts
| | |
| | | errorCode = 1; |
| | | return false; |
| | | } |
| | | if (config.ManLevel > 0 && PlayerDatas.Instance.baseData.ExAttr1 < config.ManLevel) |
| | | { |
| | | errorCode = 5; |
| | | return false; |
| | | } |
| | | return true; |
| | | // return false; |
| | | } |
| | |
| | | case 4: |
| | | SysNotifyMgr.Instance.ShowStringTip(Language.Get("FuncLimit_Mission", TaskManager.Instance.GetNeedFinishTaskCount(config.LimitMissionID))); |
| | | break; |
| | | case 5: |
| | | SysNotifyMgr.Instance.ShowStringTip(Language.Get("FuncLimit_ManLevel", config.ManLevel/10000, config.ManLevel/100%100, config.ManLevel%100)); |
| | | break; |
| | | } |
| | | } |
| | | } |
| | |
| | | return Language.Get("FuncLimit_Realm", RealmConfig.Get(config.LimiRealmLV).Name); |
| | | case 4: |
| | | return Language.Get("FuncLimit_Mission", TaskManager.Instance.GetNeedFinishTaskCount(config.LimitMissionID)); |
| | | case 5: |
| | | return Language.Get("FuncLimit_ManLevel", config.ManLevel/10000, config.ManLevel/100%100, config.ManLevel%100); |
| | | } |
| | | } |
| | | return string.Empty; |
| | |
| | | //--------------------------------------------------------
|
| | | // [Author]: YYL
|
| | | // [ Date ]: 2025年8月28日
|
| | | // [ Date ]: Thursday, November 27, 2025
|
| | | //--------------------------------------------------------
|
| | |
|
| | | using System.Collections.Generic;
|
| | |
| | | public int LimiRealmLV;
|
| | | public int LimitMissionID;
|
| | | public int OpenDay;
|
| | | public int ManLevel;
|
| | | public string Name;
|
| | | public string Desc;
|
| | | public string Icon;
|
| | |
| | |
|
| | | int.TryParse(tables[4],out OpenDay);
|
| | |
|
| | | Name = tables[5];
|
| | | int.TryParse(tables[5],out ManLevel); |
| | |
|
| | | Desc = tables[6];
|
| | | Name = tables[6];
|
| | |
|
| | | Icon = tables[7];
|
| | | Desc = tables[7];
|
| | |
|
| | | Award = ConfigParse.ParseIntArray2Dict(tables[8]); |
| | | Icon = tables[8];
|
| | |
|
| | | Award = ConfigParse.ParseIntArray2Dict(tables[9].Replace("(", "[").Replace(")", "]")); |
| | | }
|
| | | catch (Exception exception)
|
| | | {
|
| | |
| | | if (!FuncOpen.Instance.IsFuncOpen(BattleManager.Instance.passFuncId, true)) |
| | | return; |
| | | |
| | | //主线Boss之外的战斗支持永久特权跳过 |
| | | int passRound = BattleManager.Instance.defaultPassRound; |
| | | var name = battleField.ToString(); |
| | | bool isStoryBossBattleField = name == "StoryBossBattleField"; |
| | | |
| | | // 检查是否为永久特权卡玩家 |
| | | bool hasForeverPrivilege = InvestModel.Instance.IsInvested(InvestModel.foreverCardType); |
| | | if (hasForeverPrivilege && !isStoryBossBattleField) |
| | | |
| | | if (hasForeverPrivilege) |
| | | { |
| | | battleField.ForceFinish(); |
| | | return; |
| | | // 永久特权卡玩家逻辑 |
| | | if (BattleConst.FieldNameToIndex.ContainsKey(name)) |
| | | { |
| | | int index = BattleConst.FieldNameToIndex[name]; |
| | | if (BattleManager.Instance.foreverPrivilegePassDict.ContainsKey(index)) |
| | | { |
| | | passRound = BattleManager.Instance.foreverPrivilegePassDict[index]; |
| | | } |
| | | else |
| | | { |
| | | // 未配置的战场类型,使用普通玩家规则 |
| | | if (BattleManager.Instance.passDict.ContainsKey(index)) |
| | | { |
| | | passRound = BattleManager.Instance.passDict[index]; |
| | | } |
| | | // 否则使用默认配置 |
| | | } |
| | | } |
| | | // 如果战场类型不在 FieldNameToIndex 中,使用默认配置 |
| | | } |
| | | else |
| | | { |
| | | // 普通玩家逻辑 |
| | | if (BattleConst.FieldNameToIndex.ContainsKey(name)) |
| | | { |
| | | int index = BattleConst.FieldNameToIndex[name]; |
| | | if (BattleManager.Instance.passDict.ContainsKey(index)) |
| | | { |
| | | passRound = BattleManager.Instance.passDict[index]; |
| | | } |
| | | // 否则使用默认配置 |
| | | } |
| | | // 如果战场类型不在 FieldNameToIndex 中,使用默认配置 |
| | | } |
| | | |
| | | int passRound = BattleManager.Instance.passRound; |
| | | int nowRound = battleField.round; |
| | | if (nowRound < passRound) |
| | | { |
| | |
| | | battleField.ForceFinish(); |
| | | } |
| | | |
| | | |
| | | |
| | | |
| | | /// <summary> |
| | | /// 改变速度 |
| | | /// </summary> |
| | |
| | | { "TianziBillboradBattleField", "TianziBillboradBattleWin" }, |
| | | }; |
| | | |
| | | public static Dictionary<string, int> FieldNameToIndex = new Dictionary<string, int>() |
| | | { |
| | | { "StoryBossBattleField", 1 }, |
| | | { "ArenaBattleField", 2 }, |
| | | { "BoneBattleField", 3}, |
| | | { "TianziBillboradBattleField", 4 }, |
| | | }; |
| | | |
| | | public const int BattleStartEffectID = 1001; // Example effect ID for battle start |
| | | |
| | | public const int skillMotionFps = 30; |
| | |
| | | } |
| | | public readonly int[] speedIndexfuncIdArr = new int[] { 34, 35, 36 }; // 战斗倍数对应的功能ID |
| | | public readonly int passFuncId = 33; // 跳过战斗对应的功能ID |
| | | public int passRound; // 超过X回合可跳过 |
| | | |
| | | public int defaultPassRound; |
| | | public Dictionary<int, int> passDict = new Dictionary<int, int>(); |
| | | public Dictionary<int, int> foreverPrivilegePassDict = new Dictionary<int, int>(); |
| | | |
| | | public int fightGuideID; |
| | | public int fightGuideMainLevelLimit; |
| | | public int fightGuideNoClickSeconds; |
| | |
| | | challengeBossGuides = JsonMapper.ToObject<int[]>(config.Numerical4); |
| | | |
| | | config = FuncConfigConfig.Get("BattleButton"); |
| | | passRound= int.Parse(config.Numerical1); |
| | | defaultPassRound = int.Parse(config.Numerical1); |
| | | passDict = ConfigParse.ParseIntDict(config.Numerical2); |
| | | foreverPrivilegePassDict = ConfigParse.ParseIntDict(config.Numerical3); |
| | | } |
| | | |
| | | |