public override Happiness.Vector2 RotateAroundAxis_Z(float rotation) { Matrix rot = Matrix.CreateFromAxisAngle(Vector3.UnitZ, rotation); Vector3 direction3 = Vector3.Normalize(Vector3.Transform(Vector3.UnitX, rot)); Vector2 direction = new Vector2(direction3.X, direction3.Y); return(Renderer_XNA.XNAV2ToHappinessV2(direction)); }
/// <summary> /// LoadContent will be called once per game and is the place to load /// all of your content. /// </summary> protected override void LoadContent() { // Create a new SpriteBatch, which can be used to draw textures. spriteBatch = new SpriteBatch(GraphicsDevice); spriteBatch.GraphicsDevice.ScissorRectangle = new Rectangle(0, 0, spriteBatch.GraphicsDevice.Viewport.Width, spriteBatch.GraphicsDevice.Viewport.Height); _renderer = new Renderer_XNA(spriteBatch); _theGame.LoadContent(new ContentManager_XNA() { Content = Content }); }