File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 44using NewMod . Roles . ImpostorRoles ;
55using Reactor . Utilities ;
66using AmongUs . GameOptions ;
7- using System . Linq ;
87using UnityEngine ;
98using MiraAPI . Networking ;
109using 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+ }
You can’t perform that action at this time.
0 commit comments