FIXED: Chemistry JSON dump tool and companion GitHub Action (#6222)
Co-authored-by: ShadowCommander <10494922+ShadowCommander@users.noreply.github.com> Co-authored-by: moonheart08 <moonheart08@users.noreply.github.com>
This commit is contained in:
@@ -1,4 +1,6 @@
|
||||
using System.Collections.Generic;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text.Json.Serialization;
|
||||
using Content.Shared.Administration.Logs;
|
||||
using Content.Shared.Chemistry.Components;
|
||||
using Content.Shared.Chemistry.Reagent;
|
||||
@@ -20,24 +22,29 @@ namespace Content.Shared.Chemistry.Reagent
|
||||
[MeansImplicitUse]
|
||||
public abstract class ReagentEffect
|
||||
{
|
||||
[JsonPropertyName("id")] private protected string _id => this.GetType().Name;
|
||||
/// <summary>
|
||||
/// The list of conditions required for the effect to activate. Not required.
|
||||
/// </summary>
|
||||
[JsonPropertyName("conditions")]
|
||||
[DataField("conditions")]
|
||||
public ReagentEffectCondition[]? Conditions;
|
||||
|
||||
/// <summary>
|
||||
/// What's the chance, from 0 to 1, that this effect will occur?
|
||||
/// </summary>
|
||||
[JsonPropertyName("probability")]
|
||||
[DataField("probability")]
|
||||
public float Probability = 1.0f;
|
||||
|
||||
[JsonIgnore]
|
||||
[DataField("logImpact")]
|
||||
public virtual LogImpact LogImpact { get; } = LogImpact.Low;
|
||||
|
||||
/// <summary>
|
||||
/// Should this reagent effect log at all?
|
||||
/// </summary>
|
||||
[JsonIgnore]
|
||||
[DataField("shouldLog")]
|
||||
public virtual bool ShouldLog { get; } = false;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user