Advertisement
Alan468

Układy odniesienia 3D MonoGame

Nov 20th, 2018
573
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C# 21.22 KB | None | 0 0
  1. using System.Collections.Generic;
  2. using System.Linq;
  3. using Microsoft.Xna.Framework;
  4. using Microsoft.Xna.Framework.Graphics;
  5. using Microsoft.Xna.Framework.Input;
  6. using OrientationSystems;
  7.  
  8. namespace MazeEscape.CustomClasses
  9. {
  10.     public class Camera : GameComponent
  11.     {
  12.         private Vector3 cameraPosition;
  13.         public Vector3 cameraRotation;
  14.  
  15.         public float cameraSpeed { get; set; }
  16.         public Vector3 cameraLookAt;
  17.  
  18.         private Vector3 mouseRotationBuffer;
  19.         private MouseState currentMouseState;
  20.         private MouseState prevMouseState;
  21.  
  22.  
  23.         public Vector3 Position
  24.         {
  25.             get { return cameraPosition; }
  26.             set
  27.             {
  28.                 cameraPosition = value;
  29.                 UpdateLookAt();
  30.             }
  31.         }
  32.  
  33.         public Vector3 Rotation
  34.         {
  35.             get { return cameraRotation; }
  36.             set
  37.             {
  38.                 cameraRotation = value;
  39.                 UpdateLookAt();
  40.             }
  41.         }
  42.  
  43.         public Matrix Projection { get; protected set; }
  44.  
  45.         public Matrix View => Matrix.CreateLookAt(cameraPosition, cameraLookAt, Vector3.Up);
  46.  
  47.         public Game1 game { get; set; }
  48.  
  49.         public Camera(Game game, Vector3 position, Vector3 rotation, float speed) : base(game)
  50.         {
  51.             this.game = game as Game1;
  52.  
  53.             cameraSpeed = speed;
  54.             Projection = Matrix.CreatePerspectiveFieldOfView(MathHelper.PiOver4, Game.GraphicsDevice.Viewport.AspectRatio, 0.05f, 1000);
  55.             MoveTo(position, rotation);
  56.             prevMouseState = Mouse.GetState();
  57.         }
  58.  
  59.         private void MoveTo(Vector3 pos, Vector3 rot)
  60.         {
  61.             Position = pos;
  62.             Rotation = rot;
  63.         }
  64.  
  65.         private void UpdateLookAt()
  66.         {
  67.             var rotationMartix = Matrix.CreateRotationX(cameraRotation.X) * Matrix.CreateRotationY(cameraRotation.Y);
  68.  
  69.             var lookAtOffset = Vector3.Transform(Vector3.UnitZ, rotationMartix);
  70.             cameraLookAt = cameraPosition + lookAtOffset;
  71.         }
  72.  
  73.         private Vector3 PreviewMove3D(Vector3 amount)
  74.         {
  75.             var rotate = Matrix.CreateRotationX(cameraRotation.X) * Matrix.CreateRotationY(cameraRotation.Y) * Matrix.CreateRotationZ(cameraRotation.Z);
  76.  
  77.             var movment = new Vector3(amount.X, amount.Y, amount.Z);
  78.             movment = Vector3.Transform(movment, rotate);
  79.  
  80.             return cameraPosition + movment;
  81.         }
  82.         private Vector3 PreviewMove(Vector3 amount)
  83.         {
  84.             var rotate = Matrix.CreateRotationY(cameraRotation.Y);
  85.  
  86.             var movment = new Vector3(amount.X, amount.Y, amount.Z);
  87.             movment = Vector3.Transform(movment, rotate);
  88.  
  89.             return cameraPosition + movment;
  90.         }
  91.  
  92.         public Vector3 cameraAxiesPosition
  93.         {
  94.             get
  95.             {
  96.                 var rotate = Matrix.CreateRotationX(cameraRotation.X) * Matrix.CreateRotationY(cameraRotation.Y) * Matrix.CreateRotationZ(cameraRotation.Z);
  97.                 var movment = new Vector3(-0.3f, -0.15f, 0.5f);
  98.                 movment = Vector3.Transform(movment, rotate);
  99.  
  100.                 return cameraPosition + movment;
  101.             }
  102.         }
  103.  
  104.  
  105.         private void Move(Vector3 scale)
  106.         {
  107.             MoveTo(PreviewMove(scale), Rotation);
  108.         }
  109.  
  110.         private KeyboardState prevState;
  111.  
  112.         public int walkTimer = 0;
  113.  
  114.         public override void Update(GameTime gameTime)
  115.         {
  116.             if (Game.IsActive)
  117.             {
  118.                 currentMouseState = Mouse.GetState();
  119.                 var keyboardState = Keyboard.GetState();
  120.                 var dt = (float)gameTime.ElapsedGameTime.TotalSeconds;
  121.  
  122.                 var moveVector = Vector3.Zero;
  123.  
  124.                 if (keyboardState.IsKeyDown(Keys.W))
  125.                 {
  126.                     moveVector.Z = 1;
  127.                 }
  128.                 if (keyboardState.IsKeyDown(Keys.S))
  129.                 {
  130.                     moveVector.Z = -1;
  131.                 }
  132.  
  133.                 if (keyboardState.IsKeyDown(Keys.A))
  134.                 {
  135.                     moveVector.X = 1;
  136.                 }
  137.                 if (keyboardState.IsKeyDown(Keys.D))
  138.                 {
  139.                     moveVector.X = -1;
  140.                 }
  141.  
  142.                 if (keyboardState.IsKeyDown(Keys.Space))
  143.                 {
  144.                     moveVector.Y = 1;
  145.                 }
  146.                 if (keyboardState.IsKeyDown(Keys.C))
  147.                 {
  148.                     moveVector.Y = -1;
  149.                 }
  150.  
  151.  
  152.                 if (moveVector != Vector3.Zero)
  153.                 {
  154.                     moveVector.Normalize();
  155.                     moveVector *= dt * cameraSpeed;
  156.  
  157.                     Move(moveVector);
  158.                 }
  159.  
  160.  
  161.                 #region Camera Mouse
  162.                 if (currentMouseState != prevMouseState)
  163.                 {
  164.                     var deltaX = currentMouseState.X - (Game.GraphicsDevice.Viewport.Width / 2);
  165.                     var deltaY = currentMouseState.Y - (Game.GraphicsDevice.Viewport.Height / 2);
  166.  
  167.                     mouseRotationBuffer.X -= 0.05f * deltaX * dt;
  168.                     mouseRotationBuffer.Y -= 0.05f * deltaY * dt;
  169.  
  170.                     if (mouseRotationBuffer.Y < MathHelper.ToRadians(-75))
  171.                         mouseRotationBuffer.Y -= mouseRotationBuffer.Y - MathHelper.ToRadians(-75);
  172.  
  173.                     if (mouseRotationBuffer.Y > MathHelper.ToRadians(75))
  174.                         mouseRotationBuffer.Y -= mouseRotationBuffer.Y - MathHelper.ToRadians(75);
  175.  
  176.                     Rotation = new Vector3(
  177.                         -MathHelper.Clamp(mouseRotationBuffer.Y, MathHelper.ToRadians(-75f), MathHelper.ToRadians(75f)),
  178.                         MathHelper.WrapAngle(mouseRotationBuffer.X),
  179.                         0);
  180.                 }
  181.  
  182.                 Mouse.SetPosition(Game.GraphicsDevice.Viewport.Width / 2, Game.GraphicsDevice.Viewport.Height / 2);
  183.  
  184.                 prevMouseState = currentMouseState;
  185.                 #endregion
  186.  
  187.                 prevState = keyboardState;
  188.  
  189.                 base.Update(gameTime);
  190.  
  191.             }
  192.         }
  193.  
  194.     }
  195. }
  196.  
  197. /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// END CAMERA
  198.  
  199. using MazeEscape.CustomClasses;
  200. using System;
  201. using System.Collections.Generic;
  202. using System.Linq;
  203. using System.Text;
  204. using System.Threading.Tasks;
  205. using Microsoft.Xna.Framework;
  206. using Microsoft.Xna.Framework.Graphics;
  207.  
  208. namespace OrientationSystems
  209. {
  210.     public class LineFloor
  211.     {
  212.         private Game1 game1;
  213.         private List<Line> Lines;
  214.         private Vector3 Position;
  215.         private float Width, Height, Spacing;
  216.         private GraphicsDevice GraphicsDevice;
  217.  
  218.         public LineFloor(Game1 game, GraphicsDevice graphicsDevice, Vector3 position, float width, float height, float spacing)
  219.         {
  220.             game1 = game;
  221.             Width = width;
  222.             Height = height;
  223.             Spacing = spacing;
  224.             Position = position;
  225.             GraphicsDevice = graphicsDevice;
  226.             CreateFloor();
  227.         }
  228.  
  229.         public void CreateFloor()
  230.         {
  231.             Lines = new List<Line>();
  232.             for (int x = 0; x < Width; x++)
  233.             {
  234.                 Lines.Add(new Line(GraphicsDevice, new Vector3(Position.X + (x * Spacing), Position.Y, Position.Z), new Vector3(Position.X + (x * Spacing), Position.Y, Position.Z + Width)));
  235.             }
  236.             Lines.Add(new Line(GraphicsDevice, new Vector3(Position.X + (Width * Spacing), Position.Y, Position.Z), new Vector3(Position.X + (Width * Spacing), Position.Y, Position.Z + Width)));
  237.  
  238.             for (int z = 0; z <= Height; z++)
  239.             {
  240.                 Lines.Add(new Line(GraphicsDevice, new Vector3(Position.X, Position.Y, Position.Z + (z * Spacing)), new Vector3(Position.X + Width, Position.Y, Position.Z + (z * Spacing))));
  241.             }
  242.             Lines.Add(new Line(GraphicsDevice, new Vector3(Position.X, Position.Y, Position.Z + (Height * Spacing)), new Vector3(Position.X + Width, Position.Y, Position.Z + (Height * Spacing))));
  243.         }
  244.  
  245.         public void Draw(BasicEffect basicEffect,Camera camera)
  246.         {
  247.             basicEffect.VertexColorEnabled = true;
  248.             basicEffect.View = camera.View;
  249.             basicEffect.Projection = camera.Projection;
  250.             basicEffect.World = Matrix.CreateTranslation(Position);
  251.  
  252.             foreach (var line in Lines)
  253.             {
  254.                 line.DrawLine(game1.camera, basicEffect, Color.Silver);
  255.             }
  256.         }
  257.     }
  258. }
  259.  
  260. /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// END LINE FLOR END
  261.  
  262. using System;
  263. using System.Collections.Generic;
  264. using System.Linq;
  265. using System.Text;
  266. using System.Threading.Tasks;
  267. using MazeEscape.CustomClasses;
  268. using Microsoft.Xna.Framework;
  269. using Microsoft.Xna.Framework.Graphics;
  270.  
  271. namespace OrientationSystems
  272. {
  273.     public class CordSystem
  274.     {
  275.         public CordSystem ParentSystem { get; set; }
  276.  
  277.         public Vector3 Position { get; set; }
  278.         public Vector3 Rotation { get; set; }
  279.         public Vector3 Scale { get; set; }
  280.         public bool IgnoreParentRotation { get; set; }
  281.  
  282.         private List<Line> CordLines { get; set; }
  283.  
  284.         public Vector3 GetRelativePosition
  285.         {
  286.             get
  287.             {
  288.                 if (ParentSystem != null)
  289.                 {
  290.                     return Position + ParentSystem.GetRelativePosition;
  291.                 }
  292.                 else
  293.                 {
  294.                     return Position;
  295.                 }
  296.             }
  297.         }
  298.         public Vector3 GetRelativeRotation
  299.         {
  300.             get
  301.             {
  302.                 if (ParentSystem != null && !IgnoreParentRotation)
  303.                 {
  304.                     return Rotation + ParentSystem.GetRelativeRotation;
  305.                 }
  306.                 else
  307.                 {
  308.                     return Rotation;
  309.                 }
  310.             }
  311.         }
  312.  
  313.         private GraphicsDevice GraphicsDevice;
  314.  
  315.         public CordSystem(GraphicsDevice graphicsDevice, CordSystem parent, Vector3 position)
  316.         {
  317.             Scale = Vector3.One;
  318.             IgnoreParentRotation = false;
  319.             GraphicsDevice = graphicsDevice;
  320.             ParentSystem = parent;
  321.             Position = position;
  322.             Rotation = Vector3.Zero;
  323.  
  324.             CordLines = new List<Line>(){
  325.             new Line(GraphicsDevice, Vector3.Zero, new Vector3(20, 0, 0)) { color = Color.Red, Position = GetRelativePosition },
  326.             new Line(GraphicsDevice, Vector3.Zero, new Vector3(0, 20, 0)) { color = Color.Green, Position = GetRelativePosition },
  327.             new Line(GraphicsDevice, Vector3.Zero, new Vector3(0, 0, 20)) { color = Color.Blue, Position = GetRelativePosition }
  328.             };
  329.         }
  330.  
  331.         public void DrawSystemAxies(Camera camera)
  332.         {
  333.             var basicEffectBuff = CreateCordSystemBasicEffect(camera);
  334.             foreach (var cordLine in CordLines)
  335.             {
  336.                 cordLine.Position = GetRelativePosition;
  337.                 cordLine.DrawLine(camera, basicEffectBuff, cordLine.color);
  338.             }
  339.         }
  340.  
  341.         public BasicEffect CreateCordSystemBasicEffect(Camera camera)
  342.         {
  343.             var basicEffect = new BasicEffect(GraphicsDevice);
  344.             basicEffect.VertexColorEnabled = true;
  345.             basicEffect.View = camera.View;
  346.             basicEffect.Projection = camera.Projection;
  347.             basicEffect.World = Matrix.CreateScale(Scale) *
  348.                                 Matrix.CreateTranslation(GetRelativePosition) *
  349.                                 Matrix.CreateRotationX(GetRelativeRotation.X) *
  350.                                 Matrix.CreateRotationY(GetRelativeRotation.Y) *
  351.                                 Matrix.CreateRotationZ(GetRelativeRotation.Z);
  352.  
  353.             return basicEffect;
  354.         }
  355.     }
  356. }
  357.  
  358.  
  359. /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// END CORD SYSTEM END
  360.  
  361. using System;
  362. using System.Collections.Generic;
  363. using System.Linq;
  364. using System.Text;
  365. using System.Threading.Tasks;
  366. using Microsoft.Xna.Framework;
  367. using Microsoft.Xna.Framework.Graphics;
  368. using OrientationSystems;
  369.  
  370. namespace MazeEscape.CustomClasses
  371. {
  372.     public class Line
  373.     {
  374.         public Vector3 Position;
  375.         public Vector3 startPoint;
  376.         public Vector3 endPoint;
  377.         private VertexPositionColor[] vertices;
  378.         private GraphicsDevice GraphicsDevice;
  379.         public Color color;
  380.  
  381.         public Line(GraphicsDevice graphicsDevice)
  382.         {
  383.             Position = Vector3.Zero;
  384.             GraphicsDevice = graphicsDevice;
  385.         }
  386.         public Line(GraphicsDevice graphicsDevice, Vector3 start, Vector3 end)
  387.         {
  388.             Position = Vector3.Zero;
  389.             GraphicsDevice = graphicsDevice;
  390.             startPoint = start;
  391.             endPoint = end;
  392.         }
  393.  
  394.         public void DrawLine(Camera camera, BasicEffect basicEffect, Vector3 start, Vector3 end, Color color)
  395.         {
  396.             basicEffect.CurrentTechnique.Passes[0].Apply();
  397.             vertices = new[] { new VertexPositionColor(start, color), new VertexPositionColor(end, color) };
  398.             GraphicsDevice.DrawUserPrimitives(PrimitiveType.LineList, vertices, 0, 1);
  399.         }
  400.  
  401.         public void DrawLine(Camera camera, BasicEffect basicEffect, Color color)
  402.         {
  403.             basicEffect.CurrentTechnique.Passes[0].Apply();
  404.             vertices = new[] { new VertexPositionColor(startPoint, color), new VertexPositionColor(endPoint, color) };
  405.             GraphicsDevice.DrawUserPrimitives(PrimitiveType.LineList, vertices, 0, 1);
  406.         }
  407.  
  408.     }
  409. }
  410.  
  411.  
  412. /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// END LINE END
  413.  
  414. using System.Collections.Generic;
  415. using MazeEscape.CustomClasses;
  416. using Microsoft.Xna.Framework;
  417. using Microsoft.Xna.Framework.Graphics;
  418. using Microsoft.Xna.Framework.Input;
  419.  
  420. namespace OrientationSystems
  421. {
  422.     public class Game1 : Game
  423.     {
  424.         GraphicsDeviceManager graphics;
  425.         public Camera camera;
  426.         SpriteBatch spriteBatch;
  427.         private BasicEffect basicEffect;
  428.         SpriteFont Font;
  429.  
  430.         private CordSystem system1, system2, system3;
  431.  
  432.         public Game1()
  433.         {
  434.             graphics = new GraphicsDeviceManager(this);
  435.             Content.RootDirectory = "Content";
  436.             Window.AllowUserResizing = false;
  437.             graphics.PreferredBackBufferHeight = 720;
  438.             graphics.PreferredBackBufferWidth = 1280;
  439.             IsMouseVisible = true;
  440.         }
  441.  
  442.         private LineFloor floor;
  443.  
  444.         protected override void Initialize()
  445.         {
  446.             spriteBatch = new SpriteBatch(GraphicsDevice);
  447.             basicEffect = new BasicEffect(GraphicsDevice)
  448.             {
  449.                 Alpha = 1,
  450.                 VertexColorEnabled = true,
  451.                 LightingEnabled = false,
  452.             };
  453.             Font = Content.Load<SpriteFont>("SpriteFontPL");
  454.  
  455.             // Tworzenie i dodawanie kamery
  456.             camera = new Camera(this, new Vector3(0, 15, 0), Vector3.Zero, 15);
  457.             Components.Add(camera);
  458.  
  459.             system1 = new CordSystem(GraphicsDevice, null, Vector3.Zero);
  460.             system2 = new CordSystem(GraphicsDevice, system1, new Vector3(5));
  461.             system3 = new CordSystem(GraphicsDevice, system2, new Vector3(5));
  462.  
  463.             floor = new LineFloor(this, GraphicsDevice, Vector3.Zero, 50, 50, 1);
  464.  
  465.             base.Initialize();
  466.         }
  467.  
  468.         private KeyboardState statePrev;
  469.  
  470.         protected override void Update(GameTime gameTime)
  471.         {
  472.             var state = Keyboard.GetState();
  473.  
  474.             if (state.IsKeyDown(Keys.Escape))
  475.                 Exit();
  476.  
  477.             var moveSpeed = 0.5f;
  478.             var rotateSpeed = 0.05f;
  479.  
  480.             #region SterowanieSystem2
  481.  
  482.             if (state.IsKeyUp(Keys.RightControl))
  483.             {
  484.                 if (state.IsKeyDown(Keys.Up))
  485.                     system2.Position += new Vector3(0, 0, moveSpeed);
  486.                 if (state.IsKeyDown(Keys.Down))
  487.                     system2.Position -= new Vector3(0, 0, moveSpeed);
  488.  
  489.                 if (state.IsKeyDown(Keys.Left))
  490.                     system2.Position += new Vector3(moveSpeed, 0, 0);
  491.                 if (state.IsKeyDown(Keys.Right))
  492.                     system2.Position -= new Vector3(moveSpeed, 0, 0);
  493.  
  494.                 if (state.IsKeyDown(Keys.PageUp))
  495.                     system2.Position += new Vector3(0, moveSpeed, 0);
  496.                 if (state.IsKeyDown(Keys.PageDown))
  497.                     system2.Position -= new Vector3(0, moveSpeed, 0);
  498.  
  499.                 if (state.IsKeyDown(Keys.NumPad7))
  500.                     system2.Rotation += new Vector3(0, 0, rotateSpeed);
  501.                 if (state.IsKeyDown(Keys.NumPad9))
  502.                     system2.Rotation -= new Vector3(0, 0, rotateSpeed);
  503.  
  504.                 if (state.IsKeyDown(Keys.NumPad8))
  505.                     system2.Rotation += new Vector3(rotateSpeed, 0, 0);
  506.                 if (state.IsKeyDown(Keys.NumPad2))
  507.                     system2.Rotation -= new Vector3(rotateSpeed, 0, 0);
  508.  
  509.                 if (state.IsKeyDown(Keys.NumPad4))
  510.                     system2.Rotation += new Vector3(0, rotateSpeed, 0);
  511.                 if (state.IsKeyDown(Keys.NumPad6))
  512.                     system2.Rotation -= new Vector3(0, rotateSpeed, 0);
  513.  
  514.                 if (state.IsKeyDown(Keys.M) && statePrev.IsKeyDown(Keys.M))
  515.                     system2.IgnoreParentRotation = !system2.IgnoreParentRotation;
  516.             }
  517.  
  518.             #endregion
  519.  
  520.             #region SterowanieSystem2
  521.  
  522.             if (state.IsKeyDown(Keys.RightControl))
  523.             {
  524.                 if (state.IsKeyDown(Keys.Up))
  525.                     system3.Position += new Vector3(0, 0, moveSpeed);
  526.                 if (state.IsKeyDown(Keys.Down))
  527.                     system3.Position -= new Vector3(0, 0, moveSpeed);
  528.  
  529.                 if (state.IsKeyDown(Keys.Left))
  530.                     system3.Position += new Vector3(moveSpeed, 0, 0);
  531.                 if (state.IsKeyDown(Keys.Right))
  532.                     system3.Position -= new Vector3(moveSpeed, 0, 0);
  533.  
  534.                 if (state.IsKeyDown(Keys.PageUp))
  535.                     system3.Position += new Vector3(0, moveSpeed, 0);
  536.                 if (state.IsKeyDown(Keys.PageDown))
  537.                     system3.Position -= new Vector3(0, moveSpeed, 0);
  538.  
  539.                 if (state.IsKeyDown(Keys.NumPad7))
  540.                     system3.Rotation += new Vector3(0, 0, rotateSpeed);
  541.                 if (state.IsKeyDown(Keys.NumPad9))
  542.                     system3.Rotation -= new Vector3(0, 0, rotateSpeed);
  543.  
  544.                 if (state.IsKeyDown(Keys.NumPad8))
  545.                     system3.Rotation += new Vector3(rotateSpeed, 0, 0);
  546.                 if (state.IsKeyDown(Keys.NumPad2))
  547.                     system3.Rotation -= new Vector3(rotateSpeed, 0, 0);
  548.  
  549.                 if (state.IsKeyDown(Keys.NumPad4))
  550.                     system3.Rotation += new Vector3(0, rotateSpeed, 0);
  551.                 if (state.IsKeyDown(Keys.NumPad6))
  552.                     system3.Rotation -= new Vector3(0, rotateSpeed, 0);
  553.  
  554.                 if (state.IsKeyDown(Keys.M) && statePrev.IsKeyDown(Keys.M))
  555.                     system3.IgnoreParentRotation = !system3.IgnoreParentRotation;
  556.             }
  557.  
  558.             #endregion
  559.             statePrev = state;
  560.  
  561.             base.Update(gameTime);
  562.         }
  563.  
  564.         protected override void Draw(GameTime gameTime)
  565.         {
  566.             GraphicsDevice.Clear(Color.CornflowerBlue);
  567.  
  568.             spriteBatch.Begin();
  569.             {
  570.                 spriteBatch.DrawString(Font, $"System1 {system1.Position} === {system1.GetRelativePosition}", new Vector2(20, 20), Color.White, 0, Vector2.Zero, new Vector2(0.3f), SpriteEffects.None, 0);
  571.                 spriteBatch.DrawString(Font, $"System2 {system2.Position} === {system2.GetRelativePosition}", new Vector2(20, 45), Color.White, 0, Vector2.Zero, new Vector2(0.3f), SpriteEffects.None, 0);
  572.                 spriteBatch.DrawString(Font, $"System3 {system3.Position} === {system3.GetRelativePosition}", new Vector2(20, 70), Color.White, 0, Vector2.Zero, new Vector2(0.3f), SpriteEffects.None, 0);
  573.             }
  574.             spriteBatch.End();
  575.  
  576.             var depthStencilState = new DepthStencilState
  577.             {
  578.                 DepthBufferEnable = true
  579.             };
  580.             GraphicsDevice.DepthStencilState = depthStencilState;
  581.  
  582.             floor.Draw(basicEffect, camera);
  583.  
  584.             system1.DrawSystemAxies(camera);
  585.             system2.DrawSystemAxies(camera);
  586.             system3.DrawSystemAxies(camera);
  587.  
  588.             // TODO: Add your drawing code here
  589.  
  590.             base.Draw(gameTime);
  591.         }
  592.     }
  593. }
  594. /////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// END GAME 1
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement