Fixed bug with tile cache not updating after map change

This commit is contained in:
Anuken
2017-07-22 20:23:11 -04:00
parent ed6b49788d
commit a05f63343c
20 changed files with 90 additions and 27 deletions

View File

@@ -33,7 +33,6 @@ public class Renderer{
//render the entire map
if(caches.size() == 0){
for(int cx = 0; cx < chunksx; cx ++){
for(int cy = 0; cy < chunksy; cy ++){
Caches.begin(1600);
@@ -102,6 +101,13 @@ public class Renderer{
}
}
public static void clearTiles(){
for(Cache cache : caches.values())
cache.dispose();
caches.clear();
}
public static void renderPixelOverlay(){
if(player.recipe != null && (!ui.hasMouse() || android)){