Update vector.inc

This commit is contained in:
Hattrick HttrckCldHKS 2018-09-04 23:32:57 +03:00 committed by GitHub
parent 495d808704
commit 9d8dac5671
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -137,23 +137,11 @@ stock FVecIVec(const Float:FVec[3], IVec[3])
*
* @return True if the vector is zero, false otherwise
*/
stock bool:is_vector_zero(const Vector[3])
stock bool:IsVectorZero(const any:Vector[3])
{
return (Vector[0] == 0 && Vector[1] == 0 && Vector[2] == 0) ? true : false;
}
/**
* Checks if a float vector is zero.
*
* @param Vector The input float vector
*
* @return True if the float vector is zero, false otherwise
*/
stock bool:is_vector_zero_f(const Float:Vector[3])
{
return (Vector[0] == 0.0 && Vector[1] == 0.0 && Vector[2] == 0.0) ? true : false;
}
/**
* Sets a vector to zero.
*
@ -161,19 +149,7 @@ stock bool:is_vector_zero_f(const Float:Vector[3])
*
* @noreturn
*/
stock set_vector_zero(Vector[3])
stock SetVectorZero(any:Vector[3])
{
Vector[0] = Vector[1] = Vector[2] = 0;
}
/**
* Sets a float vector to zero.
*
* @param Vector Float vector
*
* @noreturn
*/
stock set_vector_zero_f(Float:Vector[3])
{
Vector[0] = Vector[1] = Vector[2] = 0.0;
}