commandList.Add(id);
}
- return IsGroupDetainedOrDead(commandList, true, true);
+ return IsGroupDetainedOrDead(commandList, true, true, true);
}
private void OnHeadRevMobStateChanged(EntityUid uid, HeadRevolutionaryComponent comp, MobStateChangedEvent ev)
// If no Head Revs are alive all normal Revs will lose their Rev status and rejoin Nanotrasen
// Cuffing Head Revs is not enough - they must be killed.
- if (IsGroupDetainedOrDead(headRevList, false, false))
+ if (IsGroupDetainedOrDead(headRevList, false, false, false))
{
var rev = AllEntityQuery<RevolutionaryComponent, MindContainerComponent>();
while (rev.MoveNext(out var uid, out _, out var mc))
/// <param name="list">The list of the entities</param>
/// <param name="checkOffStation">Bool for if you want to check if someone is in space and consider them missing in action. (Won't check when emergency shuttle arrives just in case)</param>
/// <param name="countCuffed">Bool for if you don't want to count cuffed entities.</param>
+ /// <param name="countRevolutionaries">Bool for if you want to count revolutionaries.</param>
/// <returns></returns>
- private bool IsGroupDetainedOrDead(List<EntityUid> list, bool checkOffStation, bool countCuffed)
+ private bool IsGroupDetainedOrDead(List<EntityUid> list, bool checkOffStation, bool countCuffed, bool countRevolutionaries)
{
var gone = 0;
+
foreach (var entity in list)
{
if (TryComp<CuffableComponent>(entity, out var cuffed) && cuffed.CuffedHandCount > 0 && countCuffed)
{
gone++;
+ continue;
}
- else
+
+ if (TryComp<MobStateComponent>(entity, out var state))
{
- if (TryComp<MobStateComponent>(entity, out var state))
+ if (state.CurrentState == MobState.Dead || state.CurrentState == MobState.Invalid)
{
- if (state.CurrentState == MobState.Dead || state.CurrentState == MobState.Invalid)
- {
- gone++;
- }
- else if (checkOffStation && _stationSystem.GetOwningStation(entity) == null && !_emergencyShuttle.EmergencyShuttleArrived)
- {
- gone++;
- }
+ gone++;
+ continue;
}
- //If they don't have the MobStateComponent they might as well be dead.
- else
+
+ if (checkOffStation && _stationSystem.GetOwningStation(entity) == null && !_emergencyShuttle.EmergencyShuttleArrived)
{
gone++;
+ continue;
}
}
+ //If they don't have the MobStateComponent they might as well be dead.
+ else
+ {
+ gone++;
+ continue;
+ }
+
+ if ((HasComp<RevolutionaryComponent>(entity) || HasComp<HeadRevolutionaryComponent>(entity)) && countRevolutionaries)
+ {
+ gone++;
+ continue;
+ }
}
return gone == list.Count || list.Count == 0;
using Content.Shared.Mindshield.Components;
using Content.Shared.Revolutionary.Components;
using Content.Shared.Tag;
+using Robust.Shared.Containers;
namespace Content.Server.Mindshield;
{
base.Initialize();
SubscribeLocalEvent<SubdermalImplantComponent, ImplantImplantedEvent>(ImplantCheck);
+ SubscribeLocalEvent<MindShieldImplantComponent, EntGotRemovedFromContainerMessage>(OnImplantDraw);
}
/// <summary>
_adminLogManager.Add(LogType.Mind, LogImpact.Medium, $"{ToPrettyString(implanted)} was deconverted due to being implanted with a Mindshield.");
}
}
+
+ private void OnImplantDraw(Entity<MindShieldImplantComponent> ent, ref EntGotRemovedFromContainerMessage args)
+ {
+ RemComp<MindShieldComponent>(args.Container.Owner);
+ }
}
+
--- /dev/null
+using Content.Shared.Revolutionary;
+using Robust.Shared.GameStates;
+
+namespace Content.Shared.Mindshield.Components;
+
+/// <summary>
+/// Component given to an entity to mark it is a mindshield implant.
+/// </summary>
+[RegisterComponent, NetworkedComponent, Access(typeof(SharedRevolutionarySystem))]
+public sealed partial class MindShieldImplantComponent : Component;
head-rev-role-greeting =
You are a Head Revolutionary.
- You are tasked with removing all of Command from station via death, exilement or imprisonment.
+ You are tasked with removing all of Command from station via conversion, death or imprisonment.
The Syndicate has sponsored you with a flash that converts the crew to your side.
- Beware, this won't work on Security, Command, or those wearing sunglasses.
+ Beware, this won't work on those with a mindshield or wearing eye protection.
Viva la revolución!
head-rev-briefing =
Use flashes to convert people to your cause.
- Get rid of all heads to take over the station.
+ Get rid of or convert all heads to take over the station.
head-rev-break-mindshield = The Mindshield was destroyed!
## Rev
roles-antag-rev-name = Revolutionary
-roles-antag-rev-objective = Your objective is to ensure the safety and follow the orders of the Head Revolutionaries as well as getting rid of all Command staff on station.
+roles-antag-rev-objective = Your objective is to ensure the safety and follow the orders of the Head Revolutionaries as well as getting rid or converting of all Command staff on station.
rev-break-control = {$name} has remembered their true allegiance!
rev-role-greeting =
You are a Revolutionary.
You are tasked with taking over the station and protecting the Head Revolutionaries.
- Get rid of all of the Command staff.
+ Get rid of all of or convert the Command staff.
Viva la revolución!
rev-briefing = Help your head revolutionaries get rid of every head to take over the station.
categories: [ HideSpawnMenu ]
components:
- type: SubdermalImplant
- permanent: true
+ - type: MindShieldImplant
- type: Tag
tags:
- MindShield
Revolutionaries are conversion antagonists sponsored by the [color=#ff0000]Syndicate[/color] who are tasked with taking control of the station. They have no fancy gimmicks or cheap tricks, they only have a cause and strength in numbers.
## Objectives
- You must cuff, kill, or exile all of the [textlink="Command staff" link="Command"] on station in no particular order.
+ You must convert, cuff or kill all of the [textlink="Command staff" link="Command"] on station in no particular order.
Your objective is [bold]not to destroy the station[/bold], but [italic]to take it over[/italic], so try to minimize damage where possible.
- [bold]Visibly be destroyed upon being implanted into a [color=#5e9cff]Head Revolutionary[/color][/bold], giving you away
- NOT protect against flash disorientation
- Assume all of [color=#cb0000]Security[/color] and [color=#1b67a5]Command[/color] are implanted with mindshields already.
+ Assume all of [color=#cb0000]Security[/color] and [color=#1b67a5]Command[/color] are implanted with mindshields already, [bold]however they can be removed using an empty implanter, obtainable from the Medical department's MedFab.[/bold]
<Box>
<GuideEntityEmbed Entity="MindShieldImplanter"/>