Inline Transform
This commit is contained in:
@@ -280,7 +280,7 @@ namespace Content.Server.Inventory.Components
|
||||
}
|
||||
|
||||
// TODO: The item should be dropped to the container our owner is in, if any.
|
||||
entity.Transform.AttachParentToContainerOrGrid();
|
||||
IoCManager.Resolve<IEntityManager>().GetComponent<TransformComponent>(entity.Uid).AttachParentToContainerOrGrid();
|
||||
|
||||
_entitySystemManager.GetEntitySystem<InteractionSystem>().UnequippedInteraction(Owner, entity, slot);
|
||||
|
||||
@@ -310,7 +310,7 @@ namespace Content.Server.Inventory.Components
|
||||
var item = IoCManager.Resolve<IEntityManager>().GetComponent<ItemComponent>(entity.Uid);
|
||||
inventorySlot.ForceRemove(entity);
|
||||
|
||||
var itemTransform = entity.Transform;
|
||||
var itemTransform = IoCManager.Resolve<IEntityManager>().GetComponent<TransformComponent>(entity.Uid);
|
||||
|
||||
itemTransform.AttachParentToContainerOrGrid();
|
||||
|
||||
|
||||
@@ -28,7 +28,7 @@ namespace Content.Server.Inventory
|
||||
return false;
|
||||
|
||||
// Let's spawn this first...
|
||||
var item = entityManager.SpawnEntity(prototype, user.Transform.MapPosition);
|
||||
var item = entityManager.SpawnEntity(prototype, IoCManager.Resolve<IEntityManager>().GetComponent<TransformComponent>(user.Uid).MapPosition);
|
||||
|
||||
// Helper method that deletes the item and returns false.
|
||||
bool DeleteItem()
|
||||
|
||||
Reference in New Issue
Block a user