Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 12 additions & 0 deletions Assembly-CSharp.Base.mm/src/Core/ETGMod.cs
Original file line number Diff line number Diff line change
Expand Up @@ -440,7 +440,19 @@ public static void InitModDir(string dir) {
return;
}
}
Texture2D icon = null;
string iconPath = Path.Combine(dir, "icon.png");
if (File.Exists(iconPath))
{
icon = new Texture2D(2, 2);
icon.name = "icon";

icon.LoadImage(File.ReadAllBytes(iconPath));
icon.filterMode = FilterMode.Point;

}
if (icon != null)
metadata.Icon = icon;
// ... then add an AssemblyResolve handler for all the .zip-ped libraries
AppDomain.CurrentDomain.AssemblyResolve += metadata._GenerateModAssemblyResolver();

Expand Down