mirror of
https://github.com/Gurge44/EndlessHostRoles.git
synced 2026-10-20 01:46:25 +00:00
Add Concealer
This commit is contained in:
1 parent
6de334b3eb
commit
2156e47619
6 files changed
+24
-6
No files matched your search
@@ -508,6 +508,7 @@ public enum CustomRoles
|
||||
Commited,
|
||||
Compelled,
|
||||
Composter,
|
||||
Concealer,
|
||||
Contagious,
|
||||
Damocles,
|
||||
Deadlined,
|
||||
|
||||
@@ -657,6 +657,7 @@ public class Main : BasePlugin
|
||||
{ CustomRoles.Listener, "#060270" },
|
||||
{ CustomRoles.Unbound, "#DFC57B" },
|
||||
{ CustomRoles.AntiTP, "#fcba03" },
|
||||
{ CustomRoles.Concealer, "#595959" },
|
||||
{ CustomRoles.Composter, "#8D6F64" },
|
||||
{ CustomRoles.TaskMaster, "#00ffa5" },
|
||||
{ CustomRoles.Compelled, "#D2E44C" },
|
||||
|
||||
@@ -971,6 +971,7 @@ internal static class CustomRoleSelector
|
||||
|
||||
switch (role)
|
||||
{
|
||||
case CustomRoles.Concealer when Options.AnonymousBodies.GetBool():
|
||||
case CustomRoles.Autopsy when Options.EveryoneSeesDeathReasons.GetBool():
|
||||
case CustomRoles.Gravestone when Options.EveryoneSeesDeadPlayersRoles.GetBool():
|
||||
case CustomRoles.Mare or CustomRoles.Glow or CustomRoles.Sleep when Main.CurrentMap == MapNames.Fungle:
|
||||
|
||||
@@ -1946,12 +1946,12 @@ internal static class ExtendedPlayerControl
|
||||
IncreaseAbilityUseLimitOnKill(killer);
|
||||
|
||||
target.SetRealKiller(killer, true);
|
||||
|
||||
PlayerControl realKiller = Main.PlayerStates.TryGetValue(target.PlayerId, out PlayerState state) ? state.RealKiller.ID.GetPlayer() ?? killer : killer;
|
||||
if (realKiller == null) realKiller = killer;
|
||||
|
||||
if (target.PlayerId == Godfather.GodfatherTarget)
|
||||
{
|
||||
PlayerControl realKiller = Main.PlayerStates.TryGetValue(target.PlayerId, out PlayerState state) ? state.RealKiller.ID.GetPlayer() ?? killer : killer;
|
||||
realKiller.RpcSetCustomRole(CustomRoles.Refugee);
|
||||
}
|
||||
|
||||
if (target.Is(CustomRoles.Jackal)) Jackal.Instances.Do(x => x.PromoteSidekick());
|
||||
|
||||
@@ -1960,7 +1960,7 @@ internal static class ExtendedPlayerControl
|
||||
if (killer.IsLocalPlayer() && !killer.HasKillButton() && killer.PlayerId != target.PlayerId && Options.CurrentGameMode == CustomGameMode.Standard)
|
||||
Achievements.Type.InnocentKiller.Complete();
|
||||
|
||||
if (Options.AnonymousBodies.GetBool())
|
||||
if (Options.AnonymousBodies.GetBool() || realKiller.Is(CustomRoles.Concealer))
|
||||
{
|
||||
Main.AllPlayerSpeed[target.PlayerId] = Main.MinSpeed;
|
||||
target.SyncSettings();
|
||||
@@ -2004,8 +2004,8 @@ internal static class ExtendedPlayerControl
|
||||
|
||||
killer.RpcMurderPlayer(target, true);
|
||||
|
||||
if (Main.PlayerStates.TryGetValue(target.PlayerId, out var state) && !state.IsDead)
|
||||
state.SetDead();
|
||||
if (Main.PlayerStates.TryGetValue(target.PlayerId, out var playerState) && !playerState.IsDead)
|
||||
playerState.SetDead();
|
||||
|
||||
LateTask.New(() =>
|
||||
{
|
||||
|
||||
@@ -9237,6 +9237,10 @@
|
||||
"AgitaterTargetNotify": "<size=110%><#ffff00>YOU HAVE THE BOMB!!</color>\\n<#ffa500>Pass it to someone else or die!</color></size>",
|
||||
"AgitaterCanGetBombed": "<color=#F4A460>Agitator</color> can get the bomb",
|
||||
"AgitaterAutoReportBait": "<color=#F4A460>Agitator</color> Auto Report Bait",
|
||||
"Concealer": "Concealer",
|
||||
"ConcealerInfo": "Your Kills are Anonymous",
|
||||
"ConcealerInfoLong": "(Add-ons):\\nAs the Concealer, each body of yours will be camouflaged.",
|
||||
"Prefix.Concealer": "Concealer",
|
||||
"Investor": "Investor",
|
||||
"InvestorInfo": "Invest in Players",
|
||||
"InvestorInfoLong": "(Neutrals):\\nAs the Investor, you can mark players using your kill button to invest in them. At the end, you win with the winning team if at least a set percentage of your marked players have won.",
|
||||
|
||||
@@ -0,0 +1,11 @@
|
||||
namespace EHR.AddOns.Common;
|
||||
|
||||
public class Concealer : IAddon
|
||||
{
|
||||
public AddonTypes Type => AddonTypes.ImpOnly;
|
||||
|
||||
public void SetupCustomOption()
|
||||
{
|
||||
Options.SetupAdtRoleOptions(656200, CustomRoles.Concealer, canSetNum: true);
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user