Optimise storage a quadrillion times (#37638)

* Optimise storage a quadrillion times

* How sweaty can we get

* Add fast angle checks

* Fix chunk indices

* Optimise the refresh method

Helps on client a lot as the clientside is suboptimal atm.

* Better name

* wawawewa

* Add single-angle path

* Okay FINE rider
This commit is contained in:
metalgearsloth
2025-05-21 16:16:26 +10:00
committed by GitHub
parent e100324815
commit a393033c64
4 changed files with 323 additions and 54 deletions

View File

@@ -19,6 +19,14 @@ namespace Content.Shared.Storage
{
public static string ContainerId = "storagebase";
public const byte ChunkSize = 8;
// No datafield because we can just derive it from stored items.
/// <summary>
/// Bitmask of occupied tiles
/// </summary>
public Dictionary<Vector2i, ulong> OccupiedGrid = new();
[ViewVariables]
public Container Container = default!;