DayZ 1.27
DayZ Explorer by KGB
 
Загрузка...
Поиск...
Не найдено

◆ GetRandomDir()

static vector Math3D::GetRandomDir ( )
inlinestaticprivate

Returns randon normalized direction.

Возвращает
vector
Print( Math3D.GetRandomDir() );
>>vector ret = 0x0000000007c1a1c0 {<0.422565,0,-0.906333>}
Определения EnConvert.c:106
proto void Print(void var)
Prints content of variable to console/log.
void Math3D()
Определения EnMath3D.c:29

См. определение в файле EnMath3D.c строка 447

448 {
449 float x = Math.RandomFloatInclusive(-1, 1);
450 float y = Math.RandomFloatInclusive(-1, 1);
451 float z = Math.RandomFloatInclusive(-1, 1);
452
453 return Vector(x, y, z).Normalized();
454 }
Icon x
Icon y
proto vector Normalized()
return normalized vector (keeps orginal vector untouched)
proto native vector Vector(float x, float y, float z)
Vector constructor from components.

Перекрестные ссылки vector::Normalized(), Math::RandomFloatInclusive(), Vector(), x и y.