mirror of
https://github.com/DeltaV-Station/Delta-v.git
synced 2026-09-30 16:17:27 +00:00
* move to shared * entity effect to shared * refactor: whitespaces+xml-doc typo fixups * refactor: a little bit more of xml-doc typos fixups Removed Incompatible RMC Emotes stuff. --------- Co-authored-by: pa.pecherskij <pa.pecherskij@interfax.ru>
29 lines
789 B
C#
29 lines
789 B
C#
using Robust.Shared.GameStates;
|
|
using Content.Shared.Chat;
|
|
using Content.Shared.Chat.Prototypes;
|
|
using Content.Shared.Emoting;
|
|
using Robust.Shared.Prototypes;
|
|
|
|
namespace Content.Server.Emoting;
|
|
|
|
public sealed partial class AnimatedEmotesSystem : SharedAnimatedEmotesSystem
|
|
{
|
|
public override void Initialize()
|
|
{
|
|
base.Initialize();
|
|
|
|
SubscribeLocalEvent<AnimatedEmotesComponent, EmoteEvent>(OnEmote);
|
|
}
|
|
|
|
private void OnEmote(EntityUid uid, AnimatedEmotesComponent component, ref EmoteEvent args)
|
|
{
|
|
PlayEmoteAnimation(uid, component, args.Emote.ID);
|
|
}
|
|
|
|
public void PlayEmoteAnimation(EntityUid uid, AnimatedEmotesComponent component, ProtoId<EmotePrototype> prot)
|
|
{
|
|
component.Emote = prot;
|
|
Dirty(uid, component);
|
|
}
|
|
}
|