fix clone appearance (#37130)
This commit is contained in:
@@ -72,7 +72,7 @@ public sealed class IdentitySystem : SharedIdentitySystem
|
|||||||
/// <summary>
|
/// <summary>
|
||||||
/// Queues an identity update to the start of the next tick.
|
/// Queues an identity update to the start of the next tick.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public void QueueIdentityUpdate(EntityUid uid)
|
public override void QueueIdentityUpdate(EntityUid uid)
|
||||||
{
|
{
|
||||||
_queuedIdentityUpdates.Add(uid);
|
_queuedIdentityUpdates.Add(uid);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -39,6 +39,7 @@ public abstract class SharedHumanoidAppearanceSystem : EntitySystem
|
|||||||
[Dependency] private readonly ISerializationManager _serManager = default!;
|
[Dependency] private readonly ISerializationManager _serManager = default!;
|
||||||
[Dependency] private readonly MarkingManager _markingManager = default!;
|
[Dependency] private readonly MarkingManager _markingManager = default!;
|
||||||
[Dependency] private readonly GrammarSystem _grammarSystem = default!;
|
[Dependency] private readonly GrammarSystem _grammarSystem = default!;
|
||||||
|
[Dependency] private readonly SharedIdentitySystem _identity = default!;
|
||||||
|
|
||||||
[ValidatePrototypeId<SpeciesPrototype>]
|
[ValidatePrototypeId<SpeciesPrototype>]
|
||||||
public const string DefaultSpecies = "Human";
|
public const string DefaultSpecies = "Human";
|
||||||
@@ -161,6 +162,7 @@ public abstract class SharedHumanoidAppearanceSystem : EntitySystem
|
|||||||
if (TryComp<GrammarComponent>(target, out var grammar))
|
if (TryComp<GrammarComponent>(target, out var grammar))
|
||||||
_grammarSystem.SetGender((target, grammar), sourceHumanoid.Gender);
|
_grammarSystem.SetGender((target, grammar), sourceHumanoid.Gender);
|
||||||
|
|
||||||
|
_identity.QueueIdentityUpdate(target);
|
||||||
Dirty(target, targetHumanoid);
|
Dirty(target, targetHumanoid);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -39,6 +39,11 @@ public abstract class SharedIdentitySystem : EntitySystem
|
|||||||
{
|
{
|
||||||
ent.Comp.Enabled = !args.Mask.Comp.IsToggled;
|
ent.Comp.Enabled = !args.Mask.Comp.IsToggled;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// Queues an identity update to the start of the next tick.
|
||||||
|
/// </summary>
|
||||||
|
public virtual void QueueIdentityUpdate(EntityUid uid) { }
|
||||||
}
|
}
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Gets called whenever an entity changes their identity.
|
/// Gets called whenever an entity changes their identity.
|
||||||
|
|||||||
Reference in New Issue
Block a user