Station AI (#30944)
* Station AI overlay * implement * Bunch of ports * Fix a heap of bugs and basic scouting * helldivers * Shuffle interactions a bit * navmap stuff * Revert "navmap stuff" This reverts commit d1f89dd4be83233e22cf5dd062b2581f3c6da062. * AI wires implemented * Fix examines * Optimise the overlay significantly * Back to old static * BUI radial working * lots of work * Saving work * thanks fork * alright * pc * AI upload console * AI upload * stuff * Fix copy-paste shitcode * AI actions * navmap work * Fixes * first impressions * a * reh * Revert "navmap work" This reverts commit 6f63fea6e9245e189f368f97be3e32e9b210580e. # Conflicts: # Content.Client/Silicons/StationAi/StationAiOverlay.cs * OD * radar * weh * Fix examines * scoop mine eyes * fixes * reh * Optimise * Final round of optimisations * Fixes * fixes
This commit is contained in:
@@ -2,6 +2,7 @@ using Content.Shared.Body.Events;
|
||||
using Content.Shared.Emoting;
|
||||
using Content.Shared.Hands;
|
||||
using Content.Shared.Interaction;
|
||||
using Content.Shared.Interaction.Components;
|
||||
using Content.Shared.Interaction.Events;
|
||||
using Content.Shared.Item;
|
||||
using Content.Shared.Movement.Components;
|
||||
@@ -22,9 +23,14 @@ namespace Content.Shared.ActionBlocker
|
||||
{
|
||||
[Dependency] private readonly SharedContainerSystem _container = default!;
|
||||
|
||||
private EntityQuery<ComplexInteractionComponent> _complexInteractionQuery;
|
||||
|
||||
public override void Initialize()
|
||||
{
|
||||
base.Initialize();
|
||||
|
||||
_complexInteractionQuery = GetEntityQuery<ComplexInteractionComponent>();
|
||||
|
||||
SubscribeLocalEvent<InputMoverComponent, ComponentStartup>(OnMoverStartup);
|
||||
}
|
||||
|
||||
@@ -53,6 +59,15 @@ namespace Content.Shared.ActionBlocker
|
||||
return !ev.Cancelled;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Checks if a given entity is able to do specific complex interactions.
|
||||
/// This is used to gate manipulation to general humanoids. If a mouse shouldn't be able to do something, then it's complex.
|
||||
/// </summary>
|
||||
public bool CanComplexInteract(EntityUid user)
|
||||
{
|
||||
return _complexInteractionQuery.HasComp(user);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Raises an event directed at both the user and the target entity to check whether a user is capable of
|
||||
/// interacting with this entity.
|
||||
|
||||
Reference in New Issue
Block a user