public void Setup(Car car, Vector3 pos, ///< position relative to car, in car's space Vector3 axisUp, ///< in car's space float spring, ///< force per suspension offset float travel, ///< suspension travel upwards float inertia, ///< inertia about the axel float radius, float sideFriction, float fwdFriction, float damping, int numRays) { this.car = car; this.pos = pos; this.axisUp = axisUp; this.spring = spring; this.travel = travel; this.inertia = inertia; this.radius = radius; this.sideFriction = sideFriction; this.fwdFriction = fwdFriction; this.damping = damping; this.numRays = numRays; pred = new WheelPred(car.Chassis.Body.CollisionSkin); Reset(); }
public void Setup(Car car, Vector3 pos, Vector3 axisUp, float spring, float travel, float inertia, float radius, float sideFriction, float fwdFriction, float damping, int numRays) { _car = car; Pos = pos; LocalAxisUp = axisUp; _spring = spring; _travel = travel; _inertia = inertia; Radius = radius; _sideFriction = sideFriction; _fwdFriction = fwdFriction; _damping = damping; _numRays = numRays; _pred = new WheelPred(car.Chassis.Body.CollisionSkin); Reset(); }