123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960 |
- using System.Collections.Generic;
- using Core.Language;
- using Excel2Json;
- using Fort23.UTool;
- namespace Fort23.Mono
- {
- [UIBinding(prefab = "EventMinLogWidget")]
- public partial class EventMinLogWidget : UIComponent
- {
- private EventConfig eventConfig;
- private void Init()
- {
- }
- public override void AddEvent()
- {
- }
- public override void DelEvent()
- {
- }
- public override void AddButtonEvent()
- {
- }
- public void CustomInit(int id, AccountFileInfo.EventList eventList, List<int> places)
- {
- eventConfig = ConfigComponent.Instance.Get<EventConfig>(id);
- PlacesConfig placesConfig = ConfigComponent.Instance.Get<PlacesConfig>(eventConfig.placeID);
- Text_MapName.text = LanguageManager.Instance.Text(placesConfig.placeName);
- if (eventList == null)
- {
- Text_Name.text = "???";
- }
- else
- {
- Text_Name.text = LanguageManager.Instance.Text(eventConfig.EventName);
- }
- if (places.Count > 0)
- {
- if (places.Contains(eventConfig.placeID))
- {
- transform.RecoverColor();
- }
- else
- {
- transform.Gray();
- }
- }
- else
- {
- transform.RecoverColor();
- }
- }
- }
- }
|