mirror of
https://github.com/space-syndicate/space-station-14.git
synced 2026-10-14 04:41:14 +03:00
* update math * target finder system * ports * guns with projectiles * make sure * custom sprites for the laser * add auto link * add module * sprite for the missile * update animation speed * ops * make it glow * overlay sprite * stuff that doesn't work * update launcher * fix it * make it see from far * make it work * sprite for the module * 30 seconds is too much * sprite for the range finder * why was that here? * update sprite of the missile * update module icon * ops * update missile and missile launcher * make it look like the launcher item * remove ammo counter from range finder * increase to 15 seconds * no longer show the battery percentage * use comp * change summary * ops * new line * make it last longer * commentary * acme moment * fix bug when shooter was also the target and the projectile wouldn't move * empty commit * fix test fail * replace with global behavior * forgot to remove from the yml * important * check to see if the target exists * fix autorefill bug * remove unused system * make it reload a tad slower --------- Co-authored-by: beck-thompson <beck314159@hotmail.com>
30 lines
951 B
C#
30 lines
951 B
C#
using Content.Shared.DeviceLinking;
|
|
using Robust.Shared.GameStates;
|
|
using Robust.Shared.Prototypes;
|
|
|
|
namespace Content.Shared.Weapons.Ranged.Components;
|
|
|
|
/// <summary>
|
|
/// If a gun with this component fires a projectile with <see cref="TargetFinderHitscanComponent"/>,
|
|
/// when the projectile hits a entity. it will update the target in this component.
|
|
/// </summary>
|
|
[RegisterComponent, NetworkedComponent]
|
|
public sealed partial class TargetFinderComponent : Component
|
|
{
|
|
/// <summary>
|
|
/// Target selected
|
|
/// </summary>
|
|
[DataField]
|
|
public EntityUid? Target;
|
|
|
|
/// <summary>
|
|
/// Reference to gun with <see cref="TargetAssignComponent"/> connected with this entity
|
|
/// </summary>
|
|
public EntityUid? TargetAssigner;
|
|
|
|
/// <summary>
|
|
/// The linking port for linking the targetFinder with the targetAssign.
|
|
/// </summary>
|
|
[DataField]
|
|
public ProtoId<SourcePortPrototype> LinkingPort = "TargetSource";
|
|
}
|