diff --git a/SVSim.BattleEngine/Engine/Cute/NetworkManager.cs b/SVSim.BattleEngine/Engine/Cute/NetworkManager.cs index d3a879b5..02776c8e 100644 --- a/SVSim.BattleEngine/Engine/Cute/NetworkManager.cs +++ b/SVSim.BattleEngine/Engine/Cute/NetworkManager.cs @@ -289,29 +289,6 @@ public class NetworkManager : MonoBehaviour, IManager } } - public IEnumerator Retry() - { - if (lastRequestTask == null) - { - - yield break; - } - if (connectCoroutine != null) - { - StopConnectCoroutine(); - } - connectCoroutine = Connect(showErrorDialog: true); - yield return StartCoroutine(connectCoroutine); - } - - public void GoToStore() - { - lastRequestTask.GotoStore(); - - ClearLastRequestTask(); - - } - private void disposeUnityWebRequest(UnityWebRequest unityWebRequest) { unityWebRequest.Dispose(); diff --git a/SVSim.BattleEngine/Engine/Cute/Toolbox.cs b/SVSim.BattleEngine/Engine/Cute/Toolbox.cs index 95893937..1ae29155 100644 --- a/SVSim.BattleEngine/Engine/Cute/Toolbox.cs +++ b/SVSim.BattleEngine/Engine/Cute/Toolbox.cs @@ -25,6 +25,4 @@ public class Toolbox public static DebugManager DebugManager; - - public static Mutex mute; } diff --git a/SVSim.BattleEngine/Engine/Cute/WebViewManager.cs b/SVSim.BattleEngine/Engine/Cute/WebViewManager.cs index a736872f..0902c008 100644 --- a/SVSim.BattleEngine/Engine/Cute/WebViewManager.cs +++ b/SVSim.BattleEngine/Engine/Cute/WebViewManager.cs @@ -110,15 +110,6 @@ public class WebViewManager : MonoBehaviour } } - public bool CanGoBack() - { - return false; - } - - public void GoBack() - { - } - public void SetCallback(Action cb) { Callback = cb; diff --git a/SVSim.BattleEngine/Engine/DialogBase.cs b/SVSim.BattleEngine/Engine/DialogBase.cs index 88cdc8f2..9e9e40a4 100644 --- a/SVSim.BattleEngine/Engine/DialogBase.cs +++ b/SVSim.BattleEngine/Engine/DialogBase.cs @@ -10,23 +10,18 @@ using Wizard.UI.Dialog.ImageSelection; public class DialogBase : MonoBehaviour { - public enum DialogScene { OPEN, WAIT, CLOSE } + public enum DialogScene { } public enum Size { S, M, L, XL } public enum ButtonLayout { - NONE, OkBtn, DecisionBtn, CloseBtn, BackToTitleBtn, GrayBtn, RedBtn, - YellowBtn, BlueBtn_CancelBtn, RedBtn_CancelBtn, BlueBtn_GrayBtn, - BlueBtn_RedBtn, GrayBtn_GrayBtn, BlueBtn_RedBtn_GrayBtn, - GrayBtn_CancelBtn_BlueBtn, GrayBtn_GrayBtn_BlueBtn, BattleEvolveConfirm, - BlueButton, BlueButton_BlueButton, BlueButton_BlueButton_BlueButton - } + NONE, OkBtn, DecisionBtn, CloseBtn, GrayBtn, BlueBtn_CancelBtn, RedBtn_CancelBtn, BlueBtn_GrayBtn, BlueBtn_RedBtn_GrayBtn, + GrayBtn_CancelBtn_BlueBtn, BlueButton } public enum ButtonType { - Blue, Gray, Red, Yellow, OK, Decision, Close, Cancel, - Retry, BackToTitle, BackToHome, QuitApplication, VersionUp, RecommendedList +OK, Close, Retry, BackToTitle, BackToHome, QuitApplication, VersionUp, RecommendedList } // Callback fields @@ -66,27 +61,21 @@ public class DialogBase : MonoBehaviour public void AddButton(ButtonType type, Action callback = null) { } public void AddButton(ButtonType type, bool isReflect) { } public void SetScrollViewActive(bool b) { } - public void SetReturnMsg(string msg) { } public void SetReturnMsg(string msg, string s) { } public void SetReturnMsg(GameObject go, string a, string b) { } public void SetReturnMsg(GameObject go, string a, string b, string c, string d) { } public void SetButtonText(string text) { } public void SetButtonText(string text1, string text2) { } public void SetButtonText(string text1, string text2, string text3) { } - public void SetButtonText(ButtonType type, string text) { } public void SetButtonDelegate(Action callback) { } public void SetButtonDelegate(EventDelegate del) { } - public void SetButtonDelegate(ButtonType type, Action callback = null) { } public void SetButtonDisable(bool isEnableOK, bool isEnableCancel = false) { } public void SetDialogNoClose() { } - public void SetDialogNoClose(bool noClose) { } public void SetLayer(string layerName) { } - public void SetLayer(int layer) { } public void SetObj(GameObject obj) { } public void SetBackViewLayer(int layer) { } public void SetBackViewToNotCloseDialog() { } public void SetPanelSortingOrder(int order) { } - public void SetVisibleContactButton(bool isVisible) { } public void SetVisibleContactButton(bool isVisible, string errorId) { } public void AttachToScrollView(Transform t) { } diff --git a/SVSim.BattleEngine/Engine/DialogSupport.cs b/SVSim.BattleEngine/Engine/DialogSupport.cs deleted file mode 100644 index f817277a..00000000 --- a/SVSim.BattleEngine/Engine/DialogSupport.cs +++ /dev/null @@ -1,82 +0,0 @@ -using Cute; -using UnityEngine; -using UnityEngine.Networking; -using Wizard; - -public class DialogSupport : MonoBehaviour -{ - private enum Info - { - AppVersion, - OsVersion, - Device - } - - private GameObject[] _items; - - private const string DEVICE = "&device="; - - public string ErrorCode { get; set; } - - public static DialogBase Create(string errorCode = null) - { - DialogBase dialogBase = UIManager.GetInstance().CreateDialogClose(); - dialogBase.SetSize(DialogBase.Size.XL); - SystemText systemText = Data.SystemText; - dialogBase.SetTitleLabel(systemText.Get("Contact_Dialog_001_Header")); - dialogBase.SetButtonLayout(DialogBase.ButtonLayout.OkBtn); - dialogBase.SetButtonText(systemText.Get("Contact_Dialog_001_Button")); - GameObject gameObject = Object.Instantiate(UIManager.GetInstance().SupportDialogPrefab); - dialogBase.SetObj(gameObject); - DialogSupport ds = gameObject.GetComponent(); - ds.ErrorCode = errorCode; - dialogBase.onPushButton1 = delegate - { - string url = ds.GetUrl(); - UIManager.GetInstance().WebViewHelper.PrepareOpenUrl(delegate - { - LocalLog.SendAllClientTraceLog(delegate - { - BrowserURL.Open(url); - }); - }); - }; - return dialogBase; - } - - private bool IsChecked(Info info) - { - if ((int)info >= _items.Length) - { - return false; - } - return _items[(int)info].GetComponentInChildren().normalSprite == "btn_check_on"; - } - - public string GetUrl() - { - string key = "URL_0013_steam"; - string text = Data.SystemText.Get(key); - // PlayerStaticData.UserViewerID read stripped in Phase-1 UI cull. GetUrl runs from a - // client-side report dialog; headless never invokes it. - if (IsChecked(Info.AppVersion)) - { - text = text + "&appver=" + Toolbox.DeviceManager.GetAppVersionName(); - } - if (IsChecked(Info.OsVersion)) - { - string osVersion = Toolbox.DeviceManager.GetOsVersion(); - text = text + "&osver=" + UnityWebRequest.EscapeURL(osVersion); - } - if (IsChecked(Info.Device)) - { - text = text + "&device=" + UnityWebRequest.EscapeURL(Toolbox.DeviceManager.GetDeviceName()); - text += UnityWebRequest.EscapeURL("/" + Toolbox.DeviceManager.GetGraphicsDeviceName()); - } - if (ErrorCode != null) - { - text = text + "&errorcode=" + ErrorCode; - } - return text; - } -} diff --git a/SVSim.BattleEngine/Engine/NguiObjs.cs b/SVSim.BattleEngine/Engine/NguiObjs.cs index 0bfd38e7..37a6c774 100644 --- a/SVSim.BattleEngine/Engine/NguiObjs.cs +++ b/SVSim.BattleEngine/Engine/NguiObjs.cs @@ -7,9 +7,6 @@ public class NguiObjs : MonoBehaviour [SerializeField] public List objs; - [SerializeField] - public UISprite[] sprites; - [SerializeField] public UITexture[] textures; diff --git a/SVSim.BattleEngine/Engine/UIScrollView.cs b/SVSim.BattleEngine/Engine/UIScrollView.cs index 4bc6d554..49346e54 100644 --- a/SVSim.BattleEngine/Engine/UIScrollView.cs +++ b/SVSim.BattleEngine/Engine/UIScrollView.cs @@ -155,19 +155,6 @@ public class UIScrollView : MonoBehaviour } } - public virtual bool shouldMoveVertically - { - get - { - float num = bounds.size.y; - if (mPanel.clipping == UIDrawCall.Clipping.SoftClip) - { - num += mPanel.clipSoftness.y * 2f; - } - return Mathf.RoundToInt(num - mPanel.height) > 0; - } - } - protected virtual bool shouldMove { get diff --git a/SVSim.BattleEngine/Engine/Wizard/FilteringImageSelection.cs b/SVSim.BattleEngine/Engine/Wizard/FilteringImageSelection.cs index 0dc0ff41..b0e4fb6b 100644 --- a/SVSim.BattleEngine/Engine/Wizard/FilteringImageSelection.cs +++ b/SVSim.BattleEngine/Engine/Wizard/FilteringImageSelection.cs @@ -918,36 +918,6 @@ public class FilteringImageSelection : MonoBehaviour return dataList.Any((ItemData data) => data.IsLoaded()); } - public void DestroyDialogCloseButtonCopy() - { - if (_dialogCloseButtonCopy != null) - { - UnityEngine.Object.Destroy(_dialogCloseButtonCopy.gameObject); - _dialogCloseButtonCopy = null; - } - } - - public void RegisterFavoriteChanges() - { - IEnumerable enumerable = from x in _dataList - where x.IsFavorite - select long.Parse(x._key); - IEnumerable favorites = GetFavorites(); - IEnumerable remove = favorites.Except(enumerable); - IEnumerable add = enumerable.Except(favorites); - if (remove.IsNotNullOrEmpty() || add.IsNotNullOrEmpty()) - { - string[] remove2 = remove.Select((long x) => x.ToString()).ToArray(); - string[] add2 = add.Select((long x) => x.ToString()).ToArray(); - FavoriteTask favoriteTask = new FavoriteTask(TaskKind); - favoriteTask.SetParameter(add2, remove2); - UIManager.GetInstance().StartCoroutine(Toolbox.NetworkManager.Connect(favoriteTask, delegate - { - UpdateFavoriteFlag(add, remove); - })); - } - } - protected virtual void UpdateFavoriteFlag(IEnumerable added, IEnumerable removed) { } diff --git a/SVSim.BattleEngine/Engine/Wizard/LocalLog.cs b/SVSim.BattleEngine/Engine/Wizard/LocalLog.cs index 6d666e7d..1e39c195 100644 --- a/SVSim.BattleEngine/Engine/Wizard/LocalLog.cs +++ b/SVSim.BattleEngine/Engine/Wizard/LocalLog.cs @@ -100,11 +100,6 @@ public class LocalLog } } - public static void SendAllClientTraceLog(Action onSended) - { - MakeTreceLogToSend(TRACELOG_TYPE.TRACE_ALL_LOG, onSended); - } - public static void SendLastTraceLog(Action onSended) { MakeTreceLogToSend(TRACELOG_TYPE.TRACE_LAST_LOG, onSended); diff --git a/SVSim.BattleEngine/Engine/Wizard/TransformBackup.cs b/SVSim.BattleEngine/Engine/Wizard/TransformBackup.cs deleted file mode 100644 index a715d367..00000000 --- a/SVSim.BattleEngine/Engine/Wizard/TransformBackup.cs +++ /dev/null @@ -1,30 +0,0 @@ -using UnityEngine; - -namespace Wizard; - -internal class TransformBackup -{ - public Transform backup_parent { get; private set; } - - public Vector3 backup_pos { get; private set; } - - public Vector3 backup_scale { get; private set; } - - public int backup_layer { get; private set; } - - public void Save(Transform trans) - { - backup_parent = trans.parent; - backup_pos = trans.localPosition; - backup_scale = trans.localScale; - backup_layer = trans.gameObject.layer; - } - - public void Restore(Transform trans) - { - trans.parent = backup_parent; - trans.localPosition = backup_pos; - trans.localScale = backup_scale; - trans.gameObject.layer = backup_layer; - } -} diff --git a/SVSim.BattleEngine/Engine/Wizard/WebViewHelper.cs b/SVSim.BattleEngine/Engine/Wizard/WebViewHelper.cs index efb7e48e..bfcfeb71 100644 --- a/SVSim.BattleEngine/Engine/Wizard/WebViewHelper.cs +++ b/SVSim.BattleEngine/Engine/Wizard/WebViewHelper.cs @@ -202,64 +202,6 @@ public class WebViewHelper return false; } - public DialogBase CreateOpenURLWindow(UrlType type) - { - string applicationServerURL = CustomPreference.GetApplicationServerURL(); - string text = "?lang=" + CustomPreference.GetTextLanguage(); - string openUrl = null; - string key = null; - DialogBase dialogBase = UIManager.GetInstance().CreateDialogClose(); - SystemText systemText = Data.SystemText; - switch (type) - { - case UrlType.POLICY: - dialogBase.SetPanelDepth(3000); - openUrl = applicationServerURL + "information/policy" + text; - key = "OtherTop_0009"; - break; - case UrlType.FACEBOOK: - key = "Account_0038"; - break; - case UrlType.RECOMMENDED_DEVICE: - key = "Common_0134"; - openUrl = "https://shadowverse.jp/device.php"; - break; - case UrlType.GAME_GUIDE: - openUrl = systemText.Get("URL_0012_steam"); - key = "OtherTop_0021"; - break; - case UrlType.NICONICO: - dialogBase.SetPanelDepth(3000); - key = "VideoHosting_0034"; - openUrl = "https://account.nicovideo.jp/rules/account"; - break; - case UrlType.NICONICO_PUBLISH: - dialogBase.SetPanelDepth(3000); - key = "VideoHosting_0035"; - openUrl = "http://live.nicovideo.jp/static/rule.html"; - break; - } - dialogBase.SetTitleLabel(systemText.Get(key)); - dialogBase.SetText(systemText.Get("Common_0208")); - dialogBase.SetButtonLayout(DialogBase.ButtonLayout.BlueBtn_CancelBtn); - dialogBase.SetButtonText(systemText.Get("Dia_Web_001_Button")); - dialogBase.onPushButton1 = delegate - { - PrepareOpenUrl(delegate - { - if (type == UrlType.FACEBOOK) - { - UIManager.GetInstance().AccountTransferHelper.DataTransferByFaceBook(); - } - else - { - BrowserURL.Open(openUrl); - } - }); - }; - return dialogBase; - } - public void PrepareOpenUrl(Action onFinish) { onFinish(); diff --git a/SVSim.BattleEngine/Shim/Generated/ApplicationFinishManager.g.cs b/SVSim.BattleEngine/Shim/Generated/ApplicationFinishManager.g.cs index b4f48737..e069abc2 100644 --- a/SVSim.BattleEngine/Shim/Generated/ApplicationFinishManager.g.cs +++ b/SVSim.BattleEngine/Shim/Generated/ApplicationFinishManager.g.cs @@ -8,6 +8,5 @@ namespace Wizard { public partial class ApplicationFinishManager { - public DialogBase QuitDialog { get; set; } } } diff --git a/SVSim.BattleEngine/Shim/Generated/UIManager.g.cs b/SVSim.BattleEngine/Shim/Generated/UIManager.g.cs index 57547ad5..e79c9434 100644 --- a/SVSim.BattleEngine/Shim/Generated/UIManager.g.cs +++ b/SVSim.BattleEngine/Shim/Generated/UIManager.g.cs @@ -48,18 +48,15 @@ public partial class UIManager public bool isRetryProc; public bool isNoAvailMemory; public Footer _Footer { get; set; } - public ApplicationFinishManager ApplicationFinishManager { get; set; } public GameObject MyPageUICameraObj { get; set; } public NguiObjs TextInputDialogPrefab { get; set; } public DrumrollDialog DrumrollDialogPrefab { get; set; } public DialogBase NowOpenDialog { get; set; } public UIRoot UIRootSystem { get; set; } - public GameObject SupportDialogPrefab { get; set; } public bool isBattleRecovery { get; set; } public WebViewHelper WebViewHelper { get; set; } public bool IsTouchable { get; set; } public AccountTransferHelper AccountTransferHelper { get; set; } - public static void ApplicationQuit() { } public Camera getCamera() => default!; public string GetSceneAssetPath(UIAtlasManager.AssetBundleNames assetname, string singlebundlename = "", bool isload = false) => default!; public void AddResidentAtlas(UIAtlasManager.AssetBundleNames atlasName) { } @@ -87,7 +84,6 @@ public partial class UIManager public void createInSceneCenterLoading(bool notBlack = false, bool notCollider = false, bool force = true, string overrideText = null) { } public void closeInSceneCenterLoading(bool force = true, bool disableCollider = false) { } public LoadingInScene createInSceneLoadingMatching(bool notBlack = false, bool notCollider = false) => default!; - public LoadingInScene CloseInSceneLoadingMatching() => default!; public void createInSceneNotNetwork() { } public void closeInSceneNotNetwork() { } public void CreatFadeClose(Action onFinishCallback = null) { } diff --git a/SVSim.BattleEngine/Shim/UnityEngine/UnityShim.cs b/SVSim.BattleEngine/Shim/UnityEngine/UnityShim.cs index 3f752005..4786bab6 100644 --- a/SVSim.BattleEngine/Shim/UnityEngine/UnityShim.cs +++ b/SVSim.BattleEngine/Shim/UnityEngine/UnityShim.cs @@ -99,7 +99,6 @@ namespace UnityEngine public void StopCoroutine(Coroutine routine) { } public void StopCoroutine(string methodName) { } public void StopAllCoroutines() { } - public void Invoke(string methodName, float time) { } } public partial class Transform : Component, IEnumerable @@ -239,7 +238,6 @@ namespace UnityEngine public T GetComponentInParent(bool includeInactive) => default; public T[] GetComponents() => new T[0]; public T AddComponent() where T : Component => (T)(GetOrAddComponent(typeof(T)) ?? default(T)); - public void SendMessage(string method) { } public void SendMessage(string method, object value, SendMessageOptions options) { } public static GameObject Find(string n) => null; } diff --git a/SVSim.BattleEngine/Shim/UnityEngine/UnityShimExt.cs b/SVSim.BattleEngine/Shim/UnityEngine/UnityShimExt.cs index ee5447ab..d801fe40 100644 --- a/SVSim.BattleEngine/Shim/UnityEngine/UnityShimExt.cs +++ b/SVSim.BattleEngine/Shim/UnityEngine/UnityShimExt.cs @@ -170,7 +170,6 @@ namespace UnityEngine.Networking { public UnityWebRequest() { } public UnityWebRequest(string url, string method) { } - public static string EscapeURL(string s) => s; public static UnityWebRequest Get(string uri) => new UnityWebRequest(); public UnityWebRequestAsyncOperation SendWebRequest() => new UnityWebRequestAsyncOperation(); public void SetRequestHeader(string name, string value) { }