Remove many resolves on Content.Server

This commit is contained in:
Vera Aguilera Puerto
2021-12-08 17:04:21 +01:00
parent 420039f278
commit ba736f70df
72 changed files with 407 additions and 302 deletions

View File

@@ -19,8 +19,9 @@ namespace Content.Server.AI.Utility.Actions.Test
public override void SetupOperators(Blackboard context)
{
var currentPosition = IoCManager.Resolve<IEntityManager>().GetComponent<TransformComponent>(Owner).Coordinates;
var nextPosition = IoCManager.Resolve<IEntityManager>().GetComponent<TransformComponent>(Owner).Coordinates.Offset(new Vector2(10.0f, 0.0f));
var entMan = IoCManager.Resolve<IEntityManager>();
var currentPosition = entMan.GetComponent<TransformComponent>(Owner).Coordinates;
var nextPosition = entMan.GetComponent<TransformComponent>(Owner).Coordinates.Offset(new Vector2(10.0f, 0.0f));
var originalPosOp = new MoveToGridOperator(Owner, currentPosition, 0.25f);
var newPosOp = new MoveToGridOperator(Owner, nextPosition, 0.25f);