Vector2IntExtensions.Clamped

Extension Method in Vector2IntExtensions

Declaration

public static Vector2Int Clamped(this Vector2Int vector, Vector2Int min, Vector2Int max)

Description

Clamps the vector to the range [min..max].

Parameters

vectorThe vector to clamp.
minThe minimum value.
maxThe maximum value.

Returns

Vector2IntA new clamped vector.