Update Ytyp Archetype Flags and Fix for Generate Capsule LODLight and Fix for Capsule HDLight (#205)

* Update EditYtypArchetypePanel.Designer.cs

64 - Unk07 archetype flag: disable sorting for shaders with alpha. Used for glass objects, has a bug of drawing through objects in a mirror and a white glare strip in specular shaders
524288 - Unk20 archetype flag: plays YCD animation on Dynamic objects. Works on objects with 131072 - Dynamic

* Fix for Generate Capsule LODLight

* Fix for Generate Capsule LODLight

* Fix for Capsule HDLight
This commit is contained in:
Kirill 2023-08-24 02:06:11 +03:00 committed by GitHub
parent 595bb9a375
commit 7bc3630ef9
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 5 additions and 5 deletions

View File

@ -303,7 +303,7 @@
"8 - Unk04",
"16 - Unk05",
"32 - Static",
"64 - Unk07",
"64 - Disable alpha sorting",
"128 - Instance",
"256 - Unk09",
"512 - Bone anims (YCD)",
@ -316,7 +316,7 @@
"65536 - Double-sided rendering",
"131072 - Dynamic",
"262144 - Unk19",
"524288 - Unk20",
"524288 - Dynamic anims (YCD)",
"1048576 - Unk21",
"2097152 - Unk22",
"4194304 - Unk23",

View File

@ -152,7 +152,7 @@ namespace CodeWalker.Project.Panels
var outer = (byte)Math.Round(la.ConeOuterAngle * 1.4117647f);
if (type == 4)
{
outer = (byte)Math.Max(Math.Max(la.Extent.X, la.Extent.Y), la.Extent.Z);
outer = (byte)Math.Round(la.Extent.X * 1.82f);
}

View File

@ -1057,7 +1057,7 @@ namespace CodeWalker.Rendering
RenderSelectionCone(pos, tx, ty, dir, (float)Math.Sin(innerAngle) * extent, (float)Math.Cos(innerAngle) * extent, colwht);
break;
case LightType.Capsule:
outerAngle = light.ConeOuterAngle * 0.25f;
outerAngle = light.Extent.X * 0.5f;
RenderSelectionCapsule(pos, tx, ty, dir, extent, outerAngle, colwht);
break;
}