Show / Hide Table of Contents

Class GetVerbsEvent<TVerb>

Directed event that requests verbs from any systems/components on a target entity.

Inheritance
System.Object
GetVerbsEvent<TVerb>
Namespace: Content.Shared.Verbs
Assembly: Content.Shared.dll
Syntax
public sealed class GetVerbsEvent<TVerb> : EntityEventArgs where TVerb : Verb
Type Parameters
Name Description
TVerb

Constructors

| Improve this Doc View Source

GetVerbsEvent(EntityUid, EntityUid, Nullable<EntityUid>, HandsComponent, Boolean, Boolean)

Declaration
public GetVerbsEvent(EntityUid user, EntityUid target, EntityUid? using, HandsComponent hands, bool canInteract, bool canAccess)
Parameters
Type Name Description
EntityUid user
EntityUid target
System.Nullable<EntityUid> using
HandsComponent hands
System.Boolean canInteract
System.Boolean canAccess

Fields

| Improve this Doc View Source

CanAccess

Can the user physically access the target?

Declaration
public readonly bool CanAccess
Field Value
Type Description
System.Boolean
Remarks

This is a combination of and InRangeUnobstructed(MapCoordinates, MapCoordinates, Single, CollisionGroup, SharedInteractionSystem.Ignored, Boolean).

| Improve this Doc View Source

CanInteract

Can the user physically interact?

Declaration
public readonly bool CanInteract
Field Value
Type Description
System.Boolean
Remarks

This is a just a cached CanInteract(EntityUid, Nullable<EntityUid>) result. Given that many verbs need to check this, it prevents it from having to be repeatedly called by each individual system that might contribute a verb.

| Improve this Doc View Source

Hands

The User's hand component.

Declaration
public readonly HandsComponent Hands
Field Value
Type Description
HandsComponent
Remarks

This may be null if the user has no hands.

| Improve this Doc View Source

Target

The entity being targeted for the verb.

Declaration
public readonly EntityUid Target
Field Value
Type Description
EntityUid
| Improve this Doc View Source

User

The entity that will be "performing" the verb.

Declaration
public readonly EntityUid User
Field Value
Type Description
EntityUid
| Improve this Doc View Source

Using

The entity currently being held by the active hand.

Declaration
public readonly EntityUid? Using
Field Value
Type Description
System.Nullable<EntityUid>
Remarks

This is only ever not null when CanUseHeldEntity(EntityUid) is true and the user has hands.

| Improve this Doc View Source

Verbs

Event output. Set of verbs that can be executed.

Declaration
public readonly SortedSet<TVerb> Verbs
Field Value
Type Description
SortedSet<TVerb>
  • Improve this Doc
  • View Source
☀
☾
In This Article
Back to top
Generated by DocFX
☀
☾