Files
OldThink/Content.Server/_White/Cult/Items/Systems/BloodBoilProjectileSystem.cs
Aviu00 af99df5ae0 Cult stuff (#348)
* - add: Cult buff protects against spacing.

* - add: Predict RunicDoor.

* - add: Loc.

* - fix: Missing includes.

* - add: Revive rune popups.

* - tweak: Buff rune.

* - fix: Buff rune.
2024-06-12 19:00:45 +03:00

28 lines
1008 B
C#

using Content.Server._White.Cult.Items.Components;
using Content.Server._White.Cult.TimedProduction;
using Content.Shared._White.Cult.Components;
using Content.Shared._White.Cult.Pylon;
using Robust.Shared.Physics.Events;
using CultistComponent = Content.Shared._White.Cult.Components.CultistComponent;
namespace Content.Server._White.Cult.Items.Systems;
public sealed class BloodBoilProjectileSystem : EntitySystem
{
public override void Initialize()
{
base.Initialize();
SubscribeLocalEvent<BloodBoilProjectileComponent, PreventCollideEvent>(PreventCollision);
}
private void PreventCollision(EntityUid uid, BloodBoilProjectileComponent component, ref PreventCollideEvent args)
{
if (HasComp<CultistComponent>(args.OtherEntity) || HasComp<ConstructComponent>(args.OtherEntity) ||
HasComp<CultistFactoryComponent>(args.OtherEntity) || HasComp<SharedPylonComponent>(args.OtherEntity))
{
args.Cancelled = true;
}
}
}