|
@@ -11,6 +11,7 @@ namespace GFGGame
|
|
|
|
|
|
private GameObject _scenePrefab;
|
|
private GameObject _scenePrefab;
|
|
private GameObject _sceneObject;
|
|
private GameObject _sceneObject;
|
|
|
|
+ private DressUpObjDataCache _dressUpObjDataCache;
|
|
|
|
|
|
private long _friendRoleId;
|
|
private long _friendRoleId;
|
|
|
|
|
|
@@ -21,6 +22,7 @@ namespace GFGGame
|
|
GameObject.Destroy(_sceneObject);
|
|
GameObject.Destroy(_sceneObject);
|
|
_sceneObject = null;
|
|
_sceneObject = null;
|
|
}
|
|
}
|
|
|
|
+ _dressUpObjDataCache = null;
|
|
|
|
|
|
if (_ui != null)
|
|
if (_ui != null)
|
|
{
|
|
{
|
|
@@ -43,6 +45,7 @@ namespace GFGGame
|
|
viewCom = _ui.target;
|
|
viewCom = _ui.target;
|
|
isfullScreen = true;
|
|
isfullScreen = true;
|
|
_scenePrefab = GFGAsset.Load<GameObject>(ResPathUtil.GetPrefabPath("SceneFriend"));
|
|
_scenePrefab = GFGAsset.Load<GameObject>(ResPathUtil.GetPrefabPath("SceneFriend"));
|
|
|
|
+ _dressUpObjDataCache = new DressUpObjDataCache();
|
|
|
|
|
|
_ui.m_list.SetVirtual();
|
|
_ui.m_list.SetVirtual();
|
|
_ui.m_list.itemRenderer = RenderListItem;
|
|
_ui.m_list.itemRenderer = RenderListItem;
|
|
@@ -70,8 +73,8 @@ namespace GFGGame
|
|
{
|
|
{
|
|
CustomSuitData customSuit = CustomSuitDataManager.GetSuitList(CustomSuitDataManager.currentIndex);
|
|
CustomSuitData customSuit = CustomSuitDataManager.GetSuitList(CustomSuitDataManager.currentIndex);
|
|
_sceneObject = GameObject.Instantiate(_scenePrefab);
|
|
_sceneObject = GameObject.Instantiate(_scenePrefab);
|
|
- EquipDataCache.cacher.setSceneObj(_sceneObject);
|
|
|
|
- EquipDataCache.cacher.AddOrRemove(customSuit.bg, true);
|
|
|
|
|
|
+ _dressUpObjDataCache.setSceneObj(_sceneObject);
|
|
|
|
+ _dressUpObjDataCache.AddOrRemove(customSuit.bg, true);
|
|
}
|
|
}
|
|
FriendDataManager.Instance.UpdateFriendList(true);
|
|
FriendDataManager.Instance.UpdateFriendList(true);
|
|
_ui.m_list.numItems = FriendDataManager.Instance.FriendDatas.Count;
|
|
_ui.m_list.numItems = FriendDataManager.Instance.FriendDatas.Count;
|
|
@@ -274,13 +277,13 @@ namespace GFGGame
|
|
|
|
|
|
if (suitSavedData != null)
|
|
if (suitSavedData != null)
|
|
{
|
|
{
|
|
- EquipDataCache.cacher.PutOnSuitMemory(suitSavedData);
|
|
|
|
|
|
+ _dressUpObjDataCache.PutOnSuitMemory(suitSavedData);
|
|
_ui.m_txtName.text = string.Format("我的套装{0}", NumberUtil.GetChiniseNumberText(suitSavedData.pos + 1));
|
|
_ui.m_txtName.text = string.Format("我的套装{0}", NumberUtil.GetChiniseNumberText(suitSavedData.pos + 1));
|
|
|
|
|
|
}
|
|
}
|
|
else
|
|
else
|
|
{
|
|
{
|
|
- EquipDataCache.cacher.PutOnDefaultSuitSaved();
|
|
|
|
|
|
+ _dressUpObjDataCache.PutOnDefaultSuitSaved();
|
|
_ui.m_txtName.text = string.Format("我的套装{0}", NumberUtil.GetChiniseNumberText(1));
|
|
_ui.m_txtName.text = string.Format("我的套装{0}", NumberUtil.GetChiniseNumberText(1));
|
|
|
|
|
|
}
|
|
}
|