Skip to content

Commit 5f79798

Browse files
committed
select 0, 0 tile on map load
1 parent a48c1ee commit 5f79798

1 file changed

Lines changed: 9 additions & 2 deletions

File tree

FF4MapEdit/MainWindow.xaml.cs

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -147,6 +147,9 @@ private void LoadWorldMap(MapType mapType)
147147
LoadWorldMapTiles();
148148

149149
SpaceUsed = _map.CompressedSize;
150+
151+
SelectTile(0, 0);
152+
TilePropertiesGrid.Visibility = Visibility.Visible;
150153
}
151154

152155
private void LoadWorldMapTileset()
@@ -212,12 +215,16 @@ private void Tileset_MouseLeftButtonUp(object sender, MouseButtonEventArgs e)
212215
return;
213216
}
214217

215-
_selectedTile = 16*y + x;
218+
SelectTile(x, y);
219+
}
220+
221+
private void SelectTile(int x, int y)
222+
{
223+
_selectedTile = 16 * y + x;
216224

217225
HighlightSelectedTile(x, y);
218226

219227
CheckTilePropertyBoxes();
220-
TilePropertiesGrid.Visibility = Visibility.Visible;
221228
}
222229

223230
private void HighlightSelectedTile(int x, int y)

0 commit comments

Comments
 (0)