diff --git a/MiraAPI/MiraAPI.csproj b/MiraAPI/MiraAPI.csproj index d15783ec..e4dad349 100644 --- a/MiraAPI/MiraAPI.csproj +++ b/MiraAPI/MiraAPI.csproj @@ -9,12 +9,7 @@ Simple and easy to use Among Us modding API. Angxl, XtraCube - - - Steam - 2024.8.13 - - + @@ -29,7 +24,7 @@ - + diff --git a/MiraAPI/Patches/Roles/EjectionPatches.cs b/MiraAPI/Patches/Roles/EjectionPatches.cs index f6ca0e11..60c0dfe0 100644 --- a/MiraAPI/Patches/Roles/EjectionPatches.cs +++ b/MiraAPI/Patches/Roles/EjectionPatches.cs @@ -11,16 +11,16 @@ public static class EjectionPatches [HarmonyPatch(nameof(ExileController.Begin))] public static void Begin(ExileController __instance) { - if (!__instance.exiled?.Role || __instance.exiled.Role is not ICustomRole role) + if (!__instance.initData.networkedPlayer.Role || __instance.initData.networkedPlayer.Role is not ICustomRole role) { return; } - if (role.GetCustomEjectionMessage(__instance.exiled) == null) + if (role.GetCustomEjectionMessage(__instance.initData.networkedPlayer) == null) { return; } - __instance.completeString = role.GetCustomEjectionMessage(__instance.exiled); + __instance.completeString = role.GetCustomEjectionMessage(__instance.initData.networkedPlayer); } } \ No newline at end of file