示例#1
0
        public WheelInfo(WheelInfoConstructionInfo constructionInfo)
        {
            _suspensionRestLength  = constructionInfo.SuspensionRestLength;
            _maxSuspensionTravelCm = constructionInfo.MaxSuspensionTravelCm;

            _wheelsRadius             = constructionInfo.WheelRadius;
            _wheelsDampingCompression = constructionInfo.WheelsDampingCompression;
            _wheelsDampingRelaxation  = constructionInfo.WheelsDampingRelaxation;
            _wheelDirectionCS         = constructionInfo.WheelDirectionCS;

            _suspensionStiffness      = constructionInfo.SuspensionStiffness;
            _chassicConnectionPointCS = constructionInfo.ChassicConnectionCS;

            _wheelAxleCS  = constructionInfo.WheelAxleCS;
            _frictionSlip = constructionInfo.FrictionSlip;

            _clippedInvContactDotSuspension = 0;
            _suspensionRelativeVelocity     = 0;
            _wheelsSuspensionForce          = 0;
            _skidInfo = 0;

            _steering      = 0;
            _engineForce   = 0;
            _rotation      = 0;
            _rotation      = 0;
            _deltaRotation = 0;
            _brake         = 0;
            _rollInfluence = 0.1f;
            _brake         = 0;
            _rollInfluence = 0.1f;

            _isFrontWheel = constructionInfo.IsFrontWheel;

            _raycastInfo    = default(RaycastInfo);
            _worldTransform = default(Matrix);
            _clientInfo     = null;
        }
示例#2
0
		public WheelInfo(WheelInfoConstructionInfo constructionInfo)
		{
			_suspensionRestLength = constructionInfo.SuspensionRestLength;
			_maxSuspensionTravelCm = constructionInfo.MaxSuspensionTravelCm;

			_wheelsRadius = constructionInfo.WheelRadius;
			_wheelsDampingCompression = constructionInfo.WheelsDampingCompression;
			_wheelsDampingRelaxation = constructionInfo.WheelsDampingRelaxation;
			_wheelDirectionCS = constructionInfo.WheelDirectionCS;

			_suspensionStiffness = constructionInfo.SuspensionStiffness;
			_chassicConnectionPointCS = constructionInfo.ChassicConnectionCS;

			_wheelAxleCS = constructionInfo.WheelAxleCS;
			_frictionSlip = constructionInfo.FrictionSlip;

			_clippedInvContactDotSuspension = 0;
			_suspensionRelativeVelocity = 0;
			_wheelsSuspensionForce = 0;
			_skidInfo = 0;

			_steering = 0;
			_engineForce = 0;
			_rotation = 0;
			_rotation = 0;
			_deltaRotation = 0;
			_brake = 0;
			_rollInfluence = 0.1f;
			_brake = 0;
			_rollInfluence = 0.1f;

			_isFrontWheel = constructionInfo.IsFrontWheel;

			_raycastInfo = default(RaycastInfo);
			_worldTransform = default(Matrix);
			_clientInfo = null;
		}