21 lines
781 B
C#
21 lines
781 B
C#
using Unity.Entities;
|
|
using Unity.Mathematics;
|
|
|
|
namespace ProjectM.Simulation
|
|
{
|
|
/// <summary>
|
|
/// Singleton baked into the gameplay subscene, holding the baked storage-container ghost prefab and
|
|
/// the base-grid cell to spawn it at. A one-shot server system instantiates the prefab at
|
|
/// BaseGridMath.CellToWorld(anchor, Cell) and then destroys this singleton. Mirrors the
|
|
/// UpgradePickupSpawner / PlayerSpawner pattern.
|
|
/// </summary>
|
|
public struct StorageSpawner : IComponentData
|
|
{
|
|
/// <summary>Baked storage-container ghost prefab to instantiate.</summary>
|
|
public Entity Prefab;
|
|
|
|
/// <summary>Base-grid cell at which to place the container (cell center, on the base plane).</summary>
|
|
public int2 Cell;
|
|
}
|
|
}
|