Merge remote-tracking branch 'origin/master'
This commit is contained in:
commit
1c71efbff7
@ -86,6 +86,7 @@ public class ItemMapRenderer extends MapRenderer
|
||||
{
|
||||
boolean colorAll = scale > 0;
|
||||
Color clanColor = null;
|
||||
Color clanColor2 = null;
|
||||
|
||||
if (owningClan == clan)
|
||||
{
|
||||
@ -99,13 +100,25 @@ public class ItemMapRenderer extends MapRenderer
|
||||
{
|
||||
colorAll = false;
|
||||
|
||||
if (owningClan.getName().equals("Shops") || owningClan.getName().equals("Spawn"))
|
||||
if (owningClan.getName().equals("Shops"))
|
||||
{
|
||||
clanColor = Color.WHITE;
|
||||
|
||||
if (relation == ClansUtility.ClanRelation.SAFE)
|
||||
clanColor2 = Color.CYAN;
|
||||
}
|
||||
else if (owningClan.getName().equals("Spawn"))
|
||||
{
|
||||
clanColor = Color.WHITE;
|
||||
}
|
||||
if (owningClan.getName().equals("Fields"))
|
||||
{
|
||||
clanColor = Color.WHITE;
|
||||
clanColor2 = Color.ORANGE;
|
||||
}
|
||||
else
|
||||
{
|
||||
clanColor = Color.GRAY;
|
||||
clanColor = Color.LIGHT_GRAY;
|
||||
}
|
||||
}
|
||||
else if (relation == ClansUtility.ClanRelation.WAR_LOSING)
|
||||
@ -138,34 +151,42 @@ public class ItemMapRenderer extends MapRenderer
|
||||
int chunkX1 = (int) Math.floor(blockX / 16D);
|
||||
int chunkZ1 = (int) Math.floor(blockZ / 16D);
|
||||
|
||||
//Checkin'
|
||||
boolean checker = (mapX + (mapZ % 3)) % 3 == 0;
|
||||
Color drawColor = clanColor;
|
||||
if (checker && clanColor2 == null)
|
||||
drawColor = clanColor2;
|
||||
|
||||
//Inside
|
||||
if (colorAll ||
|
||||
|
||||
((chunkBX == 0 || zoom == 13) &&
|
||||
((chunkBX == 0 || zoom == 13) &&
|
||||
|
||||
owningClan != _manager.getClansUtility().getOwner("world," + (chunkX1 - 1) + "," + chunkZ1))
|
||||
owningClan != _manager.getClansUtility().getOwner("world," + (chunkX1 - 1) + "," + chunkZ1))
|
||||
|
||||
|| ((chunkBZ == 0 || zoom == 13) &&
|
||||
|| ((chunkBZ == 0 || zoom == 13) &&
|
||||
|
||||
owningClan != _manager.getClansUtility().getOwner("world," + chunkX1 + "," + (chunkZ1 - 1)))
|
||||
owningClan != _manager.getClansUtility().getOwner("world," + chunkX1 + "," + (chunkZ1 - 1)))
|
||||
|
||||
|| ((chunkBX + zoom > 15 || zoom == 13) &&
|
||||
|| ((chunkBX + zoom > 15 || zoom == 13) &&
|
||||
|
||||
owningClan != _manager.getClansUtility().getOwner("world," + (chunkX1 + 1) + "," + chunkZ1))
|
||||
owningClan != _manager.getClansUtility().getOwner("world," + (chunkX1 + 1) + "," + chunkZ1))
|
||||
|
||||
|| ((chunkBZ + zoom > 15 || zoom == 13) &&
|
||||
|| ((chunkBZ + zoom > 15 || zoom == 13) &&
|
||||
|
||||
owningClan != _manager.getClansUtility().getOwner("world," + chunkX1 + "," + (chunkZ1 + 1))))
|
||||
owningClan != _manager.getClansUtility().getOwner("world," + chunkX1 + "," + (chunkZ1 + 1))))
|
||||
{
|
||||
Color cColor = MapPalette.getColor(color);
|
||||
double clans = colorAll ? 1 : 0.8;// 0.65;
|
||||
double base = 1 - clans;
|
||||
|
||||
int r = (int) ((cColor.getRed() * base) + (clanColor.getRed() * clans));
|
||||
int b = (int) ((cColor.getBlue() * base) + (clanColor.getBlue() * clans));
|
||||
int g = (int) ((cColor.getGreen() * base) + (clanColor.getGreen() * clans));
|
||||
int r = (int) ((cColor.getRed() * base) + (drawColor.getRed() * clans));
|
||||
int b = (int) ((cColor.getBlue() * base) + (drawColor.getBlue() * clans));
|
||||
int g = (int) ((cColor.getGreen() * base) + (drawColor.getGreen() * clans));
|
||||
|
||||
color = MapPalette.matchColor(r, g, b);
|
||||
}
|
||||
//Border
|
||||
else
|
||||
{
|
||||
Color cColor = MapPalette.getColor(color);
|
||||
@ -173,9 +194,9 @@ public class ItemMapRenderer extends MapRenderer
|
||||
double clans = 0.65;// 0.4;
|
||||
double base = 1 - clans;
|
||||
|
||||
int r = (int) ((cColor.getRed() * base) + (clanColor.getRed() * clans));
|
||||
int b = (int) ((cColor.getBlue() * base) + (clanColor.getBlue() * clans));
|
||||
int g = (int) ((cColor.getGreen() * base) + (clanColor.getGreen() * clans));
|
||||
int r = (int) ((cColor.getRed() * base) + (drawColor.getRed() * clans));
|
||||
int b = (int) ((cColor.getBlue() * base) + (drawColor.getBlue() * clans));
|
||||
int g = (int) ((cColor.getGreen() * base) + (drawColor.getGreen() * clans));
|
||||
|
||||
color = MapPalette.matchColor(r, g, b);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user