コード例 #1
0
        private void LoadTileEditor()
        {
            if (tileset.Tilesets_tiles[Layer] == null)
            {
                return;
            }
            switch (Layer)
            {
            case 2:     // layer 3
                if (TileEditor == null)
                {
                    TileEditor = new TileEditor(new Function(TileUpdate),
                                                this.tileset.Tilesets_tiles[Layer][mouseDownTile],
                                                tileset.GraphicsL3, paletteSet, 0x10);
                    TileEditor.FormClosing += new FormClosingEventHandler(editor_FormClosing);
                }
                else
                {
                    TileEditor.Reload(new Function(TileUpdate),
                                      this.tileset.Tilesets_tiles[Layer][mouseDownTile],
                                      tileset.GraphicsL3, paletteSet, 0x10);
                }
                break;

            default:
                if (TileEditor == null)
                {
                    TileEditor = new TileEditor(new Function(TileUpdate),
                                                this.tileset.Tilesets_tiles[Layer][mouseDownTile],
                                                tileset.Graphics, paletteSet, 0x20);
                    TileEditor.FormClosing += new FormClosingEventHandler(editor_FormClosing);
                }
                else
                {
                    TileEditor.Reload(new Function(TileUpdate),
                                      this.tileset.Tilesets_tiles[Layer][mouseDownTile],
                                      tileset.Graphics, paletteSet, 0x20);
                }
                break;
            }
        }
コード例 #2
0
 private void LoadTileEditor()
 {
     if (tileEditor == null)
     {
         tileEditor = new TileEditor(new Function(TileUpdate),
                                     tileset.Tileset_tiles[mouseDownTile], graphics,
                                     fontPalette, 0x20);
         tileEditor.FormClosing += new FormClosingEventHandler(editor_FormClosing);
     }
     else
     {
         tileEditor.Reload(new Function(TileUpdate),
                           tileset.Tileset_tiles[mouseDownTile], graphics,
                           fontPalette, 0x20);
     }
 }
コード例 #3
0
 private void LoadTileEditor()
 {
     if (tileEditor == null)
     {
         tileEditor = new TileEditor(new Function(TileUpdate),
                                     this.tileset.Tileset_tiles[mouseDownTile],
                                     tileset.Graphics, paletteSets[battlefield.PaletteSet], 0x20);
         tileEditor.FormClosing += new FormClosingEventHandler(editor_FormClosing);
     }
     else
     {
         tileEditor.Reload(new Function(TileUpdate),
                           this.tileset.Tileset_tiles[mouseDownTile],
                           tileset.Graphics, paletteSets[battlefield.PaletteSet], 0x20);
     }
 }
コード例 #4
0
 // editors
 public void LoadTileEditor()
 {
     if (tileEditor == null)
     {
         tileEditor = new TileEditor(new Function(TileUpdate),
                                     tileset.Tileset[mouseDownTile], tileset.Graphics,
                                     animation.PaletteSet, animation.Codec == 1 ? (byte)0x10 : (byte)0x20);
         tileEditor.FormClosing += new FormClosingEventHandler(editor_FormClosing);
     }
     else
     {
         tileEditor.Reload(new Function(TileUpdate),
                           this.tileset.Tileset[mouseDownTile], tileset.Graphics,
                           animation.PaletteSet, animation.Codec == 1 ? (byte)0x10 : (byte)0x20);
     }
 }