This commit is contained in:
Ape committed 2026-04-12 19:07:06 +02:00
1 parent 6a5fbe7300
commit 3e4d833b66
5 files changed
+15 -6

No files matched your search

+1 -1
View File
@@ -42,7 +42,7 @@ public partial class Main : BasePlugin
public static bool HasArgumentException;
public static string CredentialsText;
public const string ModVersion = "v1.7.0";
public const string ModVersion = "v1.7.1";
public static float GameTimer;
+6 -1
View File
@@ -116,7 +116,12 @@ public static class CustomRoleManagement
private static int PendingRoleMessages = 0;
public static void SendRoleMessages(Dictionary<string, string> roleMessages)
{
if (PlayerRoles.Count == 0 || PlayerControl.LocalPlayer.Data.IsDead) return;
if (PlayerRoles.Count == 0 || PlayerControl.LocalPlayer.Data.IsDead)
{
HandlingRoleMessages = false;
PendingRoleMessages = 0;
return;
}
HashSet<string> sentRoles = new HashSet<string>();
+3 -3
View File
@@ -243,10 +243,10 @@ internal static class SendChatPatch
if (!isKick && !isBan && !isColorKick && !isColorBan)
{
__instance.freeChatField.textArea.SetText(converted);
Utils.ChatCommand(__instance, $"{converted}", "", false);
//__instance.freeChatField.textArea.SetText(converted);
//Utils.ChatCommand(__instance, $"{converted}", "", false);
Logger.Info($" {PlayerControl.LocalPlayer.Data.PlayerName}: {msgtext}", "SendChat");
return false;
return true;
}
string arg = text.Substring(isKick ? 6 : isBan ? 5 : isColorKick ? 7 : isColorBan ? 6 : 0).Trim();
+4
View File
@@ -38,6 +38,8 @@ class PlayerControlSetRolePatch
{
if (!FirstAssign || !AmongUsClient.Instance.AmHost) return true;
var oldRole = roleType;
canOverrideRole = false;
if (Main.GM.Value && __instance == PlayerControl.LocalPlayer)
@@ -57,6 +59,7 @@ class PlayerControlSetRolePatch
{
roleType = RoleTypes.Crewmate;
}
Logger.Info($" {__instance.Data.PlayerName} | {oldRole} -> {roleType}", "ChangedRoleBase");
}
if (CustomRoleManagement.PlayerRoles.TryGetValue(__instance.PlayerId, out var r) && r == "Jester" && Options.Gamemode.GetValue() < 2)
{
@@ -69,6 +72,7 @@ class PlayerControlSetRolePatch
{
roleType = RoleTypes.Crewmate;
}
Logger.Info($" {__instance.Data.PlayerName} | {oldRole} -> {roleType}", "ChangedRoleBase");
}
if (Utils.isHideNSeek && i == 0)
+1 -1
View File
@@ -29,7 +29,7 @@
<img src="https://github.com/astra1dev/AUnlocker/assets/90265231/14226f03-a003-4efc-b27b-6df53fb394d6" width=410 height=240>****
‎
# 🎮 Features (v1.7.0):
# 🎮 Features (v1.7.1):
## <b> 🌟 Custom Roles:</b>
- Mayor (Crewmate)
- The mayor has extra votes and can call meetings by venting, depending on settings.