Skip to content

Commit

Permalink
feat: add storage controller page caching - may improve GUI FPS
Browse files Browse the repository at this point in the history
Closes #1038
  • Loading branch information
klikli-dev committed Jan 21, 2024
1 parent 333c3ec commit 645176b
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -543,8 +543,8 @@ protected void drawItems(GuiGraphics guiGraphics, float partialTicks, int mouseX
var changedPage = this.previousPage != this.currentPage;
this.previousPage = this.currentPage;

var changedStacksToDisplay = this.lastCachedStacksToDisplayCount != this.cachedStacksToDisplay.size();
this.lastCachedStacksToDisplayCount = this.cachedStacksToDisplay.size();
var changedStacksToDisplay = this.lastCachedStacksToDisplayCount != stacksToDisplay.size();
this.lastCachedStacksToDisplayCount = stacksToDisplay.size();

if(changedPage || changedStacksToDisplay){
this.sortItemStacks(stacksToDisplay);
Expand Down

0 comments on commit 645176b

Please sign in to comment.