More accurate comments in the new hookup transpilers

This commit is contained in:
lutepickle 2022-05-28 21:28:20 -07:00
parent 7461965174
commit 3480366337
1 changed files with 2 additions and 2 deletions

View File

@ -195,12 +195,12 @@ namespace RJW_Menstruation
private static readonly FieldInfo MinimumFuckabilityToHookup = AccessTools.Field(typeof(RJWHookupSettings), nameof(RJWHookupSettings.MinimumFuckabilityToHookup));
public static IEnumerable<CodeInstruction> Transpiler(IEnumerable<CodeInstruction> instructions)
{
// We only want the first fuckability check, i.e. the estrus-haver towards a partner
bool first_fuckability = true;
foreach(CodeInstruction instruction in instructions)
{
if(instruction.LoadsField(MinimumFuckabilityToHookup))
{
// The first load will be for the estrus-haver considering a partner, the second for a pawn considering the estrus-haver
yield return new CodeInstruction(first_fuckability ? OpCodes.Ldarg_0 : OpCodes.Ldarg_1);
yield return new CodeInstruction(first_fuckability ? OpCodes.Ldarg_1 : OpCodes.Ldarg_0);
@ -231,7 +231,7 @@ namespace RJW_Menstruation
public static IEnumerable<CodeInstruction> Transpiler(IEnumerable<CodeInstruction> instructions)
{
LocalBuilder pawn_index = null;
// Like in the last one, we're only interested in the first of each
// Like in the last one, we switch the arguments around for the second load
bool first_attractiveness = true;
bool first_relationship = true;
foreach(CodeInstruction instruction in instructions)