This commit is contained in:
Ape committed 2026-06-12 11:51:57 +02:00
1 parent 8e013830b6
commit f456eb63d5
9 files changed
+57 -21

No files matched your search

+2 -2
View File
@@ -43,7 +43,7 @@ public partial class Main : BasePlugin
public static bool HasArgumentException;
public static string CredentialsText;
public const string ModVersion = "v1.8.0";
public const string ModVersion = "v1.8.1";
public static float GameTimer;
@@ -97,7 +97,7 @@ public partial class Main : BasePlugin
Translator.Init();
Translator.Reload();
BanManager.Init();
Harmony.PatchAll();
ConsoleManager.DetachConsole();
+3 -3
View File
@@ -165,7 +165,7 @@ public static class AbilityManagement
private static int PendingRoleMessages = 0;
public static void SendRoleMessages()
{
if (!AmongUsClient.Instance.AmHost) return;
if (!AmongUsClient.Instance.AmHost || Options.Gamemode.GetValue() > 1) return;
if (string.IsNullOrEmpty(RoleList()) || PlayerControl.LocalPlayer.Data.IsDead)
{
@@ -175,12 +175,12 @@ public static class AbilityManagement
}
var players = PlayerControl.AllPlayerControls.ToArray().ToList();
float delay = 4.4f;
float delay = 6.6f;
PendingRoleMessages = 0;
HandlingRoleMessages = true;
SendRoleList(DestroyableSingleton<HudManager>.Instance.Chat, AbilityManagement.RoleList(), false);
SendRoleList(DestroyableSingleton<HudManager>.Instance.Chat, AbilityManagement.RoleList(), true);
foreach (var player in players)
{
+1
View File
@@ -19,6 +19,7 @@ public static class Translator
public static void Init()
{
Logger.Info($" Among Us Revamped {Main.ModVersion}", "Init");
CheckLanguageFile(_currentLang);
LoadLanguage(_currentLang);
}
+2 -2
View File
@@ -231,8 +231,8 @@ public static class Utils
PlayerControlSetRolePatch.Seekers.Clear();
PlayerControlSetRolePatch.Jesters.Clear();
PlayerControlSetRolePatch.FirstAssign = true;
CoShowIntroPatch.ScheduleExile = false;
OnGameStartPatch.ScheduleExile = false;
CoShowIntroPatch.IntroInitiated = false;
}
@@ -578,7 +578,7 @@ public static class Utils
return null;
}
Logger.Info($"Found {methodName}.MoveNext", "GetStateMachineMoveNext");
// Logger.Info($"Found {methodName}.MoveNext", "GetStateMachineMoveNext");
return moveNext;
}
+27 -1
View File
@@ -180,6 +180,7 @@ namespace AmongUsRevamped
private static PassiveButton template;
private static PassiveButton discordButton;
private static PassiveButton gitHubButton;
private static PassiveButton animationSceneButton;
private static Transform buttonParent;
public static void Postfix(MainMenuManager __instance)
{
@@ -212,6 +213,18 @@ namespace AmongUsRevamped
"GitHub");
}
if (animationSceneButton == null)
{
animationSceneButton = CreateButton(
__instance,
"AnimationTestSceneButton",
new(0f, 2.65f, 1f),
new(139, 0, 0, byte.MaxValue),
new(255, 127, 127, byte.MaxValue),
() => SceneChanger.ChangeScene("AnimationTestScene"),
"Animation Tester");
}
var bg = GameObject.Find("BackgroundTexture");
if (bg != null)
{
@@ -230,6 +243,12 @@ namespace AmongUsRevamped
div.SetActive(false);
}
var logo = GameObject.Find("MainUI/AspectScaler/LeftPanel/Sizer/LOGO-AU");
if (logo != null)
{
logo.SetActive(false);
}
Transform tintTrans = __instance.transform.Find("MainUI/Tint");
var tint = tintTrans.gameObject;
@@ -290,7 +309,14 @@ namespace AmongUsRevamped
button.name = name;
button.transform.localPosition = localPosition;
button.transform.localScale = new Vector3(0.8f, 1f, 1f);
if (name == "GitHubButton" || name == "DiscordButton")
{
button.transform.localScale = new Vector3(0.8f, 1f, 1f);
}
else
{
button.transform.localScale = new Vector3(1.8f, 1.6f, 1f);
}
var aspect = button.GetComponent<AspectPosition>();
if (aspect != null)
+1 -8
View File
@@ -10,7 +10,6 @@ namespace AmongUsRevamped;
internal static class CoShowIntroPatch
{
public static bool IntroInitiated;
public static bool ScheduleExile;
public static void Postfix(IntroCutscene __instance)
{
Logger.Info(" Intro initiated", "CoShowIntro");
@@ -32,12 +31,6 @@ internal static class CoShowIntroPatch
Logger.Info($" {p.Data.PlayerName} -> {p.Data.RoleType}", "RoleInfo");
}
if (ScheduleExile)
{
PlayerControl.LocalPlayer.Exiled();
ScheduleExile = false;
}
Logger.Info($" {AbilityManagement.RoleList()}", "AbilityInfo");
@@ -57,7 +50,7 @@ internal static class CoShowIntroPatch
PlayerControl.LocalPlayer.CmdReportDeadBody(null);
if (MeetingHud.Instance != null) MeetingHud.Instance.RpcClose();
}, 9f, "SetChatVisible");
}, 9.5f, "SetChatVisible");
}
}
}
+17 -2
View File
@@ -13,8 +13,9 @@ internal class CoStartGamePatch
if (!AmongUsClient.Instance.AmHost) return;
Logger.Info(" -------- GAME STARTED --------", "StartGame");
Logger.Info($" Gamemode: {Options.Gamemode.GetValue()}", "StartGame");
Logger.Info($" Gamemode: {Options.Gamemode.GetString()}", "StartGame");
Logger.Info($" Players: {PlayerControl.AllPlayerControls.Count}", "StartGame");
Logger.Info($" Map: {(MapNames)GameOptionsManager.Instance.CurrentGameOptions.MapId}", "StartGame");
NormalGameEndChecker.imps.Clear();
NormalGameEndChecker.LastWinReason = "";
@@ -42,7 +43,7 @@ class PlayerControlSetRolePatch
if (Main.GM.Value && __instance == PlayerControl.LocalPlayer)
{
roleType = RoleTypes.Crewmate;
CoShowIntroPatch.ScheduleExile = true;
OnGameStartPatch.ScheduleExile = true;
}
if (Utils.isHideNSeek && Seekers.Count() == 0)
@@ -107,4 +108,18 @@ class PlayerControlSetRolePatch
return true;
}
}
[HarmonyPatch(typeof(HudManager), nameof(HudManager.OnGameStart))]
internal static class OnGameStartPatch
{
public static bool ScheduleExile;
public static void Postfix()
{
if (ScheduleExile)
{
PlayerControl.LocalPlayer.Exiled();
ScheduleExile = false;
}
}
}
+2 -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.8.0):
# 🎮 Features (v1.8.1):
## <b> 🌟 Custom Abilities:</b>
- Mayor (Crewmate)
- The Mayor has a configurable amount of extra votes
@@ -99,6 +99,7 @@
- See player kill/task count and Role when dead
- Higher and more accurate Option ranges
- Always visible lobby timer
- Access experimental animation test scene
- <b>🎉 And this all works in public lobbies!</b>
### Hotkeys
+2 -2
View File
@@ -10,7 +10,7 @@
"disableInfoWhenDead": "Hide Info When Dead",
"disableCommandHelper": "Disable Command Helper",
"gameMasterWarning":"You will now spectate games until Game Master is turned off. WARNING: Ability messages will not be sent if this setting is enabled.",
"gameMasterWarning":"You will now spectate games until Game Master is turned off. WARNING: Ability messages will not be sent and role assigning might be inaccurate if this setting is enabled.",
"cancelStartCountdown": "Start countdown canceled",
@@ -19,7 +19,7 @@
"kickLowLevelPlayer": "Kick Players Under Level",
"tempBanLowLevelPlayer": "Ban Instead Of Kick",
"dontKickLevelOnes": "Don't Kick Lv.1 Players For Glitched Lobbies",
"kickInvalidFriendCodes": "Kick Invalid FriendCodes",
"kickInvalidFriendCodes": "Kick Invalid (Empty) Friendcodes",
"tempBanInvalidFriendCodes": "Ban Instead Of Kick",
"deniedWordsToKick": "Sent Denied Words To Kick Player",
"applyBanList": "Apply BanList",