From df2f9818e4fc5e9057471f570f4b78c1a34e9507 Mon Sep 17 00:00:00 2001 From: Limeau <148590907+Limeau@users.noreply.github.com> Date: Sun, 2 Aug 2026 01:46:26 -0700 Subject: [PATCH] Add Vitals to Fox (#666) * Update ChatCommandPatch.cs * Update RPC.cs * BAU support * more flags * revert unnecessary chatcommandpatch changes * add setting to add Vitals to Fox --------- Co-authored-by: lime1 Co-authored-by: Gurge44 <90392754+Gurge44@users.noreply.github.com> --- Modules/CustomRolesHelper.cs | 2 +- Resources/Lang/en_US.json | 1 + Roles/HideAndSeek/Fox.cs | 8 +++++++- 3 files changed, 9 insertions(+), 2 deletions(-) diff --git a/Modules/CustomRolesHelper.cs b/Modules/CustomRolesHelper.cs index 0fd9a9785..049d49071 100644 --- a/Modules/CustomRolesHelper.cs +++ b/Modules/CustomRolesHelper.cs @@ -412,7 +412,7 @@ internal static class CustomRolesHelper // Hide And Seek CustomRoles.Hider => CustomRoles.Crewmate, CustomRoles.Seeker => CustomRoles.Impostor, - CustomRoles.Fox => CustomRoles.Crewmate, + CustomRoles.Fox => Fox.HasVitals.GetBool() ? CustomRoles.Scientist : CustomRoles.Crewmate, CustomRoles.Troll => CustomRoles.Crewmate, CustomRoles.Jumper => CustomRoles.Engineer, CustomRoles.Detector => CustomRoles.Crewmate, diff --git a/Resources/Lang/en_US.json b/Resources/Lang/en_US.json index 598480b54..bf003d844 100644 --- a/Resources/Lang/en_US.json +++ b/Resources/Lang/en_US.json @@ -4494,6 +4494,7 @@ "FoxInfoLong": "Survive until the end to win", "FoxSpeed": "Fox Speed", "FoxVision": "Fox Vision", + "FoxHasVitals": "Fox has Vitals", "Hider": "Hider", "HiderInfo": "Complete tasks and survive until the end", "HiderInfoLong": "Complete tasks and survive until the end", diff --git a/Roles/HideAndSeek/Fox.cs b/Roles/HideAndSeek/Fox.cs index 46951d2f5..30ecd2de1 100644 --- a/Roles/HideAndSeek/Fox.cs +++ b/Roles/HideAndSeek/Fox.cs @@ -6,6 +6,7 @@ internal class Fox : RoleBase, IHideAndSeekRole public static OptionItem Vision; public static OptionItem Speed; + public static OptionItem HasVitals; public override bool IsEnable => On; public Team Team => Team.Neutral; @@ -21,7 +22,7 @@ internal class Fox : RoleBase, IHideAndSeekRole .SetGameMode(CustomGameMode.HideAndSeek); Options.SetupRoleOptions(69_211_301, TabGroup.NeutralRoles, CustomRoles.Fox, CustomGameMode.HideAndSeek); - + Vision = new FloatOptionItem(69_211_303, "FoxVision", new(0.05f, 5f, 0.05f), 1.25f, TabGroup.NeutralRoles) .SetGameMode(CustomGameMode.HideAndSeek) .SetValueFormat(OptionFormat.Multiplier) @@ -33,6 +34,11 @@ internal class Fox : RoleBase, IHideAndSeekRole .SetValueFormat(OptionFormat.Multiplier) .SetColor(new(0, 255, 0, byte.MaxValue)) .SetParent(Options.CustomRoleSpawnChances[CustomRoles.Fox]); + + HasVitals = new BooleanOptionItem(69_213_305, "FoxHasVitals", true, TabGroup.NeutralRoles) + .SetGameMode(CustomGameMode.HideAndSeek) + .SetColor(new(0, 255, 0, byte.MaxValue)) + .SetParent(Options.CustomRoleSpawnChances[CustomRoles.Fox]); } public override void Add(byte playerId)