| 1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859 | 
							- using FairyGUI;
 
- using UnityEngine;
 
- namespace GFGGame
 
- {
 
-     public class DressUpObjUI
 
-     {
 
-         private GameObject _scenePrefab;
 
-         public GameObject sceneObject;
 
-         public GoWrapper wrapper;
 
-         public DressUpObj dressUpObj;
 
-         public DressUpObjUI(string prefabName = "SceneDressUp")
 
-         {
 
-             _scenePrefab = GFGAsset.Load<GameObject>(ResPathUtil.GetPrefabPath(prefabName));
 
-             dressUpObj = new DressUpObj();
 
-             wrapper = new GoWrapper();
 
-         }
 
-         public void ResetSceneObj(int scale = 100, bool needSetMask = false, bool showSceneType = true, GameObject roleObj = null, bool showBg = true)
 
-         {
 
-             sceneObject = GameObject.Instantiate(_scenePrefab);
 
-             sceneObject.transform.localScale = new Vector3(scale, scale, scale);
 
-             dressUpObj.setSceneObj(sceneObject, needSetMask, showSceneType, roleObj, showBg);
 
-         }
 
-         public void UpdateWrapper(GGraph holder)
 
-         {
 
-             holder.SetNativeObject(wrapper);
 
-             wrapper.wrapTarget = sceneObject;
 
-         }
 
-         public void Dispose()
 
-         {
 
-             //预制体不能被销毁
 
-             _scenePrefab = null;
 
-             if (sceneObject != null)
 
-             {
 
-                 GameObject.Destroy(sceneObject);
 
-                 sceneObject = null;
 
-             }
 
-             if (dressUpObj != null)
 
-             {
 
-                 dressUpObj.Dispose();
 
-                 dressUpObj = null;
 
-             }
 
-             if(wrapper != null)
 
-             {
 
-                 wrapper.Dispose();
 
-                 wrapper = null;
 
-             }
 
-         }
 
-     }
 
- }
 
 
  |