Add ghost role raffles (#26629)

* Add ghost role raffles

* GRR: Fix dialogue sizing, fix merge

* GRR: Add raffle deciders (winner picker)

* GRR: Make settings prototype based with option to override

* GRR: Use Raffles folder and namespace

* GRR: DataFieldify and TimeSpanify

* GRR: Don't actually DataFieldify HashSet<ICommonSession>s

* GRR: add GetGhostRoleCount() + docs

* update engine on branch

* Ghost role raffles: docs, fix window size, cleanup, etc

* GRR: Admin UI

* GRR: Admin UI: Display initial/max/ext of selected raffle settings proto

* GRR: Make a ton of roles raffled
This commit is contained in:
no
2024-05-07 03:48:16 +02:00
committed by GitHub
parent 6685146a1e
commit 630a7a78ed
44 changed files with 1138 additions and 51 deletions

View File

@@ -1,4 +1,5 @@
using Content.Server.Mind.Commands;
using Content.Server.Ghost.Roles.Raffles;
using Content.Server.Mind.Commands;
using Content.Shared.Roles;
namespace Content.Server.Ghost.Roles.Components
@@ -87,5 +88,12 @@ namespace Content.Server.Ghost.Roles.Components
[ViewVariables(VVAccess.ReadWrite)]
[DataField("reregister")]
public bool ReregisterOnGhost { get; set; } = true;
/// <summary>
/// If set, ghost role is raffled, otherwise it is first-come-first-serve.
/// </summary>
[DataField("raffle")]
[Access(typeof(GhostRoleSystem), Other = AccessPermissions.ReadWriteExecute)] // FIXME Friends
public GhostRoleRaffleConfig? RaffleConfig { get; set; }
}
}