add SpawnTableOnUse (#32620)

* add SpawnTableOnUse

* make BaseEmitSound more flexible and remove sound from spawntable

* add log

* :trollface:

---------

Co-authored-by: deltanedas <@deltanedas:kde.org>
This commit is contained in:
deltanedas
2024-12-16 12:23:14 +00:00
committed by GitHub
parent cd23805750
commit 2635888b6a
4 changed files with 78 additions and 5 deletions

View File

@@ -0,0 +1,17 @@
using Content.Server.Storage.EntitySystems;
using Content.Shared.EntityTable.EntitySelectors;
namespace Content.Server.Storage.Components;
/// <summary>
/// Spawns items from an entity table when used in hand.
/// </summary>
[RegisterComponent, Access(typeof(SpawnTableOnUseSystem))]
public sealed partial class SpawnTableOnUseComponent : Component
{
/// <summary>
/// The entity table to select entities from.
/// </summary>
[DataField(required: true)]
public EntityTableSelector Table = default!;
}