| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263 |
- using Core.Language;
- using Excel2Json;
- using Fort23.UTool;
- namespace Fort23.Mono
- {
- [UIBinding(prefab = "XianTuSaiXuanWidget")]
- public partial class XianTuSaiXuanWidget : ItemWidgetBasic
- {
- public int type;
- public BigMapConfig _bigMapConfig;
- public PlacesConfig _placesConfig;
- private void Init()
- {
- }
- public override void AddEvent()
- {
- }
- public override void DelEvent()
- {
- }
- public override void AddButtonEvent()
- {
- base.AddButtonEvent();
- }
- public void CustomInit(int type, int id)
- {
- this.type = type;
- if (type == 1)
- {
- _bigMapConfig = ConfigComponent.Instance.Get<BigMapConfig>(id);
- if (_bigMapConfig.ID == 0)
- {
- Text_Name.text = LanguageManager.Instance.Text(10163);
- }
- else
- {
- string[] fruits = LanguageManager.Instance.Text(_bigMapConfig.mapName).Split('.');
- Text_Name.text =fruits[1];
- }
- }
- else if (type == 2)
- {
- _placesConfig = ConfigComponent.Instance.Get<PlacesConfig>(id);
- if (_placesConfig.ID == 0)
- {
- Text_Name.text = LanguageManager.Instance.Text(10163);
- }
- else
- {
- Text_Name.text = LanguageManager.Instance.Text(_placesConfig.placeName);
- }
- }
- }
- }
- }
|