Package net.lenkaspace.creeper.vo

Examples of net.lenkaspace.creeper.vo.CRVector3d.normalize()


   * @return CRVector3d vector where X component represents angle towards the object and y component distance
   */
  public CRVector3d getRelativeVectorTo(CRVector3d vector_, CRVector3d pivot_) {
    CRVector3d tempVector = CRVector3d.subtractVectors(pivot_, vector_);
    CRVector3d u = this.getVectorInLocalCoordinateSystem(tempVector);
    u.normalize();
   
    //distance from radial border of self to radial border of another object
    double distance = Math.hypot(position.x- vector_.x, position.y- vector_.y);
   
    //add direction:
View Full Code Here


  /**
   * Get normalised steering force vector
   */
  public CRVector3d getOrientationVector() {
    CRVector3d v = new CRVector3d(getRotationAsVectorComponent(), thrustForce,0);
    v.normalize();
    return v;
  }
 
  /**
   * Get vector that points in front of the situated model
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.