Esempio n. 1
0
        public override void Draw(CustomSpriteBatch g, Matrix View)
        {
            effect.View = View;

            effect.World = Rotation
                           * Matrix.CreateTranslation(Position);

            effect.CurrentTechnique.Passes[0].Apply();
            g.GraphicsDevice.DrawUserPrimitives(PrimitiveType.TriangleList, vertexes, 0, 12);

            foreach (Object3D AntiGravPropulsor in ArrayAntiGravPropulsor)
            {
                AntiGravPropulsor.Draw(g, View);
            }
        }
Esempio n. 2
0
        public override void Draw(CustomSpriteBatch g, Matrix View)
        {
            Matrix World = Matrix.CreateTranslation(0f, 0f, 0f);

            VehiculeDrawablePart.ArrayParticles[0].Position     = Position;
            VehiculeDrawablePart.ArrayParticles[0 + 1].Position = Position;
            VehiculeDrawablePart.ArrayParticles[0 + 2].Position = Position;
            VehiculeDrawablePart.ArrayParticles[0 + 3].Position = Position;

            VehiculeDrawablePart.MoveParticle(0, Vector3.Zero);
            VehiculeDrawablePart.SetViewProjection(World * View, Projection);
            VehiculeDrawablePart.Draw(g.GraphicsDevice);

            foreach (Object3D AntiGravPropulsor in ArrayAntiGravPropulsor)
            {
                AntiGravPropulsor.Draw(g, View);
            }
        }