Example #1
0
        public void LoadContent(bool reload)
        {
            if (!Renderer.staticReloadBound)
            {
                Main m = this.main;
                new CommandBinding(m.ReloadedContent, delegate()
                {
                    Renderer.reload(m);
                });
                Renderer.staticReloadBound = true;
                Renderer.reload(m);
            }

            if (this.spriteBatch != null)
            {
                this.spriteBatch.Dispose();
            }
            this.spriteBatch = new SpriteBatch(this.main.GraphicsDevice);

            // Initialize our buffers
            this.ReallocateBuffers(this.screenSize);
        }