Skip to content

Commit 3927546

Browse files
cleaning
1 parent 68e4e44 commit 3927546

1 file changed

Lines changed: 4 additions & 7 deletions

File tree

NewMod/Buttons/RevivedKillButton.cs

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@
44
using NewMod.Roles.ImpostorRoles;
55
using Reactor.Utilities;
66
using AmongUs.GameOptions;
7-
using System.Linq;
87
using UnityEngine;
98
using MiraAPI.Networking;
109
using MiraAPI.Utilities;
@@ -20,26 +19,24 @@ public class RevivedKillButton : CustomActionButton<PlayerControl>
2019
public override MiraKeybind Keybind => MiraGlobalKeybinds.PrimaryAbility;
2120
public override ButtonLocation Location => ButtonLocation.BottomRight;
2221
public override LoadableAsset<Sprite> Sprite => NewModAsset.VanillaKillButton;
22+
2323
public override bool Enabled(RoleBehaviour role)
2424
{
2525
return NecromancerRole.RevivedPlayers.ContainsKey(PlayerControl.LocalPlayer.PlayerId);
2626
}
27+
2728
public override PlayerControl GetTarget()
2829
{
2930
return PlayerControl.LocalPlayer.GetClosestPlayer(true, Distance);
3031
}
31-
public override bool IsTargetValid(PlayerControl target)
32-
{
33-
return target.PlayerId != PlayerControl.LocalPlayer.PlayerId;
34-
}
32+
3533
public override void SetOutline(bool active)
3634
{
3735
Target.cosmetics.SetOutline(active, new Il2CppSystem.Nullable<Color>(Palette.ImpostorRed));
3836
}
3937

4038
public override bool CanUse()
4139
{
42-
if (!NecromancerRole.RevivedPlayers.ContainsKey(PlayerControl.LocalPlayer.PlayerId)) return false;
4340
return true;
4441
}
4542

@@ -60,4 +57,4 @@ protected override void OnClick()
6057
NecromancerRole.RevivedPlayers.Remove(local.PlayerId);
6158
}
6259
}
63-
}
60+
}

0 commit comments

Comments
 (0)