Many various bugfixes, more aggressive memory optimization

This commit is contained in:
Anuken
2018-06-26 11:15:23 -04:00
parent 8ec9d95cd2
commit 7a049d64d8
39 changed files with 189 additions and 87 deletions
+1 -1
View File
@@ -42,7 +42,7 @@ public class MapIO {
Block floor = Block.getByID(marker.floor);
Block wall = Block.getByID(marker.wall);
int wallc = ColorMapper.getBlockColor(wall);
if(wallc == 0 && (wall.update || wall.solid || wall.breakable)) wallc = Team.values()[marker.team].intColor;
if(wallc == 0 && (wall.update || wall.solid || wall.breakable)) wallc = Team.all[marker.team].intColor;
wallc = wallc == 0 ? ColorMapper.getBlockColor(floor) : wallc;
if(marker.elevation > 0){
float scaling = 1f + marker.elevation/8f;
+1 -1
View File
@@ -141,7 +141,7 @@ public class TypeIO {
@ReadClass(Team.class)
public static Team readTeam(ByteBuffer buffer){
return Team.values()[buffer.get()];
return Team.all[buffer.get()];
}
@WriteClass(AdminAction.class)
@@ -115,9 +115,9 @@ public class Save16 extends SaveFileVersion {
byte team = Bits.getLeftByte(tr);
byte rotation = Bits.getRightByte(tr);
Team t = Team.values()[team];
Team t = Team.all[team];
tile.setTeam(Team.values()[team]);
tile.setTeam(Team.all[team]);
tile.entity.health = health;
tile.setRotation(rotation);