From 09dbb24e7e807eec36dbe6d0a2dd2939f6d13bb3 Mon Sep 17 00:00:00 2001 From: Nemanja <98561806+EmoGarbage404@users.noreply.github.com> Date: Sun, 10 Dec 2023 18:11:45 -0500 Subject: [PATCH] Make items' default rotation orient them correctly (#22258) --- Content.Shared/Storage/EntitySystems/SharedStorageSystem.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Content.Shared/Storage/EntitySystems/SharedStorageSystem.cs b/Content.Shared/Storage/EntitySystems/SharedStorageSystem.cs index 0b93b9b762..3a92de1e73 100644 --- a/Content.Shared/Storage/EntitySystems/SharedStorageSystem.cs +++ b/Content.Shared/Storage/EntitySystems/SharedStorageSystem.cs @@ -819,7 +819,7 @@ public abstract class SharedStorageSystem : EntitySystem { for (var x = storageBounding.Left; x <= storageBounding.Right; x++) { - for (var angle = Angle.Zero; angle <= Angle.FromDegrees(360); angle += Math.PI / 2f) + for (var angle = Angle.FromDegrees(-itemEnt.Comp.StoredRotation); angle <= Angle.FromDegrees(360 - itemEnt.Comp.StoredRotation); angle += Math.PI / 2f) { var location = new ItemStorageLocation(angle, (x, y)); if (ItemFitsInGridLocation(itemEnt, storageEnt, location))