From 19d003dd3c220e17cf629b0d7e9cd393d4ac5fc0 Mon Sep 17 00:00:00 2001 From: Hamunii Date: Sun, 14 Apr 2024 13:32:11 +0300 Subject: [PATCH] fix incorrect type in MonoMod Examples --- docs/dev/fundamentals/patching-code/monomod-examples.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/dev/fundamentals/patching-code/monomod-examples.md b/docs/dev/fundamentals/patching-code/monomod-examples.md index 40c100e5474..6b5d1ccd320 100644 --- a/docs/dev/fundamentals/patching-code/monomod-examples.md +++ b/docs/dev/fundamentals/patching-code/monomod-examples.md @@ -445,7 +445,7 @@ private static void Transform_set_position(ILContext il) // Emit a call to our own method named PrintPosition in class MyPatches, // which takes a (valuetype UnityEngine.Vector3&) by reference as argument, // because ldarga.s loads the address of 'value' onto stack - c.Emit(OpCodes.Call, AccessTools.DeclaredMethod(typeof(LogPlayerPosition), nameof(PrintPosition))); + c.Emit(OpCodes.Call, AccessTools.DeclaredMethod(typeof(MyPatches), nameof(PrintPosition))); // The following IL code is after us: // IL_0003: call instance void UnityEngine.Transform::set_position_Injected(valuetype UnityEngine.Vector3&)