Exemplo n.º 1
0
        /// <summary>
        /// Initialise the physics model to be built
        /// </summary>
        public PhysicsModelBuilder()
        {
            _phmo = new PhysicsModel
            {
                RigidBodies = new List <PhysicsModel.RigidBody>(),
                Nodes       = new List <PhysicsModel.Node>()
            };
            var node = new PhysicsModel.Node
            {
                Child   = -1,
                Sibling = -1,
                Parent  = -1,
                //the 'default' stringid
                Name = new StringId(1)
            };

            _phmo.Nodes.Add(node);

            _phmo.Materials = new List <PhysicsModel.Material>();
            var material = new PhysicsModel.Material
            {
                //the 'default' stringid
                Name = new StringId(1),
                // ??? material.Flags = -256;
                PhantomType = -1
            };

            _phmo.Materials.Add(material);
        }
Exemplo n.º 2
0
        /// <summary>
        /// Initialise the physics model to be built
        /// </summary>
        public PhysicsModelBuilder()
        {
            _phmo             = new PhysicsModel();
            _phmo.RigidBodies = new List <PhysicsModel.RigidBody>();
            _phmo.Nodes       = new List <PhysicsModel.Node>();
            var node = new PhysicsModel.Node();

            node.Child   = -1;
            node.Sibling = -1;
            node.Parent  = -1;
            //the 'default' stringid
            node.Name = new StringId(1);

            _phmo.Nodes.Add(node);

            _phmo.Materials = new List <PhysicsModel.Material>();
            var material = new PhysicsModel.Material();

            //the 'default' stringid
            material.Name        = new StringId(1);
            material.Flags       = -256;
            material.PhantomType = -1;

            _phmo.Materials.Add(material);
        }