feat(battle-engine): EffectType full enum + collection/card/vfx extension copies
Replaces partial EffectMgr.EffectType with all 226 decomp values; copies the IsNotNullOrEmpty/EquelsID/FindFromCardId/GetAllFuncVfxResults extension files + UI extensions; adds Renderer/MeshFilter shared-material/mesh/sortingOrder. Compile loop then closed the revealed deps (3242 files). 9.1k -> 18 errors.
This commit is contained in:
87
SVSim.BattleEngine/Engine/Wizard/CompetitionDetail.cs
Normal file
87
SVSim.BattleEngine/Engine/Wizard/CompetitionDetail.cs
Normal file
@@ -0,0 +1,87 @@
|
||||
using UnityEngine;
|
||||
using Wizard.ErrorDialog;
|
||||
using Wizard.Scripts.Network.Data.TaskData.Arena;
|
||||
|
||||
namespace Wizard;
|
||||
|
||||
public class CompetitionDetail : MonoBehaviour
|
||||
{
|
||||
[SerializeField]
|
||||
private GameObject _prefabRewardDialog;
|
||||
|
||||
[SerializeField]
|
||||
private CardDetailUI _cardDetailDialog;
|
||||
|
||||
[SerializeField]
|
||||
private GameObject _rewardRoot;
|
||||
|
||||
[SerializeField]
|
||||
private UILabel _formatLabel;
|
||||
|
||||
[SerializeField]
|
||||
private UILabel _entryPeriodTimeLabel;
|
||||
|
||||
[SerializeField]
|
||||
private UILabel _openPeriodTimeLabel;
|
||||
|
||||
[SerializeField]
|
||||
private UILabel _maxNumLabel;
|
||||
|
||||
[SerializeField]
|
||||
private UILabel _conditionLable;
|
||||
|
||||
[SerializeField]
|
||||
private UILabel _entryNum;
|
||||
|
||||
[SerializeField]
|
||||
private UILabel _tryNum;
|
||||
|
||||
private const int COMPETITION_ANNOUNCE_ID_NOT_SET_ERROR_CODE = 5516;
|
||||
|
||||
public void Init(DialogBase inDialog, ArenaCompetition data, bool isEntry)
|
||||
{
|
||||
SystemText systemText = Data.SystemText;
|
||||
inDialog.SetSize(DialogBase.Size.M);
|
||||
inDialog.SetTitleLabel(systemText.Get("Common_0022"));
|
||||
inDialog.SetButtonLayout(DialogBase.ButtonLayout.GrayBtn_GrayBtn);
|
||||
inDialog.SetButtonText(systemText.Get("Colosseum_0023"), systemText.Get("Colosseum_0025"));
|
||||
string text = "";
|
||||
text = data.DeckFormat switch
|
||||
{
|
||||
Format.TwoPick => systemText.Get("Arena_0002"),
|
||||
Format.Rotation => systemText.Get("Common_0154"),
|
||||
_ => systemText.Get("Common_0155"),
|
||||
};
|
||||
_formatLabel.text = systemText.Get("Colosseum_0054", text) + systemText.Get("Colosseum_0093");
|
||||
_openPeriodTimeLabel.text = systemText.Get("Competition_0029") + " : " + data.NowRoundTimeText;
|
||||
_entryPeriodTimeLabel.text = systemText.Get("Competition_0028") + " : " + data.EntryTimeText;
|
||||
_maxNumLabel.text = systemText.Get("Competition_0023", data.MaxBattleCount.ToString());
|
||||
_conditionLable.text = systemText.Get("Colosseum_0104", data.MaxLoseCount.ToString());
|
||||
_entryNum.text = systemText.Get("Colosseum_0088", data.MaxEntryCount.ToString());
|
||||
_tryNum.text = systemText.Get("Competition_0042", data.MaxChallengeCount.ToString());
|
||||
inDialog.onPushButton1 = delegate
|
||||
{
|
||||
if (!string.IsNullOrEmpty(data.AnnounceId))
|
||||
{
|
||||
UIManager.GetInstance().WebViewHelper.OpenAnnounceWebView(data.AnnounceId);
|
||||
}
|
||||
else
|
||||
{
|
||||
Wizard.ErrorDialog.Dialog.Create(5516);
|
||||
}
|
||||
};
|
||||
inDialog.onPushButton2 = delegate
|
||||
{
|
||||
UIManager.GetInstance().StartFirstTips(CompetitionUtility.GetCompetitionTipsType(Data.ArenaData.CompetitionData.Rule));
|
||||
};
|
||||
RewardBase component = NGUITools.AddChild(_rewardRoot, _prefabRewardDialog).GetComponent<RewardBase>();
|
||||
component.SetCardDetailUI(_cardDetailDialog);
|
||||
foreach (Wizard.Scripts.Network.Data.TaskData.Arena.Reward entryReward in data.EntryRewardList)
|
||||
{
|
||||
component.AddReward(entryReward);
|
||||
}
|
||||
component.SetActiveRewardLabel(isShow: false);
|
||||
component.SetOnlyIconEndCreate();
|
||||
base.transform.localPosition = Vector3.forward * 10f;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user