mirror of
https://github.com/crskycode/GARbro.git
synced 2026-07-08 01:30:18 +08:00
(UnityFS): adjusted texture reader.
This commit is contained in:
@@ -323,6 +323,8 @@ namespace GameRes.Formats.Unity
|
|||||||
return ReadTextAsset (file, obj);
|
return ReadTextAsset (file, obj);
|
||||||
else if ("Texture2D" == type)
|
else if ("Texture2D" == type)
|
||||||
type = "image";
|
type = "image";
|
||||||
|
else if ("AssetBundle" == type)
|
||||||
|
return null;
|
||||||
|
|
||||||
return new AssetEntry {
|
return new AssetEntry {
|
||||||
Type = type,
|
Type = type,
|
||||||
|
|||||||
@@ -214,7 +214,8 @@ namespace GameRes.Formats.Unity
|
|||||||
|
|
||||||
ImageData Unpack ()
|
ImageData Unpack ()
|
||||||
{
|
{
|
||||||
m_texture.LoadData (m_reader);
|
if (null == m_texture.m_Data || 0 == m_texture.m_Data.Length)
|
||||||
|
m_texture.LoadData (m_reader);
|
||||||
byte[] pixels;
|
byte[] pixels;
|
||||||
switch (m_texture.m_TextureFormat)
|
switch (m_texture.m_TextureFormat)
|
||||||
{
|
{
|
||||||
|
|||||||
Reference in New Issue
Block a user