From 3d641e9e352a211e1f45c50d6ab531fe52ca9437 Mon Sep 17 00:00:00 2001 From: gamer147 Date: Fri, 3 Jul 2026 22:33:26 -0400 Subject: [PATCH] cull(engine-cleanup): pass-8 phase-2 cascade round 1 after CardDetailUI stub --- SVSim.BattleEngine/Engine/CardBasePrm.cs | 9 - SVSim.BattleEngine/Engine/CardMake.cs | 31 --- .../Engine/Cute/ResourcesManager.cs | 12 - SVSim.BattleEngine/Engine/DialogBase.cs | 5 - SVSim.BattleEngine/Engine/Timer.cs | 27 -- .../Engine/UIBase_CardManager.cs | 2 - SVSim.BattleEngine/Engine/UICamera.cs | 2 - SVSim.BattleEngine/Engine/UILabel.cs | 12 - .../Engine/VoiceDictionaries.cs | 150 ----------- SVSim.BattleEngine/Engine/VoiceDictionary.cs | 252 ------------------ .../Engine/Wizard/CardCraftPanel.cs | 18 -- .../Engine/Wizard/CardListTemplate.cs | 10 - .../Engine/Wizard/CardParameter.cs | 38 --- .../Engine/Wizard/CardProtectTask.cs | 47 ---- SVSim.BattleEngine/Engine/Wizard/Master.cs | 4 - .../Engine/Wizard/PlayerStaticData.cs | 12 - .../PremiumCardConversionDialogParts.cs | 75 ------ .../Wizard/PremiumCardConversionTask.cs | 38 --- .../Engine/Wizard/PurchaseConfirm.cs | 66 ----- .../Engine/Wizard/TextLineCreater.cs | 46 ---- .../Engine/Wizard/_3dCardFrameManager.cs | 5 - SVSim.BattleEngine/Engine/iTween.cs | 41 --- .../Shim/Generated/BattleLogItem.g.cs | 4 +- .../Shim/Generated/BattlePlayerView.g.cs | 4 - .../Shim/Generated/UIManager.g.cs | 4 - .../Shim/GodObjects/GodObjects.cs | 2 +- .../Shim/UnityEngine/Primitives.cs | 1 - .../Shim/UnityEngine/UnityShim.cs | 4 +- 28 files changed, 4 insertions(+), 917 deletions(-) delete mode 100644 SVSim.BattleEngine/Engine/Timer.cs delete mode 100644 SVSim.BattleEngine/Engine/VoiceDictionaries.cs delete mode 100644 SVSim.BattleEngine/Engine/VoiceDictionary.cs delete mode 100644 SVSim.BattleEngine/Engine/Wizard/CardProtectTask.cs delete mode 100644 SVSim.BattleEngine/Engine/Wizard/PremiumCardConversionDialogParts.cs delete mode 100644 SVSim.BattleEngine/Engine/Wizard/PremiumCardConversionTask.cs delete mode 100644 SVSim.BattleEngine/Engine/Wizard/TextLineCreater.cs diff --git a/SVSim.BattleEngine/Engine/CardBasePrm.cs b/SVSim.BattleEngine/Engine/CardBasePrm.cs index f11e92f5..0597d0a0 100644 --- a/SVSim.BattleEngine/Engine/CardBasePrm.cs +++ b/SVSim.BattleEngine/Engine/CardBasePrm.cs @@ -263,15 +263,6 @@ public static class CardBasePrm return type == CharaType.SPELL; } - public static bool IsAmuletCard(CharaType type) - { - if (type != CharaType.FIELD) - { - return type == CharaType.CHANT_FIELD; - } - return true; - } - public static string GetCardTypeName(CharaType type) { string result = string.Empty; diff --git a/SVSim.BattleEngine/Engine/CardMake.cs b/SVSim.BattleEngine/Engine/CardMake.cs index 480788c9..040c6243 100644 --- a/SVSim.BattleEngine/Engine/CardMake.cs +++ b/SVSim.BattleEngine/Engine/CardMake.cs @@ -21,22 +21,6 @@ public class CardMake : MonoBehaviour private Action _onFinishCardDestruct; - public void StartCardDestruct(int cardId) - { - if (DestructDict == null) - { - DestructDict = new Dictionary(); - } - else - { - DestructDict.Clear(); - } - int possessionCardNum = 0; // Pre-Phase-5b: headless has no user inventory - DestructDict = new Dictionary(); - DestructDict.Add(cardId.ToString(), "1," + possessionCardNum); - DestructCard(); - } - private void DestructCard() { // Pre-Phase-5b: fired CardDestructTask via NetworkManager. Headless has no wire @@ -76,21 +60,6 @@ public class CardMake : MonoBehaviour list = null; } - public void StartCardCraft(int cardId) - { - if (_craftDict == null) - { - _craftDict = new Dictionary(); - } - else - { - _craftDict.Clear(); - } - int possessionCardNum = 0; // Pre-Phase-5b: headless has no user inventory - _craftDict.Add(cardId.ToString(), $"{1},{possessionCardNum}"); - CraftCard(); - } - private void CraftCard() { // Pre-Phase-5b: fired CardCreateTask via NetworkManager. See DestructCard. diff --git a/SVSim.BattleEngine/Engine/Cute/ResourcesManager.cs b/SVSim.BattleEngine/Engine/Cute/ResourcesManager.cs index 2bf80d08..2cefb6b1 100644 --- a/SVSim.BattleEngine/Engine/Cute/ResourcesManager.cs +++ b/SVSim.BattleEngine/Engine/Cute/ResourcesManager.cs @@ -1143,18 +1143,6 @@ public class ResourcesManager : MonoBehaviour, IManager Toolbox.AssetManager.CacheAsset(assetName, requestContext); } - public void StartCoroutine_LoadAssetGroupAsync(List assetList, Action callback, bool isProgress = true) - { - if (assetList == null || assetList.Count == 0) - { - callback?.Invoke(); - } - else - { - StartCoroutine(LoadAssetGroupAsync(assetList, callback, isProgress)); - } - } - public void StartCoroutine_LoadAssetGroupAsync(string asset, Action callback, bool isProgress = true) { StartCoroutine(LoadAssetGroupAsync(new List { asset }, callback, isProgress)); diff --git a/SVSim.BattleEngine/Engine/DialogBase.cs b/SVSim.BattleEngine/Engine/DialogBase.cs index b1e36b88..05d823a9 100644 --- a/SVSim.BattleEngine/Engine/DialogBase.cs +++ b/SVSim.BattleEngine/Engine/DialogBase.cs @@ -1050,11 +1050,6 @@ public class DialogBase : MonoBehaviour backView.layer = layer; } - public void SetBackViewPosition(Vector3 position) - { - backView.transform.localPosition = position; - } - public void SetScrollViewActive(bool b) { scrollView.verticalScrollBar.gameObject.SetActive(b); diff --git a/SVSim.BattleEngine/Engine/Timer.cs b/SVSim.BattleEngine/Engine/Timer.cs deleted file mode 100644 index 009fee68..00000000 --- a/SVSim.BattleEngine/Engine/Timer.cs +++ /dev/null @@ -1,27 +0,0 @@ -using System; -using System.Collections; -using UnityEngine; - -public class Timer -{ - public delegate void OnEndDelegate(); - - public float RemainTimeSec; - - public bool IsEnd { get; protected set; } - - public event OnEndDelegate onEndEvent; - - public Timer(float time, OnEndDelegate onEndEvent) - { - RemainTimeSec = time; - this.onEndEvent = onEndEvent; - IsEnd = false; - } - - public static IEnumerator DelayMethod(float waitTime, Action process) - { - yield return new WaitForSeconds(waitTime); - process?.Invoke(); - } -} diff --git a/SVSim.BattleEngine/Engine/UIBase_CardManager.cs b/SVSim.BattleEngine/Engine/UIBase_CardManager.cs index c1c7638f..22826bd3 100644 --- a/SVSim.BattleEngine/Engine/UIBase_CardManager.cs +++ b/SVSim.BattleEngine/Engine/UIBase_CardManager.cs @@ -65,8 +65,6 @@ public class UIBase_CardManager : MonoBehaviour public bool isPremiere; - public bool off; - public int TotalCardNum => mainCardNum + subCardNum; } diff --git a/SVSim.BattleEngine/Engine/UICamera.cs b/SVSim.BattleEngine/Engine/UICamera.cs index 9cb89fa7..90196e39 100644 --- a/SVSim.BattleEngine/Engine/UICamera.cs +++ b/SVSim.BattleEngine/Engine/UICamera.cs @@ -122,8 +122,6 @@ public class UICamera : MonoBehaviour public static Vector3 lastWorldPosition = Vector3.zero; - public static RaycastHit lastHit; - public static UICamera current = null; public static Camera currentCamera = null; diff --git a/SVSim.BattleEngine/Engine/UILabel.cs b/SVSim.BattleEngine/Engine/UILabel.cs index 798f0599..6bbfb38f 100644 --- a/SVSim.BattleEngine/Engine/UILabel.cs +++ b/SVSim.BattleEngine/Engine/UILabel.cs @@ -751,18 +751,6 @@ public class UILabel : UIWidget } } - public Vector2 printedSize - { - get - { - if (shouldBeProcessed) - { - ProcessText(); - } - return mCalculatedSize; - } - } - public override Vector2 localSize { get diff --git a/SVSim.BattleEngine/Engine/VoiceDictionaries.cs b/SVSim.BattleEngine/Engine/VoiceDictionaries.cs deleted file mode 100644 index f052779c..00000000 --- a/SVSim.BattleEngine/Engine/VoiceDictionaries.cs +++ /dev/null @@ -1,150 +0,0 @@ -using System; -using System.Collections.Generic; -using System.Linq; -using Wizard; - -public class VoiceDictionaries -{ - public VoiceDictionary playVoices; - - public VoiceDictionary evoVoices; - - public VoiceDictionary atkVoices; - - public VoiceDictionary evoAtkVoices; - - public VoiceDictionary destroyVoices; - - public VoiceDictionary evoDestroyVoices; - - public List skillVoices; - - public List evoSkillVoices; - - public List attachSkillVoices; - - public string VoiceId { get; private set; } - - public VoiceDictionaries(int cardId, CardMaster.CardMasterId cardMasterId) - { - CardParameter cardParameterFromId = CardMaster.GetInstance(cardMasterId).GetCardParameterFromId(cardId); - if (cardParameterFromId != null) - { - VoiceDictionary.SettingVoiceData(ref playVoices, (cardParameterFromId.PlayVoice != null) ? cardParameterFromId.PlayVoice : ""); - VoiceDictionary.SettingVoiceData(ref evoVoices, (cardParameterFromId.EvoVoice != null) ? cardParameterFromId.EvoVoice : ""); - VoiceDictionary.SettingVoiceData(ref atkVoices, ref evoAtkVoices, (cardParameterFromId.AtkVoice != null) ? cardParameterFromId.AtkVoice : ""); - VoiceDictionary.SettingVoiceData(ref destroyVoices, ref evoDestroyVoices, (cardParameterFromId.DestroyVoice != null) ? cardParameterFromId.DestroyVoice : ""); - VoiceDictionary.SettingVoiceDataList(out skillVoices, out evoSkillVoices, (cardParameterFromId.SkillVoice != null) ? cardParameterFromId.SkillVoice : ""); - } - attachSkillVoices = new List(); - VoiceId = GetVoiceId(); - } - - private bool GetVoiceIDBeforeUnderBar(VoiceDictionary dic, ref string retVoiceID) - { - string[] allVoiceList = dic.GetAllVoiceList(); - if (allVoiceList.Length == 0) - { - return false; - } - if (string.IsNullOrEmpty(allVoiceList[0])) - { - return false; - } - string text = allVoiceList.FirstOrDefault((string v) => v != "NONE".ToLower()); - if (text == null) - { - return false; - } - retVoiceID = text.Split(new string[1] { "_" }, StringSplitOptions.None)[0]; - return true; - } - - private bool GetVoiceIDListBeforeUnderBar(List dicList, ref string retVoiceID) - { - if (dicList != null && dicList.Count > 0) - { - for (int i = 0; i < dicList.Count; i++) - { - if (GetVoiceIDBeforeUnderBar(dicList[i], ref retVoiceID)) - { - return true; - } - } - } - return false; - } - - private string GetVoiceId() - { - string retVoiceID = ""; - if (GetVoiceIDBeforeUnderBar(playVoices, ref retVoiceID)) - { - return retVoiceID; - } - if (GetVoiceIDBeforeUnderBar(evoVoices, ref retVoiceID)) - { - return retVoiceID; - } - if (GetVoiceIDBeforeUnderBar(atkVoices, ref retVoiceID)) - { - return retVoiceID; - } - if (GetVoiceIDBeforeUnderBar(evoAtkVoices, ref retVoiceID)) - { - return retVoiceID; - } - if (GetVoiceIDBeforeUnderBar(destroyVoices, ref retVoiceID)) - { - return retVoiceID; - } - if (GetVoiceIDBeforeUnderBar(evoDestroyVoices, ref retVoiceID)) - { - return retVoiceID; - } - if (GetVoiceIDListBeforeUnderBar(skillVoices, ref retVoiceID)) - { - return retVoiceID; - } - if (GetVoiceIDListBeforeUnderBar(evoSkillVoices, ref retVoiceID)) - { - return retVoiceID; - } - GetVoiceIDListBeforeUnderBar(attachSkillVoices, ref retVoiceID); - return retVoiceID; - } - - public List GetNormalPlayVoices() - { - List list = playVoices.GetAllVoiceList().ToList(); - List list2 = new List(); - for (int i = 0; i < list.Count; i++) - { - string text = list.ElementAt(i); - if ((text.Contains("_ub") || text.Contains("_sb") || text.Contains("_ssb")) && !text.Contains("_ubp") && !text.Contains("_sbp") && !text.Contains("_ssbp")) - { - if (text.Contains("_ubl")) - { - list[i] = list[i].Replace("_ubl", "_ub"); - } - else if (text.Contains("_sbl")) - { - list[i] = list[i].Replace("_sbl", "_sb"); - } - else if (text.Contains("_ssbl")) - { - list[i] = list[i].Replace("_ssbl", "_ssb"); - } - else - { - list2.Add(text); - } - } - } - foreach (string item in list2) - { - list.Remove(item); - } - return list; - } -} diff --git a/SVSim.BattleEngine/Engine/VoiceDictionary.cs b/SVSim.BattleEngine/Engine/VoiceDictionary.cs deleted file mode 100644 index 269e3ce3..00000000 --- a/SVSim.BattleEngine/Engine/VoiceDictionary.cs +++ /dev/null @@ -1,252 +0,0 @@ -using System; -using System.Collections.Generic; -using System.Linq; - -public class VoiceDictionary -{ - - private VoiceAndWaitTime[] _parsedVoice; - - private string[] _allVoiceID; - - private VoiceAndWaitTime _normalVoice; - - private List _fixedUseCostVoice = new List(); - - private List _unionBurstVoice = new List(); - - private List _skyboundArtVoice = new List(); - - private List _superSkyboundArtVoice = new List(); - - private VoiceAndWaitTime _earthRiteVoice; - - private VoiceAndWaitTime _summonTokenVoice; - - public List EnemyComvoList { get; private set; } - - public List AllyComvoList { get; private set; } - - public VoiceDictionary(string voice) - { - EnemyComvoList = new List(); - AllyComvoList = new List(); - _parsedVoice = new VoiceAndWaitTime[0]; - _allVoiceID = new string[0]; - Initialize(voice); - } - - private void Initialize(string voiceStr) - { - if (string.IsNullOrEmpty(voiceStr)) - { - return; - } - string[] array = voiceStr.Split(new string[1] { "," }, StringSplitOptions.None); - _parsedVoice = new VoiceAndWaitTime[array.Count()]; - _allVoiceID = new string[array.Count()]; - string text = ""; - int i = 0; - for (int num = array.Length; i < num; i++) - { - text = array[i]; - _parsedVoice[i] = ExtractionVoice(text); - _allVoiceID[i] = _parsedVoice[i].Voice; - if (IsConvVoice(text)) - { - string[] array2 = text.Split(new string[1] { "_" }, StringSplitOptions.None); - int num2 = array2.Length - 1; - int item = int.Parse(array2[num2]); - if (text.Contains("_4_") || text.Contains("_7_")) - { - EnemyComvoList.Add(item); - } - else - { - AllyComvoList.Add(item); - } - } - if (_normalVoice == null && IsNormalVoice(text)) - { - _normalVoice = _parsedVoice[i]; - } - if (_unionBurstVoice != null && IsUnionBurstVoice(text)) - { - _unionBurstVoice.Add(_parsedVoice[i]); - } - if (_skyboundArtVoice != null && IsSkyboundArtVoice(text)) - { - _skyboundArtVoice.Add(_parsedVoice[i]); - } - if (_superSkyboundArtVoice != null && IsSuperSkyboundArtVoice(text)) - { - _superSkyboundArtVoice.Add(_parsedVoice[i]); - } - if (IsFixedUseCostVoice(text)) - { - _fixedUseCostVoice.Add(_parsedVoice[i]); - } - if (_earthRiteVoice == null && IsEarthRiteVoice(text)) - { - _earthRiteVoice = _parsedVoice[i]; - } - if (_summonTokenVoice == null && IsSummonTokenVoice(text)) - { - _summonTokenVoice = _parsedVoice[i]; - } - } - } - - public static void SettingVoiceData(ref VoiceDictionary normal, ref VoiceDictionary evolution, string voice) - { - List list = voice.Split(new string[1] { "//" }, StringSplitOptions.None).ToList(); - if (list.Count > 1) - { - normal = new VoiceDictionary(list[0]); - evolution = new VoiceDictionary(list[1]); - } - else if (list.Count == 1 && list[0] != "") - { - normal = new VoiceDictionary(list[0]); - evolution = new VoiceDictionary(string.Empty); - } - else - { - normal = new VoiceDictionary(string.Empty); - evolution = new VoiceDictionary(string.Empty); - } - } - - public static void SettingVoiceDataList(out List normal, out List evolution, string voice) - { - if (voice.IndexOf("//") == 0) - { - voice.Insert(0, "none"); - } - List list = voice.Split(new string[1] { "//" }, StringSplitOptions.None).ToList(); - if (list.Count > 1) - { - normal = CreateVoiceDataList(list[0]); - evolution = CreateVoiceDataList(list[1]); - } - else if (list.Count == 1 && list[0] != "") - { - normal = CreateVoiceDataList(list[0]); - evolution = CreateVoiceDataList(string.Empty); - } - else - { - normal = CreateVoiceDataList(string.Empty); - evolution = CreateVoiceDataList(string.Empty); - } - } - - private static List CreateVoiceDataList(string voice) - { - if (voice == string.Empty) - { - return null; - } - List list = voice.Split(new string[1] { "," }, StringSplitOptions.None).ToList(); - List list2 = null; - if (list.Count > 0) - { - list2 = new List(); - for (int i = 0; i < list.Count; i++) - { - list2.Add(new VoiceDictionary(list[i])); - } - } - return list2; - } - - public static void SettingVoiceData(ref VoiceDictionary normal, string voice) - { - List list = voice.Split(new string[1] { "//" }, StringSplitOptions.None).ToList(); - if (list.Count >= 1 && list[0] != "") - { - normal = new VoiceDictionary(list[0]); - } - else - { - normal = new VoiceDictionary(string.Empty); - } - } - - public string[] GetAllVoiceList() - { - return _allVoiceID; - } - - private bool IsNormalVoice(string voiceName) - { - if (!IsConvVoice(voiceName) && !IsFixedUseCostVoice(voiceName) && !IsUnionBurstVoice(voiceName) && !IsSkyboundArtVoice(voiceName) && !IsSuperSkyboundArtVoice(voiceName) && !IsEarthRiteVoice(voiceName)) - { - return !IsSummonTokenVoice(voiceName); - } - return false; - } - - private bool IsConvVoice(string voiceName) - { - if (voiceName.Contains("_4_")) - { - string[] array = voiceName.Split(new string[1] { "_" }, StringSplitOptions.None); - int result = 0; - int num = array.Length - 1; - if (array.Length > 2 && array[num].Length == 9) - { - return int.TryParse(array[num], out result); - } - return false; - } - if (!voiceName.Contains("_8_")) - { - return voiceName.Contains("_7_"); - } - return true; - } - - private bool IsFixedUseCostVoice(string voiceName) - { - return voiceName.Contains("_enh"); - } - - private bool IsUnionBurstVoice(string voiceName) - { - return voiceName.Contains("_ub"); - } - - private bool IsSkyboundArtVoice(string voiceName) - { - return voiceName.Contains("_sb"); - } - - private bool IsSuperSkyboundArtVoice(string voiceName) - { - return voiceName.Contains("_ssb"); - } - - private bool IsEarthRiteVoice(string voiceName) - { - return voiceName.Contains("_ear"); - } - - private bool IsSummonTokenVoice(string voiceName) - { - return voiceName.EndsWith("_11"); - } - - private VoiceAndWaitTime ExtractionVoice(string order) - { - string text = order; - float waitTime = 0f; - if (text.Contains("{")) - { - List list = text.Split(new string[1] { "{" }, StringSplitOptions.None).ToList(); - waitTime = float.Parse(list[1].Replace("}", "")); - text = list[0]; - } - return new VoiceAndWaitTime(text, waitTime); - } -} diff --git a/SVSim.BattleEngine/Engine/Wizard/CardCraftPanel.cs b/SVSim.BattleEngine/Engine/Wizard/CardCraftPanel.cs index ea205162..4aeb4119 100644 --- a/SVSim.BattleEngine/Engine/Wizard/CardCraftPanel.cs +++ b/SVSim.BattleEngine/Engine/Wizard/CardCraftPanel.cs @@ -29,24 +29,6 @@ public class CardCraftPanel : MonoBehaviour [SerializeField] private UILabel _cantDestructLabel; - public void Init(Action onClickCreateBtn, Action onClickDestructBtn) - { - UIEventListener.Get(_createButton.gameObject).onClick = delegate - { - if (UIManager.GetInstance().IsTouchable) - { - onClickCreateBtn(); - } - }; - UIEventListener.Get(_destructButton.gameObject).onClick = delegate - { - if (UIManager.GetInstance().IsTouchable) - { - onClickDestructBtn(); - } - }; - } - public void UpdateCraftPanel(CardParameter inCardParam, bool isUpdateHaveRedether = true) { SystemText systemText = Data.SystemText; diff --git a/SVSim.BattleEngine/Engine/Wizard/CardListTemplate.cs b/SVSim.BattleEngine/Engine/Wizard/CardListTemplate.cs index 8b69b701..b9f47618 100644 --- a/SVSim.BattleEngine/Engine/Wizard/CardListTemplate.cs +++ b/SVSim.BattleEngine/Engine/Wizard/CardListTemplate.cs @@ -155,11 +155,6 @@ public class CardListTemplate : MonoBehaviour return _num; } - public int GetSpotCardNum() - { - return _spotCardNum; - } - public void ShowNum() { _isHidingNum = false; @@ -179,11 +174,6 @@ public class CardListTemplate : MonoBehaviour SetNum(_num, _spotCardNum); } - public bool IsShowNum() - { - return !_isHidingNum; - } - public void SetFace(bool isUp) { _isFaceUp = isUp; diff --git a/SVSim.BattleEngine/Engine/Wizard/CardParameter.cs b/SVSim.BattleEngine/Engine/Wizard/CardParameter.cs index f809a338..0c936cf4 100644 --- a/SVSim.BattleEngine/Engine/Wizard/CardParameter.cs +++ b/SVSim.BattleEngine/Engine/Wizard/CardParameter.cs @@ -174,30 +174,6 @@ public class CardParameter } } - public string Description - { - get - { - if (_description != null) - { - return _description; - } - return _description = ConvFlavourText(_descriptionId); - } - } - - public string EvoDescription - { - get - { - if (_evoDescription != null) - { - return _evoDescription; - } - return _evoDescription = ConvFlavourText(_evoDescriptionId); - } - } - public string CardVoice { get @@ -380,24 +356,10 @@ public class CardParameter public bool IsCollaboCard => CardSetNameMgr.IsCollaboSetId(int.Parse(CardSetId)); - public bool IsEvolveChoiceCard => CardId.ToString().Substring(0, 3) == "910"; - public bool IsPhantomCard => SealedData.IsPhantomCard(CardId); public bool IsReprintedCard => CardId / 100000000 == 7; - public bool IsEnableFavorite - { - get - { - if (IsBasicCard && NormalCardId == BaseCardId) - { - return false; - } - return true; - } - } - public bool IsPreReleaseCard { get diff --git a/SVSim.BattleEngine/Engine/Wizard/CardProtectTask.cs b/SVSim.BattleEngine/Engine/Wizard/CardProtectTask.cs deleted file mode 100644 index 54fdf46f..00000000 --- a/SVSim.BattleEngine/Engine/Wizard/CardProtectTask.cs +++ /dev/null @@ -1,47 +0,0 @@ -using System.Collections.Generic; - -namespace Wizard; - -public class CardProtectTask : BaseTask -{ - public class CardProtectTaskParam : BaseParam - { - public int card_id; - - public bool is_protected; - } - - private CardProtectTaskParam _param; - - public CardProtectTask() - { - base.type = ApiType.Type.CardProtect; - } - - public void SetParameter(int card_id, bool is_protected) - { - _param = new CardProtectTaskParam(); - _param.card_id = card_id; - _param.is_protected = is_protected; - base.Params = _param; - } - - protected override int Parse() - { - int num = base.Parse(); - if (num != 1) - { - return num; - } - List favoriteCardList = new List(); // Pre-Phase-5b: no favorites headless - if (_param.is_protected) - { - favoriteCardList.Add(_param.card_id); - } - else - { - favoriteCardList.Remove(_param.card_id); - } - return num; - } -} diff --git a/SVSim.BattleEngine/Engine/Wizard/Master.cs b/SVSim.BattleEngine/Engine/Wizard/Master.cs index cb93a7dc..f2dc20a1 100644 --- a/SVSim.BattleEngine/Engine/Wizard/Master.cs +++ b/SVSim.BattleEngine/Engine/Wizard/Master.cs @@ -116,12 +116,8 @@ public class Master private IDictionary CardVoiceTextDic { get; set; } - public List CardDetailVoiceIgnoreList { get; private set; } - private IDictionary PracticeTextDic { get; set; } - public IDictionary> RelationCardSortDic { get; private set; } - public Dictionary> GleamingGemListMaster { get; set; } public Dictionary MyPageCustomBGMaster { get; private set; } diff --git a/SVSim.BattleEngine/Engine/Wizard/PlayerStaticData.cs b/SVSim.BattleEngine/Engine/Wizard/PlayerStaticData.cs index c41c775d..ed3dee38 100644 --- a/SVSim.BattleEngine/Engine/Wizard/PlayerStaticData.cs +++ b/SVSim.BattleEngine/Engine/Wizard/PlayerStaticData.cs @@ -297,18 +297,6 @@ public class PlayerStaticData : MonoBehaviour } } - public static int UserOrbNum - { - get - { - return GetItemNum(1000); - } - set - { - UpdateItemNum(1000, value); - } - } - public static long UserEmblemID { get diff --git a/SVSim.BattleEngine/Engine/Wizard/PremiumCardConversionDialogParts.cs b/SVSim.BattleEngine/Engine/Wizard/PremiumCardConversionDialogParts.cs deleted file mode 100644 index d8fb21b2..00000000 --- a/SVSim.BattleEngine/Engine/Wizard/PremiumCardConversionDialogParts.cs +++ /dev/null @@ -1,75 +0,0 @@ -using UnityEngine; - -namespace Wizard; - -public class PremiumCardConversionDialogParts : MonoBehaviour -{ - [SerializeField] - private UILabel _text2; - - [SerializeField] - private UILabel _textWarning; - - [SerializeField] - private UILabel _beforeOrbNum; - - [SerializeField] - private UILabel _afterOrbNum; - - public void Initialize(CardParameter cardData) - { - SystemText systemText = Data.SystemText; - _text2.text = systemText.Get("Card_0162_3", cardData.CardName); - _beforeOrbNum.text = PlayerStaticData.UserOrbNum.ToString(); - _afterOrbNum.text = systemText.Get("Card_0162_6", (PlayerStaticData.UserOrbNum - 1).ToString()); - SetWarningText(cardData); - } - - private void SetWarningText(CardParameter cardData) - { - if (cardData.IsPreReleaseCard) - { - _textWarning.gameObject.SetActive(value: false); - return; - } - SystemText systemText = Data.SystemText; - if (cardData.IsResurgentCard) - { - _textWarning.gameObject.SetActive(value: true); - _textWarning.text = systemText.Get("Card_0300"); - } - else if (!cardData.IsAvailableFormat(Format.Unlimited, ClassType.None)) - { - _textWarning.gameObject.SetActive(value: true); - _textWarning.text = systemText.Get("Card_0204"); - } - else if (cardData.SameKindNumMaxInUnlimited == 1) - { - _textWarning.gameObject.SetActive(value: true); - _textWarning.text = systemText.Get("Card_0205"); - } - else if (cardData.SameKindNumMaxInUnlimited == 2) - { - _textWarning.gameObject.SetActive(value: true); - _textWarning.text = systemText.Get("Card_0206"); - } - else if (Data.Crossover.IsWithinPracticePeriod) - { - int num = Mathf.Min(cardData.SameKindNumMaxInCrossoverMainClass, cardData.SameKindNumMaxInCrossoverSubClass); - if (num == 0) - { - _textWarning.gameObject.SetActive(value: true); - _textWarning.text = systemText.Get("Card_0277"); - } - else if (num < FormatBehaviorManager.GetDefaultBehaviour(Format.Crossover).DeckSameKindCardNumMax) - { - _textWarning.gameObject.SetActive(value: true); - _textWarning.text = systemText.Get("Card_0278", num.ToString()); - } - } - else - { - _textWarning.gameObject.SetActive(value: false); - } - } -} diff --git a/SVSim.BattleEngine/Engine/Wizard/PremiumCardConversionTask.cs b/SVSim.BattleEngine/Engine/Wizard/PremiumCardConversionTask.cs deleted file mode 100644 index f4fce1a7..00000000 --- a/SVSim.BattleEngine/Engine/Wizard/PremiumCardConversionTask.cs +++ /dev/null @@ -1,38 +0,0 @@ -namespace Wizard; - -public class PremiumCardConversionTask : BaseTask -{ - private class PostParam : BaseParam - { - public int base_card_id; - - public int base_card_number; - - public int create_number; - } - - public PremiumCardConversionTask() - { - base.type = ApiType.Type.PremiumCardConversion; - } - - public void SetParameter(int normalCardId, int normalCardNumber) - { - PostParam postParam = new PostParam(); - postParam.base_card_id = normalCardId; - postParam.base_card_number = normalCardNumber; - postParam.create_number = 1; - base.Params = postParam; - } - - protected override int Parse() - { - int num = base.Parse(); - if (num != 1) - { - return num; - } - PlayerStaticData.UpdateHaveUserGoodsNumByJsonData(base.ResponseData["data"]["reward_list"]); - return num; - } -} diff --git a/SVSim.BattleEngine/Engine/Wizard/PurchaseConfirm.cs b/SVSim.BattleEngine/Engine/Wizard/PurchaseConfirm.cs index 51828545..675499d2 100644 --- a/SVSim.BattleEngine/Engine/Wizard/PurchaseConfirm.cs +++ b/SVSim.BattleEngine/Engine/Wizard/PurchaseConfirm.cs @@ -174,50 +174,6 @@ public class PurchaseConfirm : MonoBehaviour m_LabelAfterItemUnit.text = unit; } - public void SetCardBuy(string moneyKindName, int moneyHave, int moneyUse, CardParameter cardData) - { - SystemText systemText = Data.SystemText; - m_LabelUseItemCnt.text = systemText.Get("Card_0064", moneyUse.ToString()); - m_LabelBuyPack.text = systemText.Get("Card_0077", cardData.CardName); - string text = CheckMyRotationCardBuyCheck(cardData); - if (cardData.IsResurgentCard) - { - SetWarningTextId("Card_0300"); - } - else if (!cardData.IsAvailableFormat(Format.Unlimited, ClassType.None)) - { - SetWarningTextId("Card_0204"); - } - else if (cardData.SameKindNumMaxInUnlimited == 1) - { - SetWarningTextId("Card_0205"); - } - else if (cardData.SameKindNumMaxInUnlimited == 2) - { - SetWarningTextId("Card_0206"); - } - else if (text != null) - { - SetWarningText(text); - } - else if (Data.Crossover.IsWithinPracticePeriod) - { - int num = Mathf.Min(cardData.SameKindNumMaxInCrossoverMainClass, cardData.SameKindNumMaxInCrossoverSubClass); - if (num == 0) - { - SetWarningText(systemText.Get("Card_0277")); - } - else if (num < FormatBehaviorManager.GetDefaultBehaviour(Format.Crossover).DeckSameKindCardNumMax) - { - SetWarningText(systemText.Get("Card_0278", num.ToString())); - } - } - m_LabelItemName.text = systemText.Get("Common_0113"); - int moneyAfter = moneyHave - moneyUse; - SetCardCommon(moneyHave, moneyAfter); - HideJpnLawObj(); - } - private string CheckMyRotationCardBuyCheck(CardParameter cardParameter) { if (!Data.MyRotationAllInfo.IsMyRotationEnable) @@ -264,28 +220,6 @@ public class PurchaseConfirm : MonoBehaviour return Data.SystemText.Get("MyRotation_ID_22", num3.ToString()); } - public void SetCardSell(string moneyKindName, int moneyHave, int moneyGet, string cardName, bool inIsPremiumCard) - { - SystemText systemText = Data.SystemText; - m_LabelUseItemCnt.text = systemText.Get("Card_0079", moneyGet.ToString()); - m_LabelBuyPack.text = systemText.Get("Card_0078", cardName); - m_LabelItemName.text = systemText.Get("Card_0097"); - if (inIsPremiumCard) - { - _premiumCardWarning.gameObject.SetActive(value: true); - _premiumCardWarning.text = systemText.Get("Card_0144"); - _confirmObj.transform.localPosition = new Vector3(0f, -40f, 0f); - _haveObj.transform.localPosition = new Vector3(0f, -40f, 0f); - } - else - { - _premiumCardWarning.gameObject.SetActive(value: false); - } - int moneyAfter = moneyHave + moneyGet; - SetCardCommon(moneyHave, moneyAfter); - HideJpnLawObj(); - } - private void SetCardCommon(int moneyHave, int moneyAfter) { SetIconImage(UserGoods.Type.RedEther); diff --git a/SVSim.BattleEngine/Engine/Wizard/TextLineCreater.cs b/SVSim.BattleEngine/Engine/Wizard/TextLineCreater.cs deleted file mode 100644 index 441b56d3..00000000 --- a/SVSim.BattleEngine/Engine/Wizard/TextLineCreater.cs +++ /dev/null @@ -1,46 +0,0 @@ -using System.Collections.Generic; -using UnityEngine; - -namespace Wizard; - -public class TextLineCreater : MonoBehaviour -{ - [SerializeField] - private GameObject _originalLine; - - [SerializeField] - private UIGrid _lineGrid; - - private List _lineList = new List(); - - public void ShowLines(int lineNumber, bool isOriginalActive = false) - { - if (lineNumber <= 0) - { - return; - } - _originalLine.gameObject.SetActive(isOriginalActive); - CreateLines(lineNumber); - int i = 0; - for (int count = _lineList.Count; i < count; i++) - { - if (i < lineNumber) - { - _lineList[i].gameObject.SetActive(value: true); - } - else - { - _lineList[i].gameObject.SetActive(value: false); - } - } - _lineGrid.Reposition(); - } - - private void CreateLines(int lineNumber) - { - for (int i = _lineList.Count; i < lineNumber; i++) - { - _lineList.Add(NGUITools.AddChild(_lineGrid.gameObject, _originalLine)); - } - } -} diff --git a/SVSim.BattleEngine/Engine/Wizard/_3dCardFrameManager.cs b/SVSim.BattleEngine/Engine/Wizard/_3dCardFrameManager.cs index 36d8e115..355ba9ff 100644 --- a/SVSim.BattleEngine/Engine/Wizard/_3dCardFrameManager.cs +++ b/SVSim.BattleEngine/Engine/Wizard/_3dCardFrameManager.cs @@ -156,11 +156,6 @@ public class _3dCardFrameManager return _frameMaterialList[(int)frameKind, (int)cardKind, rarity]; } - public Material GetFrameMaterial(bool isPhantom, CardBasePrm.CharaType cardKind, int rarity) - { - return GetFrameMaterial(isPhantom ? eFrameKind.Phantom : eFrameKind.Normal, (!CardBasePrm.IsFollowerCard(cardKind)) ? (CardBasePrm.IsSpellCard(cardKind) ? eCardKind.Spell : eCardKind.Amulet) : eCardKind.Follower, rarity); - } - private static string GetLegendFrameMaskName(eCardKind cardKind) { return $"tx_mask_CardFrame_{CARD_KIND_NAME_TABLE[(int)cardKind]}_Legend"; diff --git a/SVSim.BattleEngine/Engine/iTween.cs b/SVSim.BattleEngine/Engine/iTween.cs index 0561c045..e17737ce 100644 --- a/SVSim.BattleEngine/Engine/iTween.cs +++ b/SVSim.BattleEngine/Engine/iTween.cs @@ -174,47 +174,6 @@ public class iTween : MonoBehaviour private Transform thisTransform; - public static void ValueTo(GameObject target, Hashtable args) - { - args = CleanArgs(args); - if (!args.Contains("onupdate") || !args.Contains("from") || !args.Contains("to")) - { - Debug.LogError("iTween Error: ValueTo() requires an 'onupdate' callback function and a 'from' and 'to' property. The supplied 'onupdate' callback must accept a single argument that is the same type as the supplied 'from' and 'to' properties!"); - return; - } - args["type"] = "value"; - if (args["from"].GetType() == typeof(Vector2)) - { - args["method"] = "vector2"; - } - else if (args["from"].GetType() == typeof(Vector3)) - { - args["method"] = "vector3"; - } - else if (args["from"].GetType() == typeof(Rect)) - { - args["method"] = "rect"; - } - else if (args["from"].GetType() == typeof(float)) - { - args["method"] = "float"; - } - else - { - if (!(args["from"].GetType() == typeof(Color))) - { - Debug.LogError("iTween Error: ValueTo() only works with interpolating Vector3s, Vector2s, floats, ints, Rects and Colors!"); - return; - } - args["method"] = "color"; - } - if (!args.Contains("easetype")) - { - args.Add("easetype", EaseType.linear); - } - Launch(target, args); - } - public static void ColorFrom(GameObject target, Hashtable args) { Color color = default(Color); diff --git a/SVSim.BattleEngine/Shim/Generated/BattleLogItem.g.cs b/SVSim.BattleEngine/Shim/Generated/BattleLogItem.g.cs index 9a7dfa28..aa97cefc 100644 --- a/SVSim.BattleEngine/Shim/Generated/BattleLogItem.g.cs +++ b/SVSim.BattleEngine/Shim/Generated/BattleLogItem.g.cs @@ -12,9 +12,7 @@ public partial class BattleLogItem Null} private enum FrameType { - Unit, - Field, - Spell } +} private enum DescStyle { Normal } diff --git a/SVSim.BattleEngine/Shim/Generated/BattlePlayerView.g.cs b/SVSim.BattleEngine/Shim/Generated/BattlePlayerView.g.cs index 1c40c164..a3e07dc7 100644 --- a/SVSim.BattleEngine/Shim/Generated/BattlePlayerView.g.cs +++ b/SVSim.BattleEngine/Shim/Generated/BattlePlayerView.g.cs @@ -13,10 +13,6 @@ namespace Wizard.Battle.View public partial class BattlePlayerView { public BattlePlayerView(BattlePlayer battlePlayer) { } - public static bool HasKeyword(CardParameter cardParameter) => default!; public bool IsMoving() => default!; - public static DialogBase CreateKeyPanel(string skillDescription, UILabel label, CardMaster.CardMasterId cardMasterId) => default!; - public static void PressKeyWordColorChange(UILabel label, bool press) { } - public static void SetKeyWordLabelColor(UILabel label, string colorCode = "[ffcd45]") { } } } diff --git a/SVSim.BattleEngine/Shim/Generated/UIManager.g.cs b/SVSim.BattleEngine/Shim/Generated/UIManager.g.cs index d4d72c37..57547ad5 100644 --- a/SVSim.BattleEngine/Shim/Generated/UIManager.g.cs +++ b/SVSim.BattleEngine/Shim/Generated/UIManager.g.cs @@ -30,7 +30,6 @@ public partial class UIManager Sealed, SealedCardPackOpen, SealedDeckEdit, - Colosseum, Gacha, BuildDeckPurchasePage, CardSleevePurchasePage, @@ -38,8 +37,6 @@ public partial class UIManager Profile, Mission, BattlePass, - LoginBonus, - LotteryPage, Bingo, CrossoverPortal, NeutralPopularityVote, @@ -51,7 +48,6 @@ public partial class UIManager public bool isRetryProc; public bool isNoAvailMemory; public Footer _Footer { get; set; } - public DialogManager DialogManager { get; set; } public ApplicationFinishManager ApplicationFinishManager { get; set; } public GameObject MyPageUICameraObj { get; set; } public NguiObjs TextInputDialogPrefab { get; set; } diff --git a/SVSim.BattleEngine/Shim/GodObjects/GodObjects.cs b/SVSim.BattleEngine/Shim/GodObjects/GodObjects.cs index 8f0f57ae..26ecfc3d 100644 --- a/SVSim.BattleEngine/Shim/GodObjects/GodObjects.cs +++ b/SVSim.BattleEngine/Shim/GodObjects/GodObjects.cs @@ -94,6 +94,6 @@ namespace Wizard { public partial class DeckUpdateTask { } public partial class AccountTransferHelper { } - public class DialogManager { public DialogBase CreateDialogBaseOpenCardDetail(CardDetailUI detailUI) => default!; } + public class DialogManager { } public partial class ApplicationFinishManager { } } diff --git a/SVSim.BattleEngine/Shim/UnityEngine/Primitives.cs b/SVSim.BattleEngine/Shim/UnityEngine/Primitives.cs index ff02a5bc..af387e86 100644 --- a/SVSim.BattleEngine/Shim/UnityEngine/Primitives.cs +++ b/SVSim.BattleEngine/Shim/UnityEngine/Primitives.cs @@ -55,7 +55,6 @@ namespace UnityEngine public static float SqrMagnitude(Vector3 a) => a.sqrMagnitude; public static float Dot(Vector3 a, Vector3 b) => a.x * b.x + a.y * b.y + a.z * b.z; public static Vector3 Scale(Vector3 a, Vector3 b) => new Vector3(a.x * b.x, a.y * b.y, a.z * b.z); - public void Scale(Vector3 s) { x *= s.x; y *= s.y; z *= s.z; } public static Vector3 Lerp(Vector3 a, Vector3 b, float t) => new Vector3(a.x + (b.x - a.x) * t, a.y + (b.y - a.y) * t, a.z + (b.z - a.z) * t); public static Vector3 operator +(Vector3 a, Vector3 b) => new Vector3(a.x + b.x, a.y + b.y, a.z + b.z); public static Vector3 operator -(Vector3 a, Vector3 b) => new Vector3(a.x - b.x, a.y - b.y, a.z - b.z); diff --git a/SVSim.BattleEngine/Shim/UnityEngine/UnityShim.cs b/SVSim.BattleEngine/Shim/UnityEngine/UnityShim.cs index 719586f7..3f752005 100644 --- a/SVSim.BattleEngine/Shim/UnityEngine/UnityShim.cs +++ b/SVSim.BattleEngine/Shim/UnityEngine/UnityShim.cs @@ -271,11 +271,11 @@ namespace UnityEngine public class MeshFilter : Component { public Mesh mesh { get; set; } public Mesh sharedMesh { get; set; } } public class ParticleSystem : Component { - public void Play() { } public int particleCount => 0; +public int particleCount => 0; public MainModule main => default; public int GetParticles(Particle[] p) => 0; public void SetParticles(Particle[] p, int n) { } - public struct MainModule { public bool playOnAwake; public MinMaxGradient startColor; } + public struct MainModule { public MinMaxGradient startColor; } public struct MinMaxGradient { public Color color; public MinMaxGradient(Color c) { color = c; } public static implicit operator MinMaxGradient(Color c) => new MinMaxGradient(c); } public struct EmissionModule { } public struct Particle { public Vector3 position; public Color32 startColor; }