Anomalies behaviours (#24683)
* Added new anomaly particle * Add basic anomaly behaviour * +2 parametres * add functional to new particle * add components to behaviours * big content * add shuffle, moved thing to server * clean up * fixes * random pick redo * bonjour behavioUr * fix AJCM * fix * add some new behaviours * power modifier behaviour * rmeove timer * new event for update ui fix * refactor! * fixes * enum * Fix mapinit * Minor touches --------- Co-authored-by: metalgearsloth <comedian_vs_clown@hotmail.com>
This commit is contained in:
@@ -13,58 +13,64 @@ public sealed partial class AnomalousParticleComponent : Component
|
||||
/// The type of particle that the projectile
|
||||
/// imbues onto the anomaly on contact.
|
||||
/// </summary>
|
||||
[DataField("particleType", required: true)]
|
||||
[DataField(required: true)]
|
||||
public AnomalousParticleType ParticleType;
|
||||
|
||||
/// <summary>
|
||||
/// The fixture that's checked on collision.
|
||||
/// </summary>
|
||||
[DataField("fixtureId")]
|
||||
[DataField]
|
||||
public string FixtureId = "projectile";
|
||||
|
||||
/// <summary>
|
||||
/// The amount that the <see cref="AnomalyComponent.Severity"/> increases by when hit
|
||||
/// of an anomalous particle of <seealso cref="AnomalyComponent.SeverityParticleType"/>.
|
||||
/// </summary>
|
||||
[DataField("severityPerSeverityHit")]
|
||||
[DataField]
|
||||
public float SeverityPerSeverityHit = 0.025f;
|
||||
|
||||
/// <summary>
|
||||
/// The amount that the <see cref="AnomalyComponent.Stability"/> increases by when hit
|
||||
/// of an anomalous particle of <seealso cref="AnomalyComponent.DestabilizingParticleType"/>.
|
||||
/// </summary>
|
||||
[DataField("stabilityPerDestabilizingHit")]
|
||||
[DataField]
|
||||
public float StabilityPerDestabilizingHit = 0.04f;
|
||||
|
||||
/// <summary>
|
||||
/// The amount that the <see cref="AnomalyComponent.Stability"/> increases by when hit
|
||||
/// of an anomalous particle of <seealso cref="AnomalyComponent.DestabilizingParticleType"/>.
|
||||
/// </summary>
|
||||
[DataField("healthPerWeakeningeHit")]
|
||||
[DataField]
|
||||
public float HealthPerWeakeningeHit = -0.05f;
|
||||
|
||||
/// <summary>
|
||||
/// The amount that the <see cref="AnomalyComponent.Stability"/> increases by when hit
|
||||
/// of an anomalous particle of <seealso cref="AnomalyComponent.DestabilizingParticleType"/>.
|
||||
/// </summary>
|
||||
[DataField("stabilityPerWeakeningeHit")]
|
||||
[DataField]
|
||||
public float StabilityPerWeakeningeHit = -0.1f;
|
||||
|
||||
/// <summary>
|
||||
/// If this is true then the particle will always affect the stability of the anomaly.
|
||||
/// </summary>
|
||||
[DataField("destabilzingOverride")]
|
||||
[DataField]
|
||||
public bool DestabilzingOverride = false;
|
||||
|
||||
/// <summary>
|
||||
/// If this is true then the particle will always affect the weakeness of the anomaly.
|
||||
/// </summary>
|
||||
[DataField("weakeningOverride")]
|
||||
[DataField]
|
||||
public bool WeakeningOverride = false;
|
||||
|
||||
/// <summary>
|
||||
/// If this is true then the particle will always affect the severity of the anomaly.
|
||||
/// </summary>
|
||||
[DataField("severityOverride")]
|
||||
[DataField]
|
||||
public bool SeverityOverride = false;
|
||||
|
||||
/// <summary>
|
||||
/// If this is true then the particle will always affect the behaviour.
|
||||
/// </summary>
|
||||
[DataField]
|
||||
public bool TransmutationOverride = false;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,45 @@
|
||||
using Content.Server.Anomaly.Effects;
|
||||
|
||||
namespace Content.Server.Anomaly.Components;
|
||||
|
||||
/// <summary>
|
||||
/// Hides some information about the anomaly when scanning it
|
||||
/// </summary>
|
||||
[RegisterComponent, Access(typeof(SecretDataAnomalySystem), typeof(AnomalySystem))]
|
||||
public sealed partial class SecretDataAnomalyComponent : Component
|
||||
{
|
||||
/// <summary>
|
||||
/// Minimum hidden data elements on MapInit
|
||||
/// </summary>
|
||||
[DataField]
|
||||
public int RandomStartSecretMin = 0;
|
||||
|
||||
/// <summary>
|
||||
/// Maximum hidden data elements on MapInit
|
||||
/// </summary>
|
||||
[DataField]
|
||||
public int RandomStartSecretMax = 0;
|
||||
|
||||
/// <summary>
|
||||
/// Current secret data
|
||||
/// </summary>
|
||||
[DataField]
|
||||
public List<AnomalySecretData> Secret = new();
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Enum with secret data field variants
|
||||
/// </summary>
|
||||
[Serializable]
|
||||
public enum AnomalySecretData : byte
|
||||
{
|
||||
Severity,
|
||||
Stability,
|
||||
OutputPoint,
|
||||
ParticleDanger,
|
||||
ParticleUnstable,
|
||||
ParticleContainment,
|
||||
ParticleTransformation,
|
||||
Behavior,
|
||||
Default
|
||||
}
|
||||
@@ -0,0 +1,28 @@
|
||||
using Content.Server.Anomaly.Effects;
|
||||
|
||||
namespace Content.Server.Anomaly.Components;
|
||||
|
||||
/// <summary>
|
||||
/// Shuffle Particle types in some situations
|
||||
/// </summary>
|
||||
[RegisterComponent, Access(typeof(ShuffleParticlesAnomalySystem))]
|
||||
public sealed partial class ShuffleParticlesAnomalyComponent : Component
|
||||
{
|
||||
/// <summary>
|
||||
/// Prob() chance to randomize particle types after Anomaly pulation
|
||||
/// </summary>
|
||||
[DataField]
|
||||
public bool ShuffleOnPulse = false;
|
||||
|
||||
/// <summary>
|
||||
/// Prob() chance to randomize particle types after APE or CHIMP projectile
|
||||
/// </summary>
|
||||
[DataField]
|
||||
public bool ShuffleOnParticleHit = false;
|
||||
|
||||
/// <summary>
|
||||
/// Chance to random particles
|
||||
/// </summary>
|
||||
[DataField]
|
||||
public float Prob = 0.5f;
|
||||
}
|
||||
Reference in New Issue
Block a user