Class CollisionEvent2DUnit
Inheritance
CollisionEvent2DUnit
Implements
Inherited Members
Namespace: Unity.VisualScripting
Assembly: Unity.VisualScripting.Flow.dll
Syntax
[UnitCategory("Events/Physics 2D")]
public abstract class CollisionEvent2DUnit : GameObjectEventUnit<Collision2D>, IGraphElementWithData, IGraphEventHandler<Collision2D>, IGameObjectEventUnit, IEventUnit, IUnit, IGraphElementWithDebugData, IGraphElement, IGraphItem, INotifiedCollectionItem, IDisposable, IPrewarmable, IAotStubbable, IIdentifiable, IAnalyticsIdentifiable, IGraphEventListener
Properties
collider
The collider we hit.
Declaration
[DoNotSerialize]
public ValueOutput collider { get; }
Property Value
Type | Description |
---|---|
ValueOutput |
contacts
The contact points generated by the physics engine.
Declaration
[DoNotSerialize]
public ValueOutput contacts { get; }
Property Value
Type | Description |
---|---|
ValueOutput |
data
The complete collision data object.
Declaration
[DoNotSerialize]
public ValueOutput data { get; }
Property Value
Type | Description |
---|---|
ValueOutput |
enabled
Whether the collision was enabled or not.
Declaration
[DoNotSerialize]
public ValueOutput enabled { get; }
Property Value
Type | Description |
---|---|
ValueOutput |
relativeVelocity
The relative linear velocity of the two colliding objects.
Declaration
[DoNotSerialize]
public ValueOutput relativeVelocity { get; }
Property Value
Type | Description |
---|---|
ValueOutput |
Methods
AssignArguments(Flow, Collision2D)
Declaration
protected override void AssignArguments(Flow flow, Collision2D collisionData)
Parameters
Type | Name | Description |
---|---|---|
Flow | flow | |
Collision2D | collisionData |
Overrides
Definition()
Declaration
protected override void Definition()