备份CatanBuilding瘦身独立工程
This commit is contained in:
@@ -0,0 +1,33 @@
|
||||
using UnityEngine;
|
||||
using UnityEngine.UI;
|
||||
using asap.core;
|
||||
using cfg;
|
||||
using GameCore;
|
||||
using TMPro;
|
||||
|
||||
public class EventPartnerFishbowlInfoPopupPanel : MonoBehaviour
|
||||
{
|
||||
[SerializeField] private Image rewardIcon;
|
||||
[SerializeField] private TMP_Text text_info, text_tips;
|
||||
[SerializeField] private Button btnClose;
|
||||
private Tables _tables;
|
||||
private FishingEventData _fishingEventData;
|
||||
private IUIService _uiService;
|
||||
private EventPartnerData _data;
|
||||
private void Start()
|
||||
{
|
||||
btnClose.onClick.AddListener(() => UIManager.Instance.DestroyUI(UITypes.EventPartnerInfoPopupPanel));
|
||||
_tables = GContext.container.Resolve<Tables>();
|
||||
_data = GContext.container.Resolve<EventPartnerData>();
|
||||
_fishingEventData = GContext.container.Resolve<FishingEventData>();
|
||||
_uiService = GContext.container.Resolve<IUIService>();
|
||||
var item = _tables.TbItem[_fishingEventData.collectingTargetInitTokenID];
|
||||
var itemId = _tables.TbEventPartnerMain[_data.RedirectId].WheelTicket;
|
||||
item = _tables.TbItem[itemId];
|
||||
_uiService.SetImageSprite(rewardIcon, item.Icon);
|
||||
|
||||
string itemName = LocalizationMgr.GetText(item.Name_l10n_key);
|
||||
text_info.text = LocalizationMgr.GetFormatTextValue("UI_EventSandDigPanel_4", itemName);
|
||||
text_tips.text = LocalizationMgr.GetFormatTextValue("UI_EventSandDigPanel_7", itemName);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user