Validate remaining ProtoId strings (#38747)

Validate remaining ProtoId strings
This commit is contained in:
Tayrtahn
2025-07-04 16:55:45 -04:00
committed by GitHub
parent 3a278bca8b
commit f09bade8e7
14 changed files with 44 additions and 23 deletions

View File

@@ -21,6 +21,8 @@ namespace Content.Server.Cluwne;
public sealed class CluwneSystem : EntitySystem
{
private static readonly ProtoId<DamageGroupPrototype> GeneticDamageGroup = "Genetic";
[Dependency] private readonly PopupSystem _popupSystem = default!;
[Dependency] private readonly SharedAudioSystem _audio = default!;
[Dependency] private readonly IRobustRandom _robustRandom = default!;
@@ -53,7 +55,7 @@ public sealed class CluwneSystem : EntitySystem
RemComp<CluwneComponent>(uid);
RemComp<ClumsyComponent>(uid);
RemComp<AutoEmoteComponent>(uid);
var damageSpec = new DamageSpecifier(_prototypeManager.Index<DamageGroupPrototype>("Genetic"), 300);
var damageSpec = new DamageSpecifier(_prototypeManager.Index(GeneticDamageGroup), 300);
_damageableSystem.TryChangeDamage(uid, damageSpec);
}
}