fish-station/Content.Shared/Changeling/AbsorbedSystem.cs
Vigers Ray bcb9508552
Говнокрад (#268)
* real?

* ok

* real 2

* one more thing that i forgot to port part 2

* i am dumb

* mofo og

* waaaagh

* some rework placeholders

* porting part 2

* bruh.

* bruh 2

* bruh 3.

* Update ChangelingRuleSystem.cs

* Update AdminVerbSystem.Antags.cs

* говнокрад это SubGamemode

* тяжело...

* пу-пу-пу

---------

Co-authored-by: whateverusername0 <whateveremail>
Co-authored-by: username <113782077+whateverusername0@users.noreply.github.com>
2024-08-08 09:28:44 +03:00

27 lines
822 B
C#

using Content.Shared.Examine;
using Content.Shared.Mobs;
namespace Content.Shared.Changeling;
public sealed partial class AbsorbedSystem : EntitySystem
{
public override void Initialize()
{
base.Initialize();
SubscribeLocalEvent<AbsorbedComponent, ExaminedEvent>(OnExamine);
SubscribeLocalEvent<AbsorbedComponent, MobStateChangedEvent>(OnMobStateChange);
}
private void OnExamine(Entity<AbsorbedComponent> ent, ref ExaminedEvent args)
{
args.PushMarkup(Loc.GetString("changeling-absorb-onexamine"));
}
private void OnMobStateChange(Entity<AbsorbedComponent> ent, ref MobStateChangedEvent args)
{
// in case one somehow manages to dehusk someone
if (args.NewMobState != MobState.Dead)
RemComp<AbsorbedComponent>(ent);
}
}