using Content.Shared.Hands.Components; namespace Content.Server.NPC.HTN.Preconditions; /// /// Returns true if the active hand is unoccupied. /// public sealed partial class ActiveHandFreePrecondition : HTNPrecondition { [Dependency] private readonly IEntityManager _entManager = default!; public override bool IsMet(NPCBlackboard blackboard) { return blackboard.TryGetValue(NPCBlackboard.ActiveHandFree, out var handFree, _entManager) && handFree; } }