Ejemplo n.º 1
0
 /// <summary>
 /// The main entry point for the application.
 /// </summary>
 static void Main(string[] args)
 {
     using (JiggleGame game = new JiggleGame())
     {
         game.Run();
     }
 }
Ejemplo n.º 2
0
 /// <summary>
 /// The main entry point for the application.
 /// </summary>
 static void Main(string[] args)
 {
     using (JiggleGame game = new JiggleGame())
     {
         game.Run();
     }
 }
Ejemplo n.º 3
0
        public override void Draw(GameTime gameTime)
        {
            if (vertexData.Count == 0 || !Enabled)
            {
                return;
            }

            JiggleGame playGround = this.Game as JiggleGame;

            this.basicEffect.AmbientLightColor = Vector3.One;
            this.basicEffect.View               = playGround.Camera.View;
            this.basicEffect.Projection         = playGround.Camera.Projection;
            this.basicEffect.VertexColorEnabled = true;

            foreach (EffectPass pass in this.basicEffect.CurrentTechnique.Passes)
            {
                pass.Apply();

                GraphicsDevice.DrawUserPrimitives <VertexPositionColor>(PrimitiveType.LineStrip,
                                                                        vertexData.ToArray(), 0, vertexData.Count - 1);
            }

            vertexData.Clear();

            base.Draw(gameTime);
        }