|
@@ -19,7 +19,6 @@ namespace GFGGame
|
|
|
|
|
|
private LuckyBoxCfg _luckyBoxCfg;
|
|
|
private const int _turnTime = 7;
|
|
|
- private int _curTime = _turnTime;
|
|
|
private int _bgIndex = 0;
|
|
|
private int _modelIndex = 0;
|
|
|
private List<DressUpObjUI> _dressUpObjUIs = new List<DressUpObjUI>(2);
|
|
@@ -42,12 +41,8 @@ namespace GFGGame
|
|
|
_com = comModel;
|
|
|
}
|
|
|
|
|
|
- private bool showNoAnim;
|
|
|
public void OnShown(int luckyBoxId)
|
|
|
{
|
|
|
- showNoAnim = true;
|
|
|
- // _comModel = UI_ComModel.Proxy(_com);
|
|
|
- _curTime = _turnTime;
|
|
|
_luckyBoxCfg = LuckyBoxCfgArray.Instance.GetCfg(luckyBoxId);
|
|
|
_com.GetChild("loaMask").asLoader.url = ResPathUtil.GetBgImgPath(_luckyBoxCfg.bgResArr[_bgIndex]);
|
|
|
InitDressUpObj();
|
|
@@ -73,7 +68,7 @@ namespace GFGGame
|
|
|
_modelIndex = _modelIndex + 1 == _luckyBoxCfg.suitIdArr.Length ? 0 : _modelIndex + 1;
|
|
|
}
|
|
|
|
|
|
- if(_luckyBoxCfg.isAni == 0)
|
|
|
+ if (_luckyBoxCfg.isAni == 0)
|
|
|
{
|
|
|
_com.GetTransition("t0").Play(ChangeRes);
|
|
|
}
|
|
@@ -151,15 +146,6 @@ namespace GFGGame
|
|
|
|
|
|
int scale = _luckyBoxCfg.scaleArr.Length > 0 ? Math.Abs(_luckyBoxCfg.scaleArr[_modelIndex]) / 10000 : 100;
|
|
|
_dressUpObjUIs[_index].sceneObject.transform.localScale = new Vector3(direction * scale, scale, scale);
|
|
|
- //if (showNoAnim)
|
|
|
- //{
|
|
|
- // ChangeModelAlpha(_index, 1);
|
|
|
- // showNoAnim = false;
|
|
|
- //}
|
|
|
- //else
|
|
|
- //{
|
|
|
- // ShowModel();
|
|
|
- //}
|
|
|
ShowModel();
|
|
|
}
|
|
|
|
|
@@ -207,8 +193,6 @@ namespace GFGGame
|
|
|
{
|
|
|
_index ^= 1;
|
|
|
}
|
|
|
-
|
|
|
-
|
|
|
private bool InitModel(int index)
|
|
|
{
|
|
|
if (_dressUpObjUIs[index].sceneObject == null)
|
|
@@ -246,7 +230,7 @@ namespace GFGGame
|
|
|
|
|
|
private void ChangeModelAlpha(int index, float value)
|
|
|
{
|
|
|
- if(modelInfos[index].cubismModels == null)
|
|
|
+ if (modelInfos[index].cubismModels == null)
|
|
|
{
|
|
|
return;
|
|
|
}
|
|
@@ -291,10 +275,6 @@ namespace GFGGame
|
|
|
_dressUpObjUI2.UpdateWrapper(_comModel.m_comModelRes2.m_holder);
|
|
|
|
|
|
UI_ComModel.ProxyEnd();
|
|
|
-
|
|
|
- //int temp = 1 - _index;
|
|
|
- //InitModel(temp);
|
|
|
- //ChangeModelAlpha(temp, 0);
|
|
|
}
|
|
|
}
|
|
|
}
|