mirror of
https://github.com/Gurge44/EndlessHostRoles.git
synced 2026-10-20 01:46:25 +00:00
fix
This commit is contained in:
1 parent
c626e52dbf
commit
ba267393f0
4 files changed
+9
-8
No files matched your search
@@ -5,6 +5,7 @@
|
||||
<s:String x:Key="/Default/CodeStyle/Naming/CSharpNaming/Abbreviations/=AFK/@EntryIndexedValue">AFK</s:String>
|
||||
<s:String x:Key="/Default/CodeStyle/Naming/CSharpNaming/Abbreviations/=ATK/@EntryIndexedValue">ATK</s:String>
|
||||
<s:String x:Key="/Default/CodeStyle/Naming/CSharpNaming/Abbreviations/=AU/@EntryIndexedValue">AU</s:String>
|
||||
<s:String x:Key="/Default/CodeStyle/Naming/CSharpNaming/Abbreviations/=BAU/@EntryIndexedValue">BAU</s:String>
|
||||
<s:String x:Key="/Default/CodeStyle/Naming/CSharpNaming/Abbreviations/=CD/@EntryIndexedValue">CD</s:String>
|
||||
<s:String x:Key="/Default/CodeStyle/Naming/CSharpNaming/Abbreviations/=CK/@EntryIndexedValue">CK</s:String>
|
||||
<s:String x:Key="/Default/CodeStyle/Naming/CSharpNaming/Abbreviations/=CNO/@EntryIndexedValue">CNO</s:String>
|
||||
|
||||
@@ -393,7 +393,7 @@ internal static class CustomRolesHelper
|
||||
CustomRoles.Sidekick => RoleTypes.Impostor,
|
||||
CustomRoles.SwordsMan => UsePets && SwordsMan.UsePet.GetBool() ? RoleTypes.GuardianAngel : RoleTypes.Impostor,
|
||||
CustomRoles.Innocent => RoleTypes.Impostor,
|
||||
CustomRoles.Amnesiac when Amnesiac.RememberMode.GetValue() == 0 => RoleTypes.Impostor,
|
||||
CustomRoles.Amnesiac when Amnesiac.RememberMode.GetValue() == 1 => RoleTypes.Impostor,
|
||||
CustomRoles.Pelican => RoleTypes.Impostor,
|
||||
CustomRoles.Aid => UsePets && Aid.UsePet.GetBool() ? RoleTypes.GuardianAngel : RoleTypes.Impostor,
|
||||
CustomRoles.Socialite => UsePets && Socialite.UsePet.GetBool() ? RoleTypes.GuardianAngel : RoleTypes.Impostor,
|
||||
@@ -832,7 +832,7 @@ internal static class CustomRolesHelper
|
||||
CustomRoles.Nimble when pc.Is(CustomRoles.Oxyman) => false,
|
||||
CustomRoles.Magnet when pc.Is(Team.Impostor) => false,
|
||||
CustomRoles.Swift when pc.Is(CustomRoles.Magnet) => false,
|
||||
CustomRoles.Oblivious when pc.Is(CustomRoles.Amnesiac) && Amnesiac.RememberMode.GetValue() == 1 => false,
|
||||
CustomRoles.Oblivious when pc.Is(CustomRoles.Amnesiac) && Amnesiac.RememberMode.GetValue() == 0 => false,
|
||||
CustomRoles.Rookie when !pc.CanUseKillButton() => false,
|
||||
CustomRoles.Energetic when !Options.UsePets.GetBool() => false,
|
||||
CustomRoles.Madmate when pc.Is(CustomRoles.Sidekick) => false,
|
||||
|
||||
@@ -100,7 +100,7 @@ public static class HudSpritePatch
|
||||
newAbilityButton = CustomButton.Get("Commander");
|
||||
break;
|
||||
case CustomRoles.Amnesiac:
|
||||
if (Amnesiac.RememberMode.GetValue() == 0) newKillButton = CustomButton.Get("AmnesiacKill");
|
||||
if (Amnesiac.RememberMode.GetValue() == 1) newKillButton = CustomButton.Get("AmnesiacKill");
|
||||
else newReportButton = CustomButton.Get("AmnesiacReport");
|
||||
break;
|
||||
case CustomRoles.Assassin:
|
||||
|
||||
@@ -65,12 +65,12 @@ public class Amnesiac : RoleBase
|
||||
}
|
||||
|
||||
public override void SetKillCooldown(byte id) => Main.AllPlayerKillCooldown[id] = RememberCooldown.GetFloat();
|
||||
public override bool CanUseKillButton(PlayerControl player) => !player.Data.IsDead && RememberMode.GetValue() == 0;
|
||||
public override bool CanUseKillButton(PlayerControl player) => !player.Data.IsDead && RememberMode.GetValue() == 1;
|
||||
public override void ApplyGameOptions(IGameOptions opt, byte playerId) => opt.SetVision(false);
|
||||
|
||||
public static void OnAnyoneDeath(PlayerControl target)
|
||||
{
|
||||
if (RememberMode.GetValue() == 1)
|
||||
if (RememberMode.GetValue() == 0)
|
||||
{
|
||||
foreach (Amnesiac instance in Instances)
|
||||
{
|
||||
@@ -83,7 +83,7 @@ public class Amnesiac : RoleBase
|
||||
|
||||
public override bool OnCheckMurder(PlayerControl killer, PlayerControl target)
|
||||
{
|
||||
if (RememberMode.GetValue() == 0)
|
||||
if (RememberMode.GetValue() == 1)
|
||||
{
|
||||
RememberRole(killer, target);
|
||||
}
|
||||
@@ -93,7 +93,7 @@ public class Amnesiac : RoleBase
|
||||
|
||||
public override bool CheckReportDeadBody(PlayerControl reporter, NetworkedPlayerInfo target, PlayerControl killer)
|
||||
{
|
||||
if (RememberMode.GetValue() == 1)
|
||||
if (RememberMode.GetValue() == 0)
|
||||
{
|
||||
RememberRole(reporter, target.Object);
|
||||
return false;
|
||||
@@ -212,7 +212,7 @@ public class Amnesiac : RoleBase
|
||||
|
||||
public override void SetButtonTexts(HudManager hud, byte id)
|
||||
{
|
||||
ActionButton amneButton = RememberMode.GetValue() == 0 ? hud.KillButton : hud.ReportButton;
|
||||
ActionButton amneButton = RememberMode.GetValue() == 1 ? hud.KillButton : hud.ReportButton;
|
||||
amneButton?.OverrideText(GetString("RememberButtonText"));
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user