Class InvertVector3Processor
Inverts the x
and/or y
and/or z
channel of a Vector3
.
Inherited Members
Namespace: UnityEngine.InputSystem.Processors
Assembly: Unity.InputSystem.dll
Syntax
public class InvertVector3Processor : InputProcessor<Vector3>
Remarks
This process is registered (see RegisterProcessor<T>(string) as "invertVector3" by default.
// Bind to gravity sensor such that its Y value is inverted.
new InputAction(binding: "<GravitySensor>/gravity", processors="invertVector3(invertX=false,invertY,invertZ=false)");
Fields
invertX
If true, the x
channel of the Vector3
input value is inverted. True by default.
Declaration
public bool invertX
Field Value
Type | Description |
---|---|
bool |
See Also
invertY
If true, the y
channel of the Vector3
input value is inverted. True by default.
Declaration
public bool invertY
Field Value
Type | Description |
---|---|
bool |
See Also
invertZ
If true, the z
channel of the Vector3
input value is inverted. True by default.
Declaration
public bool invertZ
Field Value
Type | Description |
---|---|
bool |
See Also
Methods
Process(Vector3, InputControl)
Return the given vector with the respective channels being inverted.
Declaration
public override Vector3 Process(Vector3 value, InputControl control)
Parameters
Type | Name | Description |
---|---|---|
Vector3 | value | Input value. |
InputControl | control | Ignored. |
Returns
Type | Description |
---|---|
Vector3 | Vector with channels inverted according to invertX, invertY, and invertZ. |
Overrides
See Also
ToString()
Declaration
public override string ToString()
Returns
Type | Description |
---|---|
string |