Documentation

Unity Engine


User Manual

Script Reference

Unity Engine


operator +

Returns the result of a componentwise addition operation on two int2 vectors.
Read time 1 minuteLast updated 4 days ago

Definition

  • Type: Operator
  • Namespace: Unity.Mathematics
  • Assembly: UnityEngine.MathematicsModule

operator +(int2, int2)

Returns the result of a componentwise addition operation on two int2 vectors.
public static int2 operator +(int2 lhs, int2 rhs)

Parameters

lhs

Left hand side int2 to use to compute componentwise addition.

rhs

Right hand side int2 to use to compute componentwise addition.

Returns

Type

Description

int2int2 result of the componentwise addition.

operator +(int2, int)

Returns the result of a componentwise addition operation on an int2 vector and an int value.
public static int2 operator +(int2 lhs, int rhs)

Parameters

lhs

Left hand side int2 to use to compute componentwise addition.

rhs

Right hand side int to use to compute componentwise addition.

Returns

Type

Description

int2int2 result of the componentwise addition.

operator +(int, int2)

Returns the result of a componentwise addition operation on an int value and an int2 vector.
public static int2 operator +(int lhs, int2 rhs)

Parameters

lhs

Left hand side int to use to compute componentwise addition.

rhs

Right hand side int2 to use to compute componentwise addition.

Returns

Type

Description

int2int2 result of the componentwise addition.