Skip to content

Commit

Permalink
Shortcut for clear cache
Browse files Browse the repository at this point in the history
  • Loading branch information
kaczy93 committed Dec 31, 2023
1 parent 3cb0611 commit 376d7ac
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
4 changes: 4 additions & 0 deletions CentrED/Map/MapManager.cs
Original file line number Diff line number Diff line change
Expand Up @@ -525,6 +525,10 @@ public void Update(GameTime gameTime, bool isActive, bool processMouse, bool pro
{
Client.Undo();
}
if((keyState.IsKeyDown(Keys.LeftControl) || keyState.IsKeyDown(Keys.RightControl)) && keyState.IsKeyDown(Keys.R) && _prevKeyState.IsKeyUp(Keys.R))
{
Reset();
}
_prevKeyState = keyState;
}

Expand Down
2 changes: 1 addition & 1 deletion CentrED/UI/UIManager.cs
Original file line number Diff line number Diff line change
Expand Up @@ -309,7 +309,7 @@ private void DrawMainMenu()
{
_resetLayout = true;
}
if (ImGui.MenuItem("Clear cache"))
if (ImGui.MenuItem("Clear cache", "CTRL+R"))
{
CEDGame.MapManager.Reset();
}
Expand Down

0 comments on commit 376d7ac

Please sign in to comment.