Esempio n. 1
0
        void Start()
        {
            //设置自动锁屏
            Screen.sleepTimeout = 60;
            //            PlayerPrefs.DeleteAll();
            //            GetObjectSample.GetObject("AsyncGetObject");
            //事件通知
            InitBaseClasses();
            //加载基础代码
            InitSigletonMonos();
            //为下面的配置类中事件,完成添加方法执�?
            InitListener();

            //加载配置文件,配置类中有事�?
            InitConfigs();
            //初始model
            InitModels();
            //注册网络组件方法
            InitControllers();
            //加载配置文件后才能打开
            //            ViewMgr.Instance.Open(ViewNames.PayChooseView);
            //没有key则为第一次登录
            if (isDebug)
            {
                PlayerPrefs.DeleteAll();
            }

            if (!PlayerSave.HasKey("isFirstLogin"))
            {
                isfirstLogin = true;
                //是第一
                PlayerSave.SetInt("isFirstLogin", 1);
            }
//            string pAlipayOrder = AlipayOrderMgr.Instance.GetAlipayOrder();

//            Debug.Log(string.Format("<color=#ffffffff><---{0}-{1}----></color>", pAlipayOrder, "test1"));

            //            //开发者模式
            //            if (isDebug)
            //            {
            //                isfirstLogin = true;
            //
            //            }
            //                        string  encrycode=  EncryptManager.EncryptDES("isFirstLogin", "98765432");
            //                        string  decrycode=  EncryptManager.DecryptDES(encrycode, "98765432");
            //
            //                        Debug.Log(string.Format("<color=#ffffffff><---{0}-{1}----></color>", encrycode, decrycode));
            MusicSetting();
        }
Esempio n. 2
0
        public override void OnClose()
        {
            GlobalDispatcher.Instance.RemoveListener(GlobalEvent.OnRegionsConfigLoadDone, DataSet);
            CommitController.Instance.GetDispatcher().RemoveListener(CommitController.CommitControllerEvent.OnPostageCallback, OnReflashPostage);

            PlayerSave.SetString("name", inputName.text);
            PlayerSave.SetString("address", inputAddress.text);
            PlayerSave.SetString("beaty", inputBeaty.text);
            PlayerSave.SetString("phone", inputPhone.text);
            PlayerSave.SetInt("province", Provincedropdown.value);
            PlayerSave.SetInt("city", CityDropDown.value);
            PlayerSave.SetInt("country", CountryDropDown.value);
            PlayerSave.SetInt("pinpai", PinPaiDropDown.value);


            StoreController.Instance.currentSellID     = 0;
            StoreController.Instance.currentSellNumber = 0;
            base.OnClose();
        }
Esempio n. 3
0
 //点击音效开关
 private void OnClickAudioToggle(bool isOn)
 {
     MusicManager.Instance.IsMute = !isOn;
     PlayerSave.SetInt("ismute", MusicManager.Instance.IsMute?1:0);
 }