Skip to content

Commit

Permalink
Fix patching issue
Browse files Browse the repository at this point in the history
Signed-off-by: FakeMan2332 <[email protected]>
  • Loading branch information
fakeman2332 committed Aug 21, 2023
1 parent a04a0ab commit 38ef2f3
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion MERRoomReplacement/MERRoomReplacement.cs
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ public class MERRoomReplacement : Plugin<Config>

public override string Prefix => "room_replacement";

public override Version Version => new(1, 2, 0);
public override Version Version => new(1, 2, 1);

public override void OnEnabled()
{
Expand Down
4 changes: 2 additions & 2 deletions MERRoomReplacement/Patches/RemoveScp079FromSpawnQueue.cs
Original file line number Diff line number Diff line change
Expand Up @@ -13,13 +13,13 @@ public static class RemoveScp079FromSpawnQueue
{
public static void PatchSpawnQueue(Harmony harmony)
{
var originalMethod = typeof(ScpSpawner).GetProperty(nameof(ScpSpawner.SpawnableScps))?.GetMethod;
var originalMethod = PropertyGetter(typeof(ScpSpawner), nameof(ScpSpawner.SpawnableScps));
var transpiler = new HarmonyMethod(typeof(RemoveScp079FromSpawnQueue), nameof(Transpiler));

harmony.Patch(originalMethod, transpiler: transpiler);
}

private static IEnumerable<CodeInstruction> Transpiler(IEnumerable<CodeInstruction> instructions, ILGenerator generator)
internal static IEnumerable<CodeInstruction> Transpiler(IEnumerable<CodeInstruction> instructions, ILGenerator generator)
{
var newInstructions = ListPool<CodeInstruction>.Pool.Get(instructions);

Expand Down

0 comments on commit 38ef2f3

Please sign in to comment.