We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 07d0c41 commit 4dc4236Copy full SHA for 4dc4236
1 file changed
KSPCommunityFixes/BugFixes/ModuleIndexingMismatch.cs
@@ -472,9 +472,17 @@ static IEnumerable<CodeInstruction> ShipConstruct_LoadShip_Transpiler(IEnumerabl
472
Debug.LogError($"Error applying ModuleIndexingMismatch patch : couldn't find Part.LoadModule() call in ShipConstruct.LoadShip()");
473
return instructions;
474
}
475
-
476
- // then, insert our own module loading call before the original part nodes parsing loop
477
- for (int i = 0; i < code.Count - 6; i++)
+ uint minusCount;
+ if (!KSPCommunityFixes.cleanedDll)
+ {
478
+ minusCount = 6;
479
+ }
480
+ else
481
482
+ minusCount = 5;
483
484
+ // then, insert our own module loading call before the original part nodes parsing loop
485
+ for (int i = 0; i < code.Count - minusCount; i++)
486
{
487
//// int moduleIndex = 0;
488
// ldc.i4.0 NULL
0 commit comments