Fixed crashes with team IDs above 127

This commit is contained in:
Anuken
2020-07-03 12:36:12 -04:00
parent 3772b04c6b
commit 843a8c3e56
18 changed files with 48 additions and 68 deletions
+1 -1
View File
@@ -631,7 +631,7 @@ public class Block extends UnlockableContent{
//load specific team regions
teamRegions = new TextureRegion[Team.all.length];
for(Team team : Team.all){
teamRegions[team.uid] = teamRegion.found() ? Core.atlas.find(name + "-team-" + team.name, teamRegion) : teamRegion;
teamRegions[team.id] = teamRegion.found() ? Core.atlas.find(name + "-team-" + team.name, teamRegion) : teamRegion;
}
}
+1 -1
View File
@@ -171,7 +171,7 @@ public class Tile implements Position, QuadTreeObject, Displayable{
return build == null ? y : build.tile.y;
}
public byte getTeamID(){
public int getTeamID(){
return team().id;
}