Merge branch 'master' of http://192.168.0.87:10010/r/snxxz_scripts
| | |
| | | }
|
| | | }
|
| | |
|
| | | public string GetSplicePackageID()
|
| | | {
|
| | | string _result = null;
|
| | | #if UNITY_ANDROID
|
| | | if (ChannelPlatform == E_ChannelPlatform.Sp)
|
| | | {
|
| | | using (AndroidJavaClass _jc = new AndroidJavaClass("com.sp.sdk.utils.SDKManagerUtils"))
|
| | | {
|
| | | using (AndroidJavaObject _jo = _jc.CallStatic<AndroidJavaObject>("getAssetPropConfig", GetApplicationContext(), "plugin_config.properties"))
|
| | | {
|
| | | _result = _jo.Call<string>("get", "game_id");
|
| | | }
|
| | | }
|
| | | }
|
| | | else if (ChannelPlatform == E_ChannelPlatform.Mr)
|
| | | {
|
| | | using (AndroidJavaClass _jc = new AndroidJavaClass("com.secondworld.univeralsdk.UniversalUtil"))
|
| | | {
|
| | | _result = _jc.CallStatic<string>("getMetaString", "Mr_GAME_ID");
|
| | | }
|
| | | }
|
| | | else if (ChannelPlatform == E_ChannelPlatform.Js)
|
| | | {
|
| | | using (AndroidJavaClass _jc = new AndroidJavaClass("com.secondworld.univeralsdk.UniversalUtil"))
|
| | | {
|
| | | _result = _jc.CallStatic<string>("getMetaString", "LL_APPID");
|
| | | }
|
| | | }
|
| | | #endif
|
| | | return _result;
|
| | | }
|
| | |
|
| | | private void SendMessageToSDK(JsonData json)
|
| | | {
|
| | | #if !UNITY_EDITOR
|
| | |
| | | return;
|
| | | }
|
| | | var playerId = PlayerDatas.Instance.baseData.PlayerID;
|
| | | var path = StringUtility.Contact(Application.persistentDataPath, "//", fileName, "_", playerId, ".log");
|
| | | var path = StringUtility.Contact(ResourcesPath.Instance.ExternalStorePath, fileName, "_", playerId, ".log");
|
| | | using (FileStream fs = new FileStream(path, FileMode.Create, FileAccess.Write))
|
| | | {
|
| | | using (StreamWriter sw = new StreamWriter(fs, Encoding.UTF8))
|
| | |
| | | {
|
| | | Clear();
|
| | | var playerId = PlayerDatas.Instance.baseData.PlayerID;
|
| | | var path = StringUtility.Contact(Application.persistentDataPath, "//", fileName, "_", playerId, ".log");
|
| | | var path = StringUtility.Contact(ResourcesPath.Instance.ExternalStorePath, fileName, "_", playerId, ".log");
|
| | | if (!File.Exists(path))
|
| | | {
|
| | | return;
|
| | |
| | | public int AwardRecord = 0;//领奖记录
|
| | | public int HasSweep = 0;//是否已扫荡
|
| | | public int DayLv = 0;//今日等级
|
| | | public int Cost = 0;//绑玉进入花费
|
| | | public event Action UpdateIceLodeInf;
|
| | | DungeonModel m_Model;
|
| | | DungeonModel model { get { return m_Model ?? (m_Model = ModelCenter.Instance.GetModel<DungeonModel>()); } }
|
| | | public override void Init()
|
| | | {
|
| | | var IceLodeCfg = Config.Instance.Get<FuncConfigConfig>("IceLodeCfg");
|
| | | Cost = int.Parse(IceLodeCfg.Numerical1);
|
| | | Assignment();
|
| | | }
|
| | | public void OnBeforePlayerDataInitialize()
|
| | |
| | | {
|
| | | IceCrystalVeinMiddle.Add(IceCrystalVeinReward[i]);
|
| | | } |
| | | |
| | | } |
| | | |
| | | protected override void AddListeners() |
| | |
| | | {
|
| | | StarAll = iceCrystalVeinModel.GetAllStar();
|
| | | m_ScrollerController.m_Scorller.RefreshActiveCellViews();//刷新可见
|
| | | SetGridBotton();
|
| | | }
|
| | |
|
| | | private void dungeonRecordChangeEvent(int fbId)
|
| | |
| | | {
|
| | | StarAll = iceCrystalVeinModel.GetAllStar();
|
| | | m_ScrollerController.m_Scorller.RefreshActiveCellViews();//刷新可见
|
| | | SetGridBotton();
|
| | | // SetGridBotton();
|
| | | }
|
| | | }
|
| | |
|
| | |
| | | }
|
| | | else//收费
|
| | | {
|
| | | string str = "重复挑战该副本需要消耗50绑玉,确定要重复挑战?";
|
| | | string str = Language.Get("IceCrystal_1");
|
| | | ConfirmCancel.ShowPopConfirm(Language.Get("Mail101"), str, (bool isOk) =>
|
| | | {
|
| | | if (isOk)
|
| | | {
|
| | | int GoldPaper = (int)UIHelper.GetMoneyCnt(2);
|
| | | if (GoldPaper >= 50)
|
| | | if (GoldPaper >= iceCrystalVeinModel.Cost)
|
| | | {
|
| | | EnterTheCopy();
|
| | | }
|
| | |
| | | Text TextStar = ObjChild.transform.Find("Text_Star").GetComponent<Text>();
|
| | | GameObject m_NIKE= ObjChild.transform.Find("NIKE").gameObject;
|
| | | GameObject m_Collar = ObjChild.transform.Find("Collar").gameObject;
|
| | | TextStar.text = StarAll + "/" + IceLode.Star;
|
| | | if (StarAll >= IceLode.Star)
|
| | | {
|
| | | TextStar.text = Language.Get("IceCrystal_G", StarAll, IceLode.Star);
|
| | | }
|
| | | else
|
| | | {
|
| | | TextStar.text = Language.Get("IceCrystal_R", StarAll, IceLode.Star);
|
| | | }
|
| | | m_NIKE.SetActive(false);
|
| | | m_Collar.SetActive(false);
|
| | | bool _bool = MathUtility.GetBitValue((uint)iceCrystalVeinModel.AwardRecord, (ushort)IceLode.Index);
|
| | |
| | | if (WindowCenter.Instance.IsOpen<PowerAddWin>())
|
| | | {
|
| | | WindowCenter.Instance.CloseImmediately<PowerAddWin>();
|
| | | if (prowNum != 0)
|
| | | {
|
| | | prowNum += power;
|
| | | }
|
| | | }
|
| | | WindowCenter.Instance.Open<PowerAddWin>();
|
| | | }
|
| | |
| | | [SerializeField] PositionTween m_NameTween;
|
| | | [SerializeField] UIAlphaTween m_DungeonAlphaTween;
|
| | |
|
| | | [SerializeField] float m_SelectHeight = 253f;
|
| | |
|
| | | TreasureModel model
|
| | | {
|
| | | get { return ModelCenter.Instance.GetModel<TreasureModel>(); }
|
| | |
| | | var selectLevel = treasureDungeon.currentLevel == treasureDungeon.maxLevel ?
|
| | | treasureDungeon.maxLevel : (treasureDungeon.currentLevel + 1);
|
| | | var selectPosition = scriptable.GetPosition(selectLevel - 1);
|
| | | var lastPosition = scriptable.GetPosition(treasureDungeon.maxLevel - 1);
|
| | | if (selectPosition.y + (height / 2) * expand <= viewAreaHeight)
|
| | | {
|
| | | m_DungeonsContent.anchoredPosition = Vector3.zero;
|
| | | return;
|
| | | }
|
| | | else if (lastPosition.y - selectPosition.y + height * expand + m_SelectHeight <= viewAreaHeight)
|
| | | {
|
| | | var delta = lastPosition.y + (height / 2) * expand - viewAreaHeight;
|
| | | m_DungeonsContent.anchoredPosition = m_DungeonsContent.localPosition.SetY(-delta);
|
| | | }
|
| | | else
|
| | | {
|
| | | var delta = selectPosition.y + (height / 2) * expand - viewAreaHeight;
|
| | | var delta = selectPosition.y - m_SelectHeight;
|
| | | m_DungeonsContent.anchoredPosition = m_DungeonsContent.localPosition.SetY(-delta);
|
| | | }
|
| | | }
|
| | |
| | | }
|
| | | }
|
| | |
|
| | | public void ResetPotentialLevel()
|
| | | {
|
| | | var list = potentials;
|
| | | if (list != null)
|
| | | {
|
| | | for (int i = 0; i < list.Count; i++)
|
| | | {
|
| | | list[i].level = 0;
|
| | | }
|
| | | }
|
| | | }
|
| | |
|
| | | public void UpdatePotentialLevel(int _potentialId, int _level)
|
| | | {
|
| | | for (int i = 0; i < potentials.Count; i++)
|
| | |
| | | {
|
| | | treasure.state = TreasureState.Locked;
|
| | | treasure.UpdateTreasureLevelExp(0, 0, false);
|
| | | treasure.ResetPotentialLevel();
|
| | | if ((treasure is HumanTreasure))
|
| | | {
|
| | | var humanTreasure = treasure as HumanTreasure;
|