407 {
408 array<Shape> shapes = new array<Shape>;
409
410 vector endL, endR;
411 Math3D.ConePoints(pos, lenght, halfAngle, offsetAngle, endL, endR);
412
413
414 shapes.Insert(
Debug.DrawLine(pos, endL, color, flags) );
415
416 shapes.Insert(
Debug.DrawLine(pos, endR, color, flags) );
417
418 shapes.Insert(
Debug.DrawLine(endL, endR, color, flags) );
419
420 shapes.Insert(
Debug.DrawLine(pos, pos +
Vector(Math.Cos(offsetAngle), 0, Math.Sin(offsetAngle)).
Normalized() * lenght, color, flags) );
421
422 return shapes;
423 }
proto vector Normalized()
return normalized vector (keeps orginal vector untouched)
proto native vector Vector(float x, float y, float z)
Vector constructor from components.