Files
tbd-station-14/Content.Server/StationEvents/Components/RampingStationEventSchedulerComponent.cs
IProduceWidgets 07ec00ed05 refactor event schedulers to use explicit game rules (#29320)
* works, still has testing values, im sure I did stupid shit.

* shitvent crapfactor

* snap extra word out of existence

* shit I died of old

* remove useless inaccurate design comments

* Oopsie, handle requirement params in RandomRuleSystem too

* I'm a slash slinging hasher

* Address reviews, add admin alerts I forgor

* EntityMan saves the day

* address reviews 1

* eh, I actually don't care about the cargo gifts thing.

* started

* Do reviews

* you actually meant 1.2 lmao

* dependency inheritance is a fickle bitch

* I have no idea.

* Threads are for sheets not computers.

* fix traitor rule test

* fix round type tattling

* break things

* It worky

* Toolshed makes we want to drink depresso.

* Finished?

* remove debug values

* timings

* use defaults

* alphabetize

* bobby drop tables

* Float required fr fr

* continue

* more continence

* uno mas

* obsolution

* cleanup and documentations

* Yell at self

* use the right value defaults

* housekeeping
2024-08-14 15:21:01 +10:00

42 lines
1.5 KiB
C#

using Content.Shared.EntityTable.EntitySelectors;
namespace Content.Server.StationEvents.Components;
[RegisterComponent, Access(typeof(RampingStationEventSchedulerSystem))]
public sealed partial class RampingStationEventSchedulerComponent : Component
{
/// <summary>
/// Average ending chaos modifier for the ramping event scheduler. Higher means faster.
/// Max chaos chosen for a round will deviate from this
/// </summary>
[DataField]
public float AverageChaos = 6f;
/// <summary>
/// Average time (in minutes) for when the ramping event scheduler should stop increasing the chaos modifier.
/// Close to how long you expect a round to last, so you'll probably have to tweak this on downstreams.
/// </summary>
[DataField]
public float AverageEndTime = 40f;
[DataField]
public float EndTime;
[DataField]
public float MaxChaos;
[DataField]
public float StartingChaos;
[DataField]
public float TimeUntilNextEvent;
/// <summary>
/// The gamerules that the scheduler can choose from
/// </summary>
/// Reminder that though we could do all selection via the EntityTableSelector, we also need to consider various <see cref="StationEventComponent"/> restrictions.
/// As such, we want to pass a list of acceptable game rules, which are then parsed for restrictions by the <see cref="EventManagerSystem"/>.
[DataField(required: true)]
public EntityTableSelector ScheduledGameRules = default!;
}