mirror of
https://github.com/DeltaV-Station/Delta-v.git
synced 2026-09-29 23:57:29 +00:00
fix: glimmer probers now explode when unanchored due to grid change (#2606)
tweak: glimmer probers now explode when unanchored due to grid change
This commit is contained in:
@@ -65,6 +65,7 @@ namespace Content.Server.Psionics.Glimmer
|
||||
SubscribeLocalEvent<SharedGlimmerReactiveComponent, DamageChangedEvent>(OnDamageChanged);
|
||||
SubscribeLocalEvent<SharedGlimmerReactiveComponent, DestructionEventArgs>(OnDestroyed);
|
||||
SubscribeLocalEvent<SharedGlimmerReactiveComponent, UnanchorAttemptEvent>(OnUnanchorAttempt);
|
||||
SubscribeLocalEvent<SharedGlimmerReactiveComponent, AnchorStateChangedEvent>(OnAnchorStateChanged);
|
||||
SubscribeLocalEvent<SharedGlimmerReactiveComponent, AttemptMeleeThrowOnHitEvent>(OnMeleeThrowOnHitAttempt);
|
||||
}
|
||||
|
||||
@@ -230,6 +231,14 @@ namespace Content.Server.Psionics.Glimmer
|
||||
}
|
||||
}
|
||||
|
||||
private void OnAnchorStateChanged(EntityUid uid, SharedGlimmerReactiveComponent component, AnchorStateChangedEvent args)
|
||||
{
|
||||
if (!args.Anchored && _glimmerSystem.GetGlimmerTier() >= GlimmerTier.Dangerous)
|
||||
{
|
||||
AnchorOrExplode(uid);
|
||||
}
|
||||
}
|
||||
|
||||
public void BeamRandomNearProber(EntityUid prober, int targets, float range = 10f)
|
||||
{
|
||||
List<EntityUid> targetList = new();
|
||||
@@ -425,4 +434,3 @@ namespace Content.Server.Psionics.Glimmer
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user