Action, Action Container, and Action Upgrade changes (#24005)

* Added TransferActionWithNewAttached and TransferAllActionsWithNewAttached and OnActionAdded event method to ActionContainerSystem. These are needed where the action needs to have a different attached entity for usage.  Fixed a bug with not being able to upgrade actions between levels.  Added a way to grant and remove a singular action.

* adds an action container component to mind on action added to fix tests

* Swaps trycomp for hascomp

* Maybe this will fix the thests

* Grants action container to performer as well

* Wait that makes no sense, removing that

* fixes mind action grant logic

* Changes ent check back to netent check

* Reverts unintended container changes
This commit is contained in:
keronshb
2024-01-15 01:37:38 -05:00
committed by GitHub
parent ff3fe2e79b
commit c8466055ef
5 changed files with 182 additions and 22 deletions

View File

@@ -51,7 +51,7 @@ internal sealed class UpgradeActionCommand : IConsoleCommand
if (args.Length == 1)
{
if (!actionUpgrade.TryUpgradeAction(uid, actionUpgradeComponent))
if (!actionUpgrade.TryUpgradeAction(uid, out _, actionUpgradeComponent))
{
shell.WriteLine(Loc.GetString("upgradeaction-command-cannot-level-up"));
return;
@@ -74,7 +74,7 @@ internal sealed class UpgradeActionCommand : IConsoleCommand
return;
}
if (!actionUpgrade.TryUpgradeAction(uid, actionUpgradeComponent, level))
if (!actionUpgrade.TryUpgradeAction(uid, out _, actionUpgradeComponent, level))
shell.WriteLine(Loc.GetString("upgradeaction-command-cannot-level-up"));
}
}