Namespace WitShells.DesignPatterns
Namespaces
Classes
- Draggable
Generic draggable component that works for UI (RectTransform) and world objects. Attach to any GameObject. For UI make sure Canvas has a GraphicRaycaster. For world objects use a PhysicsRaycaster on the camera and a collider on the object.
- Packet
A lightweight data transfer container used to send structured messages between systems (e.g. over WebSocket, local IPC, or within the same process).
- PacketCompressionUtils
Utility class providing GZip compression and decompression helpers for Packet payloads. Use these methods to reduce the wire size of large JSON payloads before sending.
- SpiralLayoutContainer
A MonoBehaviour that procedurally arranges ISpiralNode GameObjects in a spiral pattern using an ObjectPool<T> for efficient instantiation and reuse.
- SpiralNode<T>
Abstract MonoBehaviour implementation of ISpiralNode that carries typed data payload
T. Subclass this to create spiral nodes that display game-specific content (e.g. inventory items, skill icons, quest entries).
- WitLogger
A thin wrapper around Unity's Debug logging API that supports a global enable/disable toggle via EnableLogging. Use this instead of
Debug.Logdirectly so that all logging can be silenced in production builds from a single flag.
Interfaces
- ISpiralNode
Contract for a node in a doubly-linked spiral layout list. Each node knows its neighbours, its index in the spiral, and its 2D grid coordinate.
Enums
- SpiralDirection
Direction of spiral growth when generating a SpiralLayoutContainer layout.