Forbid string literals for SharedActionsSystem methods (#38472)

Forbid string literals for SharedActionsSystem methods
This commit is contained in:
Tayrtahn
2025-06-20 18:11:12 -04:00
committed by GitHub
parent 5006214be5
commit c1de936c4b

View File

@@ -579,7 +579,7 @@ public abstract class SharedActionsSystem : EntitySystem
#region AddRemoveActions #region AddRemoveActions
public EntityUid? AddAction(EntityUid performer, public EntityUid? AddAction(EntityUid performer,
string? actionPrototypeId, [ForbidLiteral] string? actionPrototypeId,
EntityUid container = default, EntityUid container = default,
ActionsComponent? component = null) ActionsComponent? component = null)
{ {
@@ -599,7 +599,7 @@ public abstract class SharedActionsSystem : EntitySystem
/// <param name="container">The entity that contains/enables this action (e.g., flashlight).</param> /// <param name="container">The entity that contains/enables this action (e.g., flashlight).</param>
public bool AddAction(EntityUid performer, public bool AddAction(EntityUid performer,
[NotNullWhen(true)] ref EntityUid? actionId, [NotNullWhen(true)] ref EntityUid? actionId,
string? actionPrototypeId, [ForbidLiteral] string? actionPrototypeId,
EntityUid container = default, EntityUid container = default,
ActionsComponent? component = null) ActionsComponent? component = null)
{ {
@@ -610,7 +610,7 @@ public abstract class SharedActionsSystem : EntitySystem
public bool AddAction(EntityUid performer, public bool AddAction(EntityUid performer,
[NotNullWhen(true)] ref EntityUid? actionId, [NotNullWhen(true)] ref EntityUid? actionId,
[NotNullWhen(true)] out ActionComponent? action, [NotNullWhen(true)] out ActionComponent? action,
string? actionPrototypeId, [ForbidLiteral] string? actionPrototypeId,
EntityUid container = default, EntityUid container = default,
ActionsComponent? component = null) ActionsComponent? component = null)
{ {