private void animatedTIlesetToolStripMenuItem_Click(object sender, EventArgs e)
        {
            FormNewAnimatedTileset frm = new FormNewAnimatedTileset();

            frm.ShowDialog();

            if (frm.Tileset == null)
            {
                return;
            }

            animatedSetData = frm.Tileset;

            try
            {
                GDIImage image = (GDIImage)GDIBitmap.FromFile(animatedSetData.TilesetImageName);

                pbAnimatedSet.Image = image;

                Stream stream = new FileStream(animatedSetData.TilesetImageName, FileMode.Open,
                                               FileAccess.Read);

                Texture2D texture = Texture2D.FromStream(GraphicsDevice, stream);
                animatedSet = new AnimatedTileset(
                    texture,
                    animatedSetData.FramesAcross,
                    animatedSetData.TilesHigh,
                    animatedSetData.TileWidthInPixels,
                    animatedSetData.TileHeightInPixels);

                if (map != null)
                {
                    map.AddAnimatedTileset(animatedSet);
                }
                sbAnimatedTile.Maximum   = 0;
                chkPaintAnimated.Enabled = true;

                stream.Close();
                stream.Dispose();
            }
            catch (Exception ex)
            {
                MessageBox.Show("Error reading file.\n" + ex.Message, "Error reading image");
                return;
            }
        }