| | |
| | | using System.Collections.Generic;
|
| | | using System.Linq;
|
| | | using System.Text;
|
| | | using Cysharp.Threading.Tasks;
|
| | | using LitJson;
|
| | | using UnityEngine;
|
| | |
|
| | |
|
| | | public partial class GuildManager : GameSystemManager<GuildManager>
|
| | | using Cysharp.Threading.Tasks; |
| | | using LitJson; |
| | | using UnityEngine; |
| | | |
| | | |
| | | public partial class GuildManager : GameSystemManager<GuildManager> |
| | | {
|
| | | // 家族自定义记录类型
|
| | | public const int MemberChangeActionType = 12; //公会变更记录
|
| | |
| | | public int zbgChangFamilyCD;
|
| | | public List<int> cutCntListForTalk = new List<int>();
|
| | | public int familyRecordMaxCount;
|
| | | public const int DefaultEmblemWordCharacterLimit = 1;
|
| | | public Dictionary<string, int> emblemWordCharacterLimitDict = new Dictionary<string, int>();
|
| | |
|
| | | void ParseConfig()
|
| | | {
|
| | |
| | | config = FuncConfigConfig.Get("FamilyBillboardSet");
|
| | | pageCnt = int.Parse(config.Numerical1);
|
| | | queryPointNum = int.Parse(config.Numerical2);
|
| | |
|
| | | config = FuncConfigConfig.Get("FamilyEmblem");
|
| | | emblemWordCharacterLimitDict = JsonMapper.ToObject<Dictionary<string, int>>(config.Numerical1);
|
| | | }
|
| | |
|
| | |
|
| | |
| | | });
|
| | | }
|
| | |
|
| | | public int GetEmblemWordCharacterLimit()
|
| | | {
|
| | | string langId = Language.Id;
|
| | | if (!string.IsNullOrEmpty(langId) && emblemWordCharacterLimitDict.TryGetValue(langId, out int limit) && limit > 0)
|
| | | {
|
| | | return limit;
|
| | | }
|
| | |
|
| | | return DefaultEmblemWordCharacterLimit;
|
| | | }
|
| | |
|
| | | public string LimitEmblemWord(string emblemWord)
|
| | | {
|
| | | if (string.IsNullOrEmpty(emblemWord))
|
| | | {
|
| | | return string.Empty;
|
| | | }
|
| | |
|
| | | int limit = GetEmblemWordCharacterLimit();
|
| | | if (emblemWord.Length <= limit)
|
| | | {
|
| | | return emblemWord;
|
| | | }
|
| | |
|
| | | return emblemWord.Substring(0, limit);
|
| | | }
|
| | |
|
| | | bool CheckEmblemWord(string emblemWord)
|
| | | {
|
| | | if (string.IsNullOrEmpty(emblemWord))
|
| | | {
|
| | | return true;
|
| | | }
|
| | |
|
| | | int limit = GetEmblemWordCharacterLimit();
|
| | | return emblemWord.Length <= limit;
|
| | | }
|
| | |
|
| | |
|
| | |
|
| | |
|
| | |
| | | return;
|
| | | }
|
| | |
|
| | | if (emblemWord.Length > 1)
|
| | | if (!CheckEmblemWord(emblemWord))
|
| | | {
|
| | | //预制体输入框限制,不限任意字符都只能输入1个字
|
| | | return;
|
| | | }
|
| | |
|
| | |
| | | return;
|
| | | }
|
| | |
|
| | | if (GuildAtkDefBatManager.Instance.UpdateAtkDefBatLogInfo(_package))
|
| | | {
|
| | | return;
|
| | | }
|
| | | |
| | | if (PlayerDatas.Instance.baseData.FamilyId != _package.FamilyID)
|
| | | if (GuildAtkDefBatManager.Instance.UpdateAtkDefBatLogInfo(_package)) |
| | | { |
| | | return; |
| | | } |
| | | |
| | | if (PlayerDatas.Instance.baseData.FamilyId != _package.FamilyID) |
| | | {
|
| | | return;
|
| | | }
|
| | |
| | | PublishNotice = 3,
|
| | | Kick = 4,
|
| | |
|
| | | } |
| | | } |