stock

xs_vec_sqdistance_2d

Syntax

stock Float:xs_vec_sqdistance_2d(const Float:vec1[], const Float:vec2[])

Description

Computes the square of the distance between two 2D vectors (points).
This is faster than the distance.

Parameters

vec1 First vector.
vec2 Second vector.

Return

The square of the distance between two vectors.