Пример #1
0
        public Chassis(Car car)
        {
            body          = new ChassisBody(car);
            collisionSkin = new CollisionSkin(body);

            body.CollisionSkin = collisionSkin;

            float length = 6.0f;
            float width  = 2.3f;
            float height = 1.6f;

            Vector3 min = new Vector3(-0.5f * length, 0.0f, -width * 0.5f);
            Vector3 max = new Vector3(0.5f * length, height, width * 0.5f);

            SetDims(min, max);
        }
Пример #2
0
        /// <summary>
        /// Constructor
        /// </summary>
        /// <param name="car"></param>
        public Chassis(RollingVehicle car)
        {
            body = new ChassisBody(car);
            collisionSkin = new CollisionSkin(body);

            body.CollisionSkin = collisionSkin;

            float length = 6.0f;
            float width = 2.3f;
            float height = 1.6f;

            Vector3 min = new Vector3(-0.5f * length, 0.0f, -width * 0.5f);
            Vector3 max = new Vector3(0.5f * length, height, width * 0.5f);

            SetDims(min, max);
        }
Пример #3
0
        public Chassis(Car car)
        {
            _body = new ChassisBody(car);
            Skin  = new CollisionSkin(_body);

            _body.CollisionSkin = Skin;

            const float length = 6.0f;
            const float width  = 2.3f;
            const float height = 1.6f;

            var min = new Vector3(-0.5f * length, 0.0f, -width * 0.5f);
            var max = new Vector3(0.5f * length, height, width * 0.5f);

            SetDims(min, max);
        }
Пример #4
0
        public Chassis(Car car)
        {
            body = new ChassisBody(car);
            collisionSkin = new CollisionSkin(body);

            body.CollisionSkin = collisionSkin;

            float s = 2;
            float length = 4.0f * s;
            float width = 4.3f * s;
            float height = 1.6f * s;

            Vector3 min = new Vector3(-0.5f * length, 0.0f, -width * 0.5f);
            Vector3 max = new Vector3(0.5f * length, height, width * 0.5f);

            SetDims(min, max);
        }