Skip to content

Commit

Permalink
Fix assembly shim output for older Unity versions due to non-explicit…
Browse files Browse the repository at this point in the history
… class layouts
  • Loading branch information
LukeFZ committed Dec 10, 2023
1 parent 7b03b93 commit 6b060c2
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Il2CppInspector.Common/Outputs/AssemblyShims.cs
Original file line number Diff line number Diff line change
Expand Up @@ -185,7 +185,7 @@ private TypeDefUser CreateTypeShallow(ModuleDef module, TypeInfo type)
Attributes = (TypeAttributes)type.Attributes
};

if (mType.IsExplicitLayout)
if (mType.IsExplicitLayout || mType.IsSequentialLayout)
mType.ClassLayout = new ClassLayoutUser(1, (uint)type.Sizes.nativeSize);

// Add nested types
Expand Down

0 comments on commit 6b060c2

Please sign in to comment.