|
@@ -13,7 +13,14 @@ namespace GFGGame
|
|
|
{
|
|
|
private UI_DailySupplyUI _ui;
|
|
|
// private ValueBarController _valueBarController;
|
|
|
-
|
|
|
+ private GameObject _gameObject0;
|
|
|
+ private GameObject _gameObject1;
|
|
|
+ private GameObject _gameObject2;
|
|
|
+ private GameObject _gameObject3;
|
|
|
+ private GoWrapper _wrapper0;
|
|
|
+ private GoWrapper _wrapper1;
|
|
|
+ private GoWrapper _wrapper2;
|
|
|
+ private GoWrapper _wrapper3;
|
|
|
private int _signCount;
|
|
|
private int _month;
|
|
|
private int _day;
|
|
@@ -26,6 +33,10 @@ namespace GFGGame
|
|
|
// _valueBarController.Dispose();
|
|
|
// _valueBarController = null;
|
|
|
// }
|
|
|
+ SceneController.DestroyObjectFromView(_gameObject0, _wrapper0);
|
|
|
+ SceneController.DestroyObjectFromView(_gameObject1, _wrapper1);
|
|
|
+ SceneController.DestroyObjectFromView(_gameObject2, _wrapper2);
|
|
|
+ SceneController.DestroyObjectFromView(_gameObject3, _wrapper3);
|
|
|
if (_ui != null)
|
|
|
{
|
|
|
_ui.Dispose();
|
|
@@ -42,11 +53,22 @@ namespace GFGGame
|
|
|
this.viewCom = _ui.target;
|
|
|
this.viewCom.Center();
|
|
|
this.modal = true;
|
|
|
- viewAnimationType = EnumViewAnimationType.ZOOM_CENTER;
|
|
|
+ viewAnimationType = EnumViewAnimationType.None;
|
|
|
// _valueBarController = new ValueBarController(_ui.m_comValueBar);
|
|
|
|
|
|
// _ui.m_btnback.onClick.Add(OnBtnBackClick);
|
|
|
-
|
|
|
+ UpdateEffect();
|
|
|
+ }
|
|
|
+ private void UpdateEffect()
|
|
|
+ {
|
|
|
+ string resPath = ResPathUtil.GetViewEffectPath("ui_Activity", "Time_thing_book");
|
|
|
+ SceneController.AddObjectToView(null, null, _ui.m_holder, resPath, out _gameObject0, out _wrapper0);
|
|
|
+ string resPath1 = ResPathUtil.GetViewEffectPath("ui_Activity", "Time_thing_hudie");
|
|
|
+ SceneController.AddObjectToView(null, null, _ui.m_comSupply.m_holder, resPath1, out _gameObject1, out _wrapper1);
|
|
|
+
|
|
|
+ string resPath2 = ResPathUtil.GetViewEffectPath("ui_Activity", "Time_thing_zhuti");
|
|
|
+ SceneController.AddObjectToView(null, null, _ui.m_comSupply.m_comSupply0.m_holder, resPath2, out _gameObject2, out _wrapper2);
|
|
|
+ SceneController.AddObjectToView(null, null, _ui.m_comSupply.m_comSupply1.m_holder, resPath2, out _gameObject3, out _wrapper3);
|
|
|
}
|
|
|
protected override void AddEventListener()
|
|
|
{
|
|
@@ -60,12 +82,14 @@ namespace GFGGame
|
|
|
_month = TimeUtil.GetCurMonth();
|
|
|
_day = TimeUtil.GetCurDay();
|
|
|
UpdateSupplyView();
|
|
|
+ _ui.m_t0.Play();
|
|
|
}
|
|
|
|
|
|
protected override void OnHide()
|
|
|
{
|
|
|
// _valueBarController.OnHide();
|
|
|
base.OnHide();
|
|
|
+ _ui.m_t0.Stop();
|
|
|
}
|
|
|
protected override void RemoveEventListener()
|
|
|
{
|
|
@@ -84,8 +108,8 @@ namespace GFGGame
|
|
|
|
|
|
private void UpdateSupplyView()
|
|
|
{
|
|
|
- UpdateReward(_ui.m_comSupply0.target, DailySupplyCfgArray.Instance.dataArray[0].id);
|
|
|
- UpdateReward(_ui.m_comSupply1.target, DailySupplyCfgArray.Instance.dataArray[1].id);
|
|
|
+ UpdateReward(_ui.m_comSupply.m_comSupply0.target, DailySupplyCfgArray.Instance.dataArray[0].id);
|
|
|
+ UpdateReward(_ui.m_comSupply.m_comSupply1.target, DailySupplyCfgArray.Instance.dataArray[1].id);
|
|
|
}
|
|
|
|
|
|
|
|
@@ -93,7 +117,7 @@ namespace GFGGame
|
|
|
{
|
|
|
DailySupplyCfg supplyCfg = DailySupplyCfgArray.Instance.GetCfg(id);
|
|
|
|
|
|
- UI_ComSupply item = UI_ComSupply.Proxy(obj);
|
|
|
+ UI_ComSupplyItem item = UI_ComSupplyItem.Proxy(obj);
|
|
|
|
|
|
long openTime = TimeUtil.GetCurDayTime(TimeUtil.GetDateTime(supplyCfg.openTime).ToString("HH:mm:ss"));
|
|
|
long endTime = TimeUtil.GetCurDayTime(TimeUtil.GetDateTime(supplyCfg.endTime).ToString("HH:mm:ss"));
|
|
@@ -132,7 +156,7 @@ namespace GFGGame
|
|
|
item.m_btnGet.onClick.Add(OnBtnGetSupplyClick);
|
|
|
}
|
|
|
item.m_btnGet.data = supplyCfg;
|
|
|
- UI_ComSupply.ProxyEnd();
|
|
|
+ UI_ComSupplyItem.ProxyEnd();
|
|
|
}
|
|
|
private void OnBtnGetSupplyClick(EventContext context)
|
|
|
{
|