Files
tbd-station-14/Content.Server/Mobs/Roles/Suspicion/SuspicionInnocentRole.cs
DrSmugleaf 548ef3dedb Add HUD button that displays your SSS role and allies (#1895)
* Add button that displays your SSS role and allies

* Capitalize button name

* Add cases for 0, 1 and invalid number of allies

* Make the ally syncing system saner
2020-08-27 16:39:29 +02:00

32 lines
955 B
C#

using Content.Server.Interfaces.Chat;
using Content.Shared.Roles;
using Robust.Shared.IoC;
namespace Content.Server.Mobs.Roles.Suspicion
{
public class SuspicionInnocentRole : SuspicionRole
{
public AntagPrototype Prototype { get; }
public SuspicionInnocentRole(Mind mind, AntagPrototype antagPrototype) : base(mind)
{
Prototype = antagPrototype;
Name = antagPrototype.Name;
Antagonist = antagPrototype.Antagonist;
}
public override string Name { get; }
public string Objective => Prototype.Objective;
public override bool Antagonist { get; }
public override void Greet()
{
base.Greet();
var chat = IoCManager.Resolve<IChatManager>();
chat.DispatchServerMessage(Mind.Session, $"You're an {Name}!");
chat.DispatchServerMessage(Mind.Session, $"Objective: {Objective}");
}
}
}