| 1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556 |
- using System.Collections;
- using System.Collections.Generic;
- using UnityEngine;
- using UnityEngine.UI;
- using UnityEngine.SceneManagement;
- /* 设置界面1 */
- public class SetUpView1 : MonoBehaviour
- {
- void Awake() {
- if (CommonConfig.needToExamine) {
- transform.Find("Items/GameSetup").GetComponentInChildren<TextAutoLanguage>().SetText(1234560);
- transform.Find("BtnQuitGame").GetComponentInChildren<TextAutoLanguage>().SetText(1234561);
- }
- }
- public void GoToGameSetupView() {
- AudioMgr.ins.PlayBtn();
- GameObject.Instantiate(Resources.Load<GameObject>("Prefabs/Views/SetUpView"), Vector3.zero, new Quaternion());
- }
- public void AboutUs() {
- AudioMgr.ins.PlayBtn();
- // PopupMgr.ins.ShowTip(TextAutoLanguage2.GetTextByKey("tip_about-us"));
- GameObject.Instantiate(Resources.Load<GameObject>("Prefabs/Views/AboutUsView"), transform);
- }
- public void GoToUserAgreement() {
- AudioMgr.ins.PlayBtn();
- GameObject o = GameObject.Instantiate(Resources.Load<GameObject>("Prefabs/Views/AgreementView"));
- o.GetComponent<AgreementView>().EnterUserAgreement();
- }
- public void GoToPrivacyAgreement() {
- AudioMgr.ins.PlayBtn();
- GameObject o = GameObject.Instantiate(Resources.Load<GameObject>("Prefabs/Views/AgreementView"));
- o.GetComponent<AgreementView>().EnterPrivacyAgreement();
- }
- public void QuitGame() {
- AudioMgr.ins.PlayBtn();
- Application.Quit();
- }
- public void QuitLogin()
- {
- AudioMgr.ins.PlayBtn();
- PlayerPrefs.DeleteKey("IdAndToken");
- SceneManager.LoadScene("Login", LoadSceneMode.Single);
- if (UserPlayer.ins != null) UserPlayer.ins.Close();
- }
- public void Back() {
- AudioMgr.ins.PlayBtn();
- Destroy(this.gameObject);
- }
- }
|