forked from Perfare/AssetStudio
-
Notifications
You must be signed in to change notification settings - Fork 96
Open
Description
I tried two unity 6 games, PEAK which is unity6000.0.36f1 and StarSavior which is unity6000.0.30f1, shader cant be loaded.


// AssetStudio/Classes/Shader.cs (L750-768)
if (version >= (2020, 2)) //2020.2 and up
{
int numEditorDataHash = reader.ReadInt32();
m_EditorDataHash = new Hash128[numEditorDataHash];
for (int i = 0; i < numEditorDataHash; i++)
{
m_EditorDataHash[i] = new Hash128(reader);
}
reader.AlignStream();
m_Platforms = reader.ReadUInt8Array();
reader.AlignStream();
if (version <= (2021, 1)) //2021.1 and down
{
m_LocalKeywordMask = reader.ReadUInt16Array();
reader.AlignStream();
m_GlobalKeywordMask = reader.ReadUInt16Array();
reader.AlignStream();
}
}
im not sure which version specifically, but i guess it would be
- if (version >= (2020, 2)) //2020.2 and up
+ if (version >= (2020, 2) && version < 6000) //2020.2 and up lower than 6000
also,
// AssetStudio/Classes/Shader.cs (L1006-1007)
var m_ShaderIsBaked = reader.ReadBoolean();
+ if (version >= 6000)
+ {
+ var m_AssetGUID = reader.ReadBytes(16);
+ }
reader.AlignStream();
but there's still some shader cant be read properly by ShaderConverter
Metadata
Metadata
Assignees
Labels
No labels