1
0
mirror of synced 2024-11-29 01:34:42 +01:00

Also add material icons for tranparent toggle in render state

This commit is contained in:
KillzXGaming 2019-05-30 21:46:00 -04:00
parent 31b2ab8260
commit 7682a827cc
5 changed files with 7 additions and 1 deletions

Binary file not shown.

View File

@ -871,9 +871,15 @@ namespace FirstPlugin
if (mat.shaderassign.options.ContainsKey("enable_translucent"))
IsTransparentMask = mat.shaderassign.options["enable_transparent"] == "1";
}
if (mat.MaterialU != null)
{
IsTranslucent = mat.MaterialU.RenderState.FlagsMode == ResU.RenderStateFlagsMode.Translucent;
IsTransparentMask = mat.MaterialU.RenderState.FlagsMode == ResU.RenderStateFlagsMode.AlphaMask;
}
SetMaterialIcon(mat, IsTranslucent, "MaterialTranslucent");
SetMaterialIcon(mat, IsTransparentMask, "MaterialTransparent");
SetMaterialIcon(mat, IsTransparentMask, "MaterialTransparent");
}
private static void SetMaterialIcon(FMAT mat, bool IsEffect, string Key)