|
@@ -1,4 +1,5 @@
|
|
|
using ExIni;
|
|
|
+using MyRoomCustom;
|
|
|
using System;
|
|
|
using System.Collections;
|
|
|
using System.Collections.Generic;
|
|
@@ -375,24 +376,30 @@ namespace CM3D2.MultipleMaids.Plugin
|
|
|
GUI.enabled = false;
|
|
|
}
|
|
|
|
|
|
- bool previousGUIState = GUI.enabled;
|
|
|
- GUI.enabled = !modItemsOnly;
|
|
|
+ if (!modItemsOnly)
|
|
|
+ {
|
|
|
+ bool previousGUIState = GUI.enabled;
|
|
|
+ GUI.enabled = slotIndex > 1;
|
|
|
+ modItemsToggle = GUI.Toggle(new Rect(GetPix(156),
|
|
|
+ GetPix(115),
|
|
|
+ GetPix(50),
|
|
|
+ GetPix(20)),
|
|
|
+ modItemsToggle,
|
|
|
+ "Mods",
|
|
|
+ style3
|
|
|
+ );
|
|
|
+ GUI.enabled = previousGUIState;
|
|
|
+ }
|
|
|
|
|
|
- modItemsToggle = GUI.Toggle(new Rect(GetPix(156),
|
|
|
- GetPix(115),
|
|
|
- GetPix(50),
|
|
|
- GetPix(20)),
|
|
|
- modItemsToggle,
|
|
|
- "Mods",
|
|
|
- style3
|
|
|
- );
|
|
|
|
|
|
- GUI.enabled = previousGUIState;
|
|
|
|
|
|
int iconSize = GetPix(45);
|
|
|
Rect position1;
|
|
|
Rect viewRect;
|
|
|
- int bg2ItemCount = (!modItemsOnly && modItemsToggle) ? numberOfModItems : sortList.Count;
|
|
|
+ int bg2ItemCount = slotIndex == 1 ?
|
|
|
+ creativeSortList.Count :
|
|
|
+ (!modItemsOnly && modItemsToggle) ?
|
|
|
+ numberOfModItems : sortList.Count;
|
|
|
if (sceneLevel != 5)
|
|
|
{
|
|
|
position1 = new Rect(GetPix(7),
|
|
@@ -418,9 +425,10 @@ namespace CM3D2.MultipleMaids.Plugin
|
|
|
|
|
|
bg2ScrollPos = GUI.BeginScrollView(position1, bg2ScrollPos, viewRect);
|
|
|
int bg2Index = 0;
|
|
|
- foreach (SortItem sortItem in sortList)
|
|
|
+ List<SortItem> bg2List = slotIndex == 1 ? creativeSortList : sortList;
|
|
|
+ foreach (SortItem sortItem in bg2List)
|
|
|
{
|
|
|
- if (modItemsToggle && !sortItem.isMod)
|
|
|
+ if (slotIndex > 1 && modItemsToggle && !sortItem.isMod)
|
|
|
{
|
|
|
continue;
|
|
|
}
|
|
@@ -432,51 +440,62 @@ namespace CM3D2.MultipleMaids.Plugin
|
|
|
);
|
|
|
if (GUI.Button(position2, ""))
|
|
|
{
|
|
|
- string menu = sortItem.menu;
|
|
|
- byte[] modBuf = null;
|
|
|
- bool ready = true;
|
|
|
- if (sortItem.isOfficialMod)
|
|
|
+ GameObject gameObject = null;
|
|
|
+ if (slotIndex > 1)
|
|
|
{
|
|
|
- menu = sortItem.baseItem;
|
|
|
+ string menu = sortItem.menu;
|
|
|
+ byte[] modBuf = null;
|
|
|
+ bool ready = true;
|
|
|
+ if (sortItem.isOfficialMod)
|
|
|
+ {
|
|
|
+ menu = sortItem.baseMenu;
|
|
|
|
|
|
- using (FileStream fileStream = new FileStream(sortItem.menu, FileMode.Open))
|
|
|
+ using (FileStream fileStream = new FileStream(sortItem.menu, FileMode.Open))
|
|
|
+ {
|
|
|
+ if (fileStream == null)
|
|
|
+ {
|
|
|
+ ready = false;
|
|
|
+ }
|
|
|
+ else
|
|
|
+ {
|
|
|
+ modBuf = new byte[fileStream.Length];
|
|
|
+ fileStream.Read(modBuf, 0, (int)fileStream.Length);
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ byte[] menuBuf = null;
|
|
|
+ using (AFileBase afileBase = GameUty.FileOpen(menu, null))
|
|
|
{
|
|
|
- if (fileStream == null)
|
|
|
+ if (ready = afileBase.IsValid())
|
|
|
{
|
|
|
- ready = false;
|
|
|
+ menuBuf = afileBase.ReadAll();
|
|
|
}
|
|
|
- else
|
|
|
+ }
|
|
|
+
|
|
|
+ if (ready)
|
|
|
+ {
|
|
|
+ string[] meshInfo = ProcScriptBin(menuBuf);
|
|
|
+ gameObject = ImportCM2.LoadSkinMesh_R(meshInfo[0], meshInfo, 1);
|
|
|
+ gameObject.name = menu;
|
|
|
+ if (sortItem.isOfficialMod)
|
|
|
{
|
|
|
- modBuf = new byte[fileStream.Length];
|
|
|
- fileStream.Read(modBuf, 0, (int)fileStream.Length);
|
|
|
+ gameObject.name += $"#{Path.GetFileName(sortItem.menu)}";
|
|
|
+ ProcModScriptBin(modBuf, gameObject);
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
- byte[] menuBuf = null;
|
|
|
- using (AFileBase afileBase = GameUty.FileOpen(menu, null))
|
|
|
+ else
|
|
|
{
|
|
|
- if (ready = afileBase.IsValid())
|
|
|
- {
|
|
|
- menuBuf = afileBase.ReadAll();
|
|
|
- }
|
|
|
+ // My Room Custom content
|
|
|
+ PlacementData.Data data = PlacementData.GetData(int.Parse(sortItem.menu));
|
|
|
+ gameObject = Instantiate(data.GetPrefab());
|
|
|
+ gameObject.name = $"creative_{sortItem.baseMenu}";
|
|
|
}
|
|
|
|
|
|
- if (ready)
|
|
|
+ if (gameObject != null)
|
|
|
{
|
|
|
- string[] meshInfo = ProcScriptBin(menuBuf);
|
|
|
- GameObject gameObject = ImportCM2.LoadSkinMesh_R(meshInfo[0], meshInfo, 1);
|
|
|
- gameObject.name = menu;
|
|
|
- if (sortItem.isOfficialMod)
|
|
|
- {
|
|
|
- gameObject.name += $"#{Path.GetFileName(sortItem.menu)}";
|
|
|
- ProcModScriptBin(modBuf, gameObject);
|
|
|
- }
|
|
|
doguBObject.Add(gameObject);
|
|
|
- Vector3 zero1 = Vector3.zero;
|
|
|
- Vector3 zero2 = Vector3.zero;
|
|
|
- zero1.z = 0.4f;
|
|
|
- gameObject.transform.localPosition = zero1;
|
|
|
- gameObject.transform.localRotation = Quaternion.Euler(zero2);
|
|
|
+ gameObject.transform.position = new Vector3(0, 0, 0.4f);
|
|
|
doguCnt = doguBObject.Count - 1;
|
|
|
gDogu[doguCnt] = GameObject.CreatePrimitive(PrimitiveType.Cube);
|
|
|
gDogu[doguCnt].GetComponent<Renderer>().material = m_material;
|
|
@@ -755,225 +774,248 @@ namespace CM3D2.MultipleMaids.Plugin
|
|
|
sortList.Clear();
|
|
|
bg2ScrollPos = new Vector2(0.0f, 0.0f);
|
|
|
|
|
|
- if (itemDataList.Count == 0)
|
|
|
+ if (slotIndex == 0)
|
|
|
{
|
|
|
- #region menu files
|
|
|
- HashSet<string> modMenus = null;
|
|
|
- if (!modItemsOnly)
|
|
|
- {
|
|
|
- modMenus = new HashSet<string>(GameUty.ModOnlysMenuFiles
|
|
|
- .Select(file => Path.GetFileName(file).ToLowerInvariant()));
|
|
|
- }
|
|
|
-
|
|
|
- string[] menuFiles = modItemsOnly ? GameUty.ModOnlysMenuFiles : GameUty.MenuFiles;
|
|
|
- foreach (string menuFile in menuFiles)
|
|
|
+ return;
|
|
|
+ }
|
|
|
+ else if (slotIndex == 1)
|
|
|
+ {
|
|
|
+ if (creativeSortList.Count == 0)
|
|
|
{
|
|
|
- string fileName = Path.GetFileName(menuFile);
|
|
|
- byte[] buf;
|
|
|
- using (AFileBase aFileBase = GameUty.FileOpen(menuFile))
|
|
|
+ PlacementData.CreateData();
|
|
|
+ List<PlacementData.Data> creativeData = PlacementData.GetAllDatas(false);
|
|
|
+ creativeData = creativeData.OrderBy(data => data.categoryID).ThenBy(data => data.ID).ToList();
|
|
|
+ creativeSortList = new List<SortItem>(creativeData.Count);
|
|
|
+ foreach (var data in creativeData)
|
|
|
{
|
|
|
- if (!aFileBase.IsValid())
|
|
|
+ string asset = !string.IsNullOrEmpty(data.resourceName) ? data.resourceName : data.assetName;
|
|
|
+ SortItem item = new SortItem()
|
|
|
{
|
|
|
- continue;
|
|
|
- }
|
|
|
- buf = aFileBase.ReadAll();
|
|
|
+ menu = data.ID.ToString(),
|
|
|
+ baseMenu = asset,
|
|
|
+ isCreative = true,
|
|
|
+ tex = data.GetThumbnail() as Texture2D
|
|
|
+ };
|
|
|
+ creativeSortList.Add(item);
|
|
|
}
|
|
|
-
|
|
|
- ItemData item = new ItemData()
|
|
|
- {
|
|
|
- menu = fileName,
|
|
|
- isMod = modItemsOnly ? true : modMenus.Contains(fileName)
|
|
|
- };
|
|
|
- BinaryReader binaryReader = new BinaryReader(new MemoryStream(buf), Encoding.UTF8);
|
|
|
- if (binaryReader.ReadString() != "CM3D2_MENU")
|
|
|
+ }
|
|
|
+ }
|
|
|
+ else
|
|
|
+ {
|
|
|
+ if (itemDataList.Count == 0)
|
|
|
+ {
|
|
|
+ #region menu files
|
|
|
+ HashSet<string> modMenus = null;
|
|
|
+ if (!modItemsOnly)
|
|
|
{
|
|
|
- binaryReader.Close();
|
|
|
+ modMenus = new HashSet<string>(GameUty.ModOnlysMenuFiles
|
|
|
+ .Select(file => Path.GetFileName(file).ToLowerInvariant()));
|
|
|
}
|
|
|
- else
|
|
|
+
|
|
|
+ string[] menuFiles = modItemsOnly ? GameUty.ModOnlysMenuFiles : GameUty.MenuFiles;
|
|
|
+ foreach (string menuFile in menuFiles)
|
|
|
{
|
|
|
- try
|
|
|
+ string fileName = Path.GetFileName(menuFile);
|
|
|
+ byte[] buf;
|
|
|
+ using (AFileBase aFileBase = GameUty.FileOpen(menuFile))
|
|
|
{
|
|
|
- binaryReader.ReadInt32();
|
|
|
- binaryReader.ReadString();
|
|
|
- item.name = binaryReader.ReadString();
|
|
|
- item.category = binaryReader.ReadString();
|
|
|
- binaryReader.ReadString();
|
|
|
- binaryReader.ReadInt32();
|
|
|
- bool run = true;
|
|
|
- do
|
|
|
+ if (!aFileBase.IsValid())
|
|
|
{
|
|
|
- int size;
|
|
|
- do
|
|
|
- {
|
|
|
- size = binaryReader.ReadByte();
|
|
|
- } while (size == 0);
|
|
|
+ continue;
|
|
|
+ }
|
|
|
+ buf = aFileBase.ReadAll();
|
|
|
+ }
|
|
|
|
|
|
- for (int index = 0; index < size; ++index)
|
|
|
+ ItemData item = new ItemData()
|
|
|
+ {
|
|
|
+ menu = fileName,
|
|
|
+ isMod = modItemsOnly ? true : modMenus.Contains(fileName)
|
|
|
+ };
|
|
|
+ BinaryReader binaryReader = new BinaryReader(new MemoryStream(buf), Encoding.UTF8);
|
|
|
+ if (binaryReader.ReadString() != "CM3D2_MENU")
|
|
|
+ {
|
|
|
+ binaryReader.Close();
|
|
|
+ }
|
|
|
+ else
|
|
|
+ {
|
|
|
+ try
|
|
|
+ {
|
|
|
+ binaryReader.ReadInt32();
|
|
|
+ binaryReader.ReadString();
|
|
|
+ item.name = binaryReader.ReadString();
|
|
|
+ item.category = binaryReader.ReadString();
|
|
|
+ binaryReader.ReadString();
|
|
|
+ binaryReader.ReadInt32();
|
|
|
+ bool run = true;
|
|
|
+ do
|
|
|
{
|
|
|
- string header = binaryReader.ReadString();
|
|
|
- if (header == "icons" || header == "icon")
|
|
|
+ int size;
|
|
|
+ do
|
|
|
{
|
|
|
- run = false;
|
|
|
- item.icon = binaryReader.ReadString();
|
|
|
- break;
|
|
|
- }
|
|
|
+ size = binaryReader.ReadByte();
|
|
|
+ } while (size == 0);
|
|
|
|
|
|
- if (header == "priority")
|
|
|
+ for (int index = 0; index < size; ++index)
|
|
|
{
|
|
|
- int.TryParse(binaryReader.ReadString(), out item.priority);
|
|
|
- break;
|
|
|
+ string header = binaryReader.ReadString();
|
|
|
+ if (header == "icons" || header == "icon")
|
|
|
+ {
|
|
|
+ run = false;
|
|
|
+ item.icon = binaryReader.ReadString();
|
|
|
+ break;
|
|
|
+ }
|
|
|
+
|
|
|
+ if (header == "priority")
|
|
|
+ {
|
|
|
+ int.TryParse(binaryReader.ReadString(), out item.priority);
|
|
|
+ break;
|
|
|
+ }
|
|
|
}
|
|
|
- }
|
|
|
- } while (run);
|
|
|
+ } while (run);
|
|
|
|
|
|
- itemDataList.Add(item);
|
|
|
- }
|
|
|
- catch { }
|
|
|
+ itemDataList.Add(item);
|
|
|
+ }
|
|
|
+ catch { }
|
|
|
|
|
|
- binaryReader.Close();
|
|
|
+ binaryReader.Close();
|
|
|
+ }
|
|
|
}
|
|
|
- }
|
|
|
- #endregion
|
|
|
+ #endregion
|
|
|
|
|
|
- #region mod files
|
|
|
- foreach (string modFile in Menu.GetModFiles())
|
|
|
- {
|
|
|
- byte[] buf = null;
|
|
|
- try
|
|
|
+ #region mod files
|
|
|
+ foreach (string modFile in Menu.GetModFiles())
|
|
|
{
|
|
|
- using (FileStream fileStream = new FileStream(modFile, FileMode.Open))
|
|
|
+ byte[] buf = null;
|
|
|
+ try
|
|
|
{
|
|
|
- if (fileStream == null)
|
|
|
+ using (FileStream fileStream = new FileStream(modFile, FileMode.Open))
|
|
|
{
|
|
|
- continue;
|
|
|
+ if (fileStream == null)
|
|
|
+ {
|
|
|
+ continue;
|
|
|
+ }
|
|
|
+ buf = new byte[fileStream.Length];
|
|
|
+ fileStream.Read(buf, 0, (int)fileStream.Length);
|
|
|
}
|
|
|
- buf = new byte[fileStream.Length];
|
|
|
- fileStream.Read(buf, 0, (int)fileStream.Length);
|
|
|
}
|
|
|
- }
|
|
|
- catch { }
|
|
|
+ catch { }
|
|
|
|
|
|
- if (buf == null)
|
|
|
- {
|
|
|
- continue;
|
|
|
- }
|
|
|
+ if (buf == null)
|
|
|
+ {
|
|
|
+ continue;
|
|
|
+ }
|
|
|
|
|
|
- ItemData item = new ItemData()
|
|
|
- {
|
|
|
- isMod = true,
|
|
|
- isOfficialMod = true,
|
|
|
- menu = modFile,
|
|
|
- priority = 1000
|
|
|
- };
|
|
|
+ ItemData item = new ItemData()
|
|
|
+ {
|
|
|
+ isMod = true,
|
|
|
+ isOfficialMod = true,
|
|
|
+ menu = modFile,
|
|
|
+ priority = 1000
|
|
|
+ };
|
|
|
|
|
|
- BinaryReader binaryReader = new BinaryReader(new MemoryStream(buf), Encoding.UTF8);
|
|
|
- if (binaryReader.ReadString() != "CM3D2_MOD")
|
|
|
- {
|
|
|
- binaryReader.Close();
|
|
|
- }
|
|
|
- else
|
|
|
- {
|
|
|
- try
|
|
|
+ BinaryReader binaryReader = new BinaryReader(new MemoryStream(buf), Encoding.UTF8);
|
|
|
+ if (binaryReader.ReadString() != "CM3D2_MOD")
|
|
|
+ {
|
|
|
+ binaryReader.Close();
|
|
|
+ }
|
|
|
+ else
|
|
|
{
|
|
|
- binaryReader.ReadInt32();
|
|
|
- string iconName = binaryReader.ReadString();
|
|
|
- string baseItemPath = binaryReader.ReadString().Replace(":", " ");
|
|
|
- item.baseItem = Path.GetFileName(baseItemPath);
|
|
|
- item.name = binaryReader.ReadString();
|
|
|
- item.category = binaryReader.ReadString();
|
|
|
- binaryReader.ReadString();
|
|
|
- string mpnValue = binaryReader.ReadString();
|
|
|
- MPN mpn = MPN.null_mpn;
|
|
|
try
|
|
|
{
|
|
|
- mpn = (MPN)Enum.Parse(typeof(MPN), mpnValue, true);
|
|
|
- }
|
|
|
- catch
|
|
|
- {
|
|
|
- binaryReader.Close();
|
|
|
- continue;
|
|
|
- }
|
|
|
- if (mpn != MPN.null_mpn)
|
|
|
- {
|
|
|
+ binaryReader.ReadInt32();
|
|
|
+ string iconName = binaryReader.ReadString();
|
|
|
+ string baseItemPath = binaryReader.ReadString().Replace(":", " ");
|
|
|
+ item.baseItem = Path.GetFileName(baseItemPath);
|
|
|
+ item.name = binaryReader.ReadString();
|
|
|
+ item.category = binaryReader.ReadString();
|
|
|
binaryReader.ReadString();
|
|
|
- }
|
|
|
- binaryReader.ReadString();
|
|
|
- int size = binaryReader.ReadInt32();
|
|
|
- for (int i = 0; i < size; i++)
|
|
|
- {
|
|
|
- string key = binaryReader.ReadString();
|
|
|
- int count = binaryReader.ReadInt32();
|
|
|
- byte[] data = binaryReader.ReadBytes(count);
|
|
|
- if (string.Equals(key, iconName, StringComparison.InvariantCultureIgnoreCase))
|
|
|
+ string mpnValue = binaryReader.ReadString();
|
|
|
+ MPN mpn = MPN.null_mpn;
|
|
|
+ try
|
|
|
{
|
|
|
- Texture2D tex = new Texture2D(1, 1, TextureFormat.RGBA32, false);
|
|
|
- tex.LoadImage(data);
|
|
|
- item.tex = tex;
|
|
|
- break;
|
|
|
+ mpn = (MPN)Enum.Parse(typeof(MPN), mpnValue, true);
|
|
|
+ }
|
|
|
+ catch
|
|
|
+ {
|
|
|
+ binaryReader.Close();
|
|
|
+ continue;
|
|
|
}
|
|
|
+ if (mpn != MPN.null_mpn)
|
|
|
+ {
|
|
|
+ binaryReader.ReadString();
|
|
|
+ }
|
|
|
+ binaryReader.ReadString();
|
|
|
+ int size = binaryReader.ReadInt32();
|
|
|
+ for (int i = 0; i < size; i++)
|
|
|
+ {
|
|
|
+ string key = binaryReader.ReadString();
|
|
|
+ int count = binaryReader.ReadInt32();
|
|
|
+ byte[] data = binaryReader.ReadBytes(count);
|
|
|
+ if (string.Equals(key, iconName, StringComparison.InvariantCultureIgnoreCase))
|
|
|
+ {
|
|
|
+ Texture2D tex = new Texture2D(1, 1, TextureFormat.RGBA32, false);
|
|
|
+ tex.LoadImage(data);
|
|
|
+ item.tex = tex;
|
|
|
+ break;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ itemDataList.Add(item);
|
|
|
}
|
|
|
- itemDataList.Add(item);
|
|
|
+ catch { }
|
|
|
+ binaryReader.Close();
|
|
|
}
|
|
|
- catch { }
|
|
|
- binaryReader.Close();
|
|
|
}
|
|
|
+ #endregion
|
|
|
}
|
|
|
- #endregion
|
|
|
- }
|
|
|
|
|
|
- if (slotIndex == 0)
|
|
|
- {
|
|
|
- return;
|
|
|
- }
|
|
|
-
|
|
|
- foreach (ItemData itemData in itemDataList)
|
|
|
- {
|
|
|
- if (itemData.category == slotArray[slotIndex] && itemData.priority > 0)
|
|
|
+ foreach (ItemData itemData in itemDataList)
|
|
|
{
|
|
|
- sortList.Add(new SortItem()
|
|
|
+ if (itemData.category == slotArray[slotIndex] && itemData.priority > 0)
|
|
|
{
|
|
|
- category = itemData.category,
|
|
|
- priority = itemData.priority,
|
|
|
- name = itemData.name,
|
|
|
- icon = itemData.icon,
|
|
|
- menu = itemData.menu,
|
|
|
- tex = itemData.tex,
|
|
|
- isMod = itemData.isMod,
|
|
|
- isOfficialMod = itemData.isOfficialMod,
|
|
|
- baseItem = itemData.baseItem
|
|
|
- });
|
|
|
+ sortList.Add(new SortItem()
|
|
|
+ {
|
|
|
+ category = itemData.category,
|
|
|
+ priority = itemData.priority,
|
|
|
+ name = itemData.name,
|
|
|
+ icon = itemData.icon,
|
|
|
+ menu = itemData.menu,
|
|
|
+ tex = itemData.tex,
|
|
|
+ isMod = itemData.isMod,
|
|
|
+ isOfficialMod = itemData.isOfficialMod,
|
|
|
+ baseMenu = itemData.baseItem
|
|
|
+ });
|
|
|
+ }
|
|
|
}
|
|
|
- }
|
|
|
|
|
|
- IOrderedEnumerable<SortItem> sortedItemList = sortList
|
|
|
- .OrderBy(item => item.priority)
|
|
|
- .ThenBy(item => item.name);
|
|
|
+ IOrderedEnumerable<SortItem> sortedItemList = sortList
|
|
|
+ .OrderBy(item => item.priority)
|
|
|
+ .ThenBy(item => item.name);
|
|
|
|
|
|
- List<SortItem> sortItemList = new List<SortItem>();
|
|
|
+ List<SortItem> sortItemList = new List<SortItem>();
|
|
|
|
|
|
- string previousMenu = "";
|
|
|
- foreach (SortItem item in sortedItemList)
|
|
|
- {
|
|
|
- try
|
|
|
+ string previousMenu = "";
|
|
|
+ foreach (SortItem item in sortedItemList)
|
|
|
{
|
|
|
- if (item.menu != previousMenu)
|
|
|
+ try
|
|
|
{
|
|
|
- if (!modItemsOnly && item.isMod) numberOfModItems++;
|
|
|
- if (item.tex == null)
|
|
|
+ if (item.menu != previousMenu)
|
|
|
{
|
|
|
- byte[] data = ImportCM.LoadTexture(GameUty.FileSystem, item.icon, false).data;
|
|
|
- Texture2D texture2D = new Texture2D(50, 50, TextureFormat.RGB565, false);
|
|
|
- texture2D.LoadImage(data);
|
|
|
- item.tex = texture2D;
|
|
|
+ if (!modItemsOnly && item.isMod) numberOfModItems++;
|
|
|
+ if (item.tex == null)
|
|
|
+ {
|
|
|
+ byte[] data = ImportCM.LoadTexture(GameUty.FileSystem, item.icon, false).data;
|
|
|
+ Texture2D texture2D = new Texture2D(50, 50, TextureFormat.RGB565, false);
|
|
|
+ texture2D.LoadImage(data);
|
|
|
+ item.tex = texture2D;
|
|
|
+ }
|
|
|
+ previousMenu = item.menu;
|
|
|
+ sortItemList.Add(item);
|
|
|
}
|
|
|
- previousMenu = item.menu;
|
|
|
- sortItemList.Add(item);
|
|
|
}
|
|
|
+ catch { }
|
|
|
}
|
|
|
- catch { }
|
|
|
+ sortList = sortItemList;
|
|
|
}
|
|
|
-
|
|
|
- sortList = sortItemList;
|
|
|
}
|
|
|
|
|
|
private void BGSelectWindow(int winID)
|