mirror of
https://github.com/space-syndicate/space-station-14.git
synced 2026-10-17 14:21:13 +03:00
* Make every EntitySystem partial * Oobs thats for a diff PR * Also oops on that one * Test systems * git are we fr * Update file templates * cleanup empty classes while we are here * forgor --------- Co-authored-by: AJCM-git <ajcm_mail@disroot.org>
19 lines
685 B
C#
19 lines
685 B
C#
using Content.Server.GameTicking.Rules.Components;
|
|
using Content.Server.StationEvents.Components;
|
|
using Content.Shared.GameTicking.Components;
|
|
|
|
namespace Content.Server.StationEvents.Events;
|
|
|
|
public sealed partial class RandomSpawnRule : StationEventSystem<RandomSpawnRuleComponent>
|
|
{
|
|
protected override void Started(EntityUid uid, RandomSpawnRuleComponent comp, GameRuleComponent gameRule, GameRuleStartedEvent args)
|
|
{
|
|
base.Started(uid, comp, gameRule, args);
|
|
|
|
if (TryFindRandomTile(out _, out _, out _, out var coords))
|
|
{
|
|
Sawmill.Info($"Spawning {comp.Prototype} at {coords}");
|
|
Spawn(comp.Prototype, coords);
|
|
}
|
|
}
|
|
}
|