diff --git a/Content.Shared/SS220/CultYogg/Corruption/CultYoggCorruptedPrototype.cs b/Content.Shared/SS220/CultYogg/Corruption/CultYoggCorruptedPrototype.cs
index 04c00858676d..44626052f776 100644
--- a/Content.Shared/SS220/CultYogg/Corruption/CultYoggCorruptedPrototype.cs
+++ b/Content.Shared/SS220/CultYogg/Corruption/CultYoggCorruptedPrototype.cs
@@ -43,6 +43,12 @@ public sealed partial class CultYoggCorruptedPrototype : IPrototype
[DataField("emptyStorage", required: false)]
public bool EmptyStorage { get; private set; }
+ ///
+ /// At what stage is this corruption result available
+ ///
+ [DataField("avaliableOnStage", required: false)]
+ public int AvaliableOnStage = 0;
+
}
[DataDefinition]
diff --git a/Content.Shared/SS220/CultYogg/Corruption/SharedCultYoggCorruptedSystem.cs b/Content.Shared/SS220/CultYogg/Corruption/SharedCultYoggCorruptedSystem.cs
index 78ded45a18c3..692aa1e894bc 100644
--- a/Content.Shared/SS220/CultYogg/Corruption/SharedCultYoggCorruptedSystem.cs
+++ b/Content.Shared/SS220/CultYogg/Corruption/SharedCultYoggCorruptedSystem.cs
@@ -14,6 +14,8 @@
using Robust.Shared.Random;
using Robust.Shared.Serialization;
using System.Diagnostics.CodeAnalysis;
+using Robust.Shared.GameObjects;
+using Content.Shared.Popups;
namespace Content.Shared.SS220.CultYogg.Corruption;
@@ -33,6 +35,7 @@ public sealed class SharedCultYoggCorruptedSystem : EntitySystem
[Dependency] private readonly SharedTransformSystem _transformSystem = default!;
[Dependency] private readonly IRobustRandom _random = default!;
[Dependency] private readonly SharedSoftDeleteSystem _softDeleteSystem = default!;
+ [Dependency] private readonly SharedPopupSystem _popup = default!;
private readonly TimeSpan _corruptionDuration = TimeSpan.FromSeconds(1.8);
private readonly Dictionary, CultYoggCorruptedPrototype> _recipesBySourcePrototypeId = [];
@@ -138,10 +141,16 @@ public bool IsCorrupted(EntityUid entity)
/// Flag indicating that the target entity is in hand
/// Optional callback to fire when finished
/// if corruption process has been started, otherwise
- public bool TryCorruptContinuously(EntityUid user, EntityUid entity, bool isInHand, Action? callback = null)
+ public bool TryCorruptContinuously(EntityUid user, CultYoggComponent comp, EntityUid entity, bool isInHand, Action? callback = null)
{
if (!TryGetCorruptionRecipe(entity, out var recipe))
{
+ _popup.PopupClient(Loc.GetString("cult-yogg-corrupt-no-proto"), entity, user);
+ return false;
+ }
+ if (comp.CurrentStage < recipe.AvaliableOnStage)
+ {
+ _popup.PopupClient(Loc.GetString("cult-yogg-corrupt-too-low-tier"), entity, user);
return false;
}
var e = new CultYoggCorruptDoAfterEvent(recipe, isInHand, callback);
diff --git a/Content.Shared/SS220/CultYogg/Cultists/SharedCultYoggSystem.cs b/Content.Shared/SS220/CultYogg/Cultists/SharedCultYoggSystem.cs
index 2f3ebbf1fdbd..97b706f42973 100644
--- a/Content.Shared/SS220/CultYogg/Cultists/SharedCultYoggSystem.cs
+++ b/Content.Shared/SS220/CultYogg/Cultists/SharedCultYoggSystem.cs
@@ -89,9 +89,8 @@ private void CorruptItemAction(Entity uid, ref CultYoggCorrup
return;
}
- if (!_cultYoggCorruptedSystem.TryCorruptContinuously(uid, args.Target, false))
+ if (!_cultYoggCorruptedSystem.TryCorruptContinuously(uid, uid.Comp, args.Target, false))
{
- _popup.PopupClient(Loc.GetString("cult-yogg-corrupt-no-proto"), args.Target, uid);
return;
}
args.Handled = true;
@@ -120,9 +119,8 @@ private void CorruptItemInHandAction(Entity uid, ref CultYogg
return;
}
- if (!_cultYoggCorruptedSystem.TryCorruptContinuously(uid, handItem.Value, true))
+ if (!_cultYoggCorruptedSystem.TryCorruptContinuously(uid, uid.Comp, handItem.Value, true))
{
- _popup.PopupClient(Loc.GetString("cult-yogg-corrupt-no-proto"), handItem.Value, uid);
return;
}
args.Handled = true;
diff --git a/Resources/Locale/ru-RU/ss220/cultYogg/cult_yogg_popups.ftl b/Resources/Locale/ru-RU/ss220/cultYogg/cult_yogg_popups.ftl
index 7c59c9d2743c..cadcd4fc4c87 100644
--- a/Resources/Locale/ru-RU/ss220/cultYogg/cult_yogg_popups.ftl
+++ b/Resources/Locale/ru-RU/ss220/cultYogg/cult_yogg_popups.ftl
@@ -1,5 +1,6 @@
cult-yogg-corrupt-no-proto = Предмет не имеет истинной формы
cult-yogg-corrupt-already-corrupted = Предмет уже обрел истинную форму
+cult-yogg-corrupt-too-low-tier = Искажения будет доступно при большем числе принесенных жертв
cult-yogg-no-mind = Оболочка не имеет разума
cult-yogg-enslave-verb = [italic]Поработить[/italic]
diff --git a/Resources/Prototypes/SS220/Entities/Objects/CultYogg/corruption.yml b/Resources/Prototypes/SS220/Entities/Objects/CultYogg/corruption.yml
index 99e2b4acc573..ef11a5a673f7 100644
--- a/Resources/Prototypes/SS220/Entities/Objects/CultYogg/corruption.yml
+++ b/Resources/Prototypes/SS220/Entities/Objects/CultYogg/corruption.yml
@@ -271,6 +271,7 @@
parentPrototypeId: ClothingOuterHardsuitBase
result: ClothingOuterHardsuitCultYogg
corruptionReverseEffect: ExorcismUncorruptEffect
+ avaliableOnStage: 2
# Hardsuit end
# Backpack beginning
diff --git a/Resources/Prototypes/SS220/GameRules/roundstart.yml b/Resources/Prototypes/SS220/GameRules/roundstart.yml
index 62226725545b..0200b9e0af5f 100644
--- a/Resources/Prototypes/SS220/GameRules/roundstart.yml
+++ b/Resources/Prototypes/SS220/GameRules/roundstart.yml
@@ -7,8 +7,8 @@
- type: GameRule
minPlayers: 40
delay:
- min: 300
- max: 600
+ min: 5
+ max: 10
- type: CultYoggRule
- type: AntagSelection
definitions: