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

◆ IsFacingTarget()

bool ManBase::IsFacingTarget ( Object target)
inlineprotected

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

4924 {
4925 vector pdir = GetDirection();
4926 vector ptv = target.GetPosition() - GetPosition();
4927 pdir.Normalize();
4928 ptv.Normalize();
4929
4930 if (Math.AbsFloat(pdir[0]-ptv[0]) < 0.5 && Math.AbsFloat(pdir[2]-ptv[2]) < 0.5)
4931 {
4932 return true;
4933 }
4934 return false;
4935 }
proto float Normalize()
Normalizes vector. Returns length.
vector GetPosition()
Get the world position of the Effect.
Определения Effect.c:473

Перекрестные ссылки Math::AbsFloat(), GetPosition() и vector::Normalize().