Prevent AI from dropping something that's not in their hands
This commit is contained in:
@@ -21,7 +21,7 @@ namespace Content.Server.AI.Operators.Inventory
|
|||||||
/// <returns></returns>
|
/// <returns></returns>
|
||||||
public override Outcome Execute(float frameTime)
|
public override Outcome Execute(float frameTime)
|
||||||
{
|
{
|
||||||
if (!_owner.TryGetComponent(out HandsComponent handsComponent))
|
if (!_owner.TryGetComponent(out HandsComponent handsComponent) || handsComponent.FindHand(_entity) == null)
|
||||||
{
|
{
|
||||||
return Outcome.Failed;
|
return Outcome.Failed;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user