Cherry Pick Round-start Solar Variation (#36825)

* Roundstart Variation for Solar Panels (#86)

* Added roundstart variation for solar panels

* Removed HV cable spawner since i don't want to bother with mapping them

* Solar Panel Variation Pass Fix (#96)

Added a second variation pass for regular solar assemblies, since otherwise they would spawn both it and the broken variety

* Reorganized everything to no longer be in the _Moffstation subdirectory

* Removed a forgotten tag for Moffstation

* Removed the moffstation namespace settings

* Update Content.Server/GameTicking/Rules/VariationPass/Components/SolarPanelReplaceVariationPassComponent.cs

Co-authored-by: Tayrtahn <tayrtahn@gmail.com>

* Update Content.Server/GameTicking/Rules/VariationPass/Components/ReplacementMarkers/SolarPanelReplacementMarkerComponent.cs

Co-authored-by: Tayrtahn <tayrtahn@gmail.com>

---------

Co-authored-by: Tayrtahn <tayrtahn@gmail.com>
This commit is contained in:
Southbridge
2025-04-22 15:46:38 -04:00
committed by GitHub
parent bd1f2af691
commit 1e794a30d0
6 changed files with 48 additions and 0 deletions

View File

@@ -0,0 +1,7 @@
namespace Content.Server.GameTicking.Rules.VariationPass.Components.ReplacementMarkers;
/// <summary>
/// This component marks replaceable solar panels for use with fast queries in variation passes.
/// </summary>
[RegisterComponent]
public sealed partial class SolarPanelReplacementMarkerComponent : Component;

View File

@@ -0,0 +1,5 @@
namespace Content.Server.GameTicking.Rules.VariationPass.Components;
[RegisterComponent]
public sealed partial class SolarPanelReplaceVariationPassComponent : Component;

View File

@@ -0,0 +1,11 @@
using Content.Server.GameTicking.Rules.VariationPass.Components;
using Content.Server.GameTicking.Rules.VariationPass.Components.ReplacementMarkers;
namespace Content.Server.GameTicking.Rules.VariationPass;
/// <summary>
/// This handles the ability to replace entities marked with <see cref="SolarPanelReplacementMarkerComponent"/> in a variation pass
/// </summary>
public sealed class SolarPanelReplaceVariationPassSystem : BaseEntityReplaceVariationPassSystem<SolarPanelReplacementMarkerComponent, SolarPanelReplaceVariationPassComponent>
{
}

View File

@@ -151,6 +151,7 @@
- type: Construction
graph: SolarPanel
node: solarpanel
- type: SolarPanelReplacementMarker
- type: entity
id: SolarPanelBroken

View File

@@ -447,3 +447,5 @@
orGroup: puddleMess
- id: SmugglerStashVariationPass
prob: 0.90
- id: SolarPanelDamageVariationPass
- id: SolarPanelEmptyVariationPass

View File

@@ -123,3 +123,25 @@
blacklist:
components:
- ParticleAcceleratorControlBox
- type: entity
id: SolarPanelDamageVariationPass
parent: BaseVariationPass
components:
- type: SolarPanelReplaceVariationPass
- type: EntityReplaceVariationPass
entitiesPerReplacementAverage: 30
entitiesPerReplacementStdDev: 5
replacements:
- id: SolarPanelBroken
- type: entity
id: SolarPanelEmptyVariationPass
parent: BaseVariationPass
components:
- type: SolarPanelReplaceVariationPass
- type: EntityReplaceVariationPass
entitiesPerReplacementAverage: 30
entitiesPerReplacementStdDev: 5
replacements:
- id: SolarAssembly