Files
tbd-station-14/Content.Shared/EntityConditions/Conditions/Body/InternalsEntityConditionSystem.cs
Princess Cheeseballs d4a32ce502 Mild Entity Effect/Condition Cleanup (#41059)
* Commit

* ploop

* borger

---------

Co-authored-by: Princess Cheeseballs <66055347+Pronana@users.noreply.github.com>
2025-10-23 23:35:59 +00:00

24 lines
963 B
C#

using Content.Shared.Body.Components;
using Robust.Shared.Prototypes;
namespace Content.Shared.EntityConditions.Conditions.Body;
/// <summary>
/// Returns true if this entity is using internals. False if they are not or cannot use internals.
/// </summary>
/// <inheritdoc cref="EntityConditionSystem{T, TCondition}"/>
public sealed partial class InternalsOnEntityConditionSystem : EntityConditionSystem<InternalsComponent, InternalsCondition>
{
protected override void Condition(Entity<InternalsComponent> entity, ref EntityConditionEvent<InternalsCondition> args)
{
args.Result = entity.Comp.GasTankEntity != null;
}
}
/// <inheritdoc cref="EntityCondition"/>
public sealed partial class InternalsCondition : EntityConditionBase<InternalsCondition>
{
public override string EntityConditionGuidebookText(IPrototypeManager prototype) =>
Loc.GetString("entity-condition-guidebook-internals", ("usingInternals", !Inverted));
}