Various sharedsystem spring cleaning (#36200)
* Various shared system warnings cleanup * More shared system warnings cleanup * Rearranging changes * Using correct transform for unbuckle * Small changes * Revert buckle change * Update Content.Shared/Ghost/SharedGhostSystem.cs --------- Co-authored-by: slarticodefast <161409025+slarticodefast@users.noreply.github.com>
This commit is contained in:
@@ -38,6 +38,7 @@ public abstract class SharedHumanoidAppearanceSystem : EntitySystem
|
||||
[Dependency] private readonly IPrototypeManager _proto = default!;
|
||||
[Dependency] private readonly ISerializationManager _serManager = default!;
|
||||
[Dependency] private readonly MarkingManager _markingManager = default!;
|
||||
[Dependency] private readonly GrammarSystem _grammarSystem = default!;
|
||||
|
||||
[ValidatePrototypeId<SpeciesPrototype>]
|
||||
public const string DefaultSpecies = "Human";
|
||||
@@ -156,8 +157,9 @@ public abstract class SharedHumanoidAppearanceSystem : EntitySystem
|
||||
targetHumanoid.MarkingSet = new(sourceHumanoid.MarkingSet);
|
||||
|
||||
targetHumanoid.Gender = sourceHumanoid.Gender;
|
||||
|
||||
if (TryComp<GrammarComponent>(target, out var grammar))
|
||||
grammar.Gender = sourceHumanoid.Gender;
|
||||
_grammarSystem.SetGender((target, grammar), sourceHumanoid.Gender);
|
||||
|
||||
Dirty(target, targetHumanoid);
|
||||
}
|
||||
@@ -438,7 +440,7 @@ public abstract class SharedHumanoidAppearanceSystem : EntitySystem
|
||||
humanoid.Gender = profile.Gender;
|
||||
if (TryComp<GrammarComponent>(uid, out var grammar))
|
||||
{
|
||||
grammar.Gender = profile.Gender;
|
||||
_grammarSystem.SetGender((uid, grammar), profile.Gender);
|
||||
}
|
||||
|
||||
humanoid.Age = profile.Age;
|
||||
|
||||
Reference in New Issue
Block a user