Syringe gun! (#32112)
* Init testing * copyright * oops * Tracking the embed entity uid * testing stuff for gradual injection * work * weh * god save me * bleh * Yippee! * Again * Mini syringe ammo * cleaning up * mini syringes have a texture for fill amount * -3 cool points :( * hitboxes * init cleanup * much needed fixes * Fixes
This commit is contained in:
@@ -71,6 +71,8 @@ public abstract partial class SharedProjectileSystem : EntitySystem
|
||||
TryComp<PhysicsComponent>(uid, out var physics);
|
||||
_physics.SetBodyType(uid, BodyType.Dynamic, body: physics, xform: xform);
|
||||
_transform.AttachToGridOrMap(uid, xform);
|
||||
component.EmbeddedIntoUid = null;
|
||||
Dirty(uid, component);
|
||||
|
||||
// Reset whether the projectile has damaged anything if it successfully was removed
|
||||
if (TryComp<ProjectileComponent>(uid, out var projectile))
|
||||
@@ -127,8 +129,10 @@ public abstract partial class SharedProjectileSystem : EntitySystem
|
||||
}
|
||||
|
||||
_audio.PlayPredicted(component.Sound, uid, null);
|
||||
component.EmbeddedIntoUid = target;
|
||||
var ev = new EmbedEvent(user, target);
|
||||
RaiseLocalEvent(uid, ref ev);
|
||||
Dirty(uid, component);
|
||||
}
|
||||
|
||||
private void PreventCollision(EntityUid uid, ProjectileComponent component, ref PreventCollideEvent args)
|
||||
|
||||
Reference in New Issue
Block a user