Update core + remove Manifold from core + remove awt.Colors

This commit is contained in:
tom lee
2022-03-21 15:16:37 +08:00
parent aa86381b80
commit 8351c58d7b
5 changed files with 22 additions and 30 deletions
+8 -1
View File
@@ -180,10 +180,17 @@ allprojects { p ->
// def excapedMCVersion = rootProject.minecraft_version.replace(".", "_")
// options.compilerArgs += ['-Xplugin:Manifold', "-AMC_VERSION_${excapedMCVersion}"]
//
options.compilerArgs += ['-Xplugin:Manifold']
//options.compilerArgs += ['-deprecation']
//options.compilerArgs += ['-verbose']
//options.compilerArgs += ['-Xlint:unchecked']
//options.compilerArgs += ['-Xdiags:verbose']
//options.compilerArgs += ['-Xprint']
//options.compilerArgs += ['-XprintProcessorInfo']
//options.compilerArgs += ['-XprintRounds']
// println options.compilerArgs
if (p != project(":core")) {
options.compilerArgs += ['-Xplugin:Manifold']
options.release = rootProject.java_version as Integer
}
}
@@ -187,7 +187,7 @@ public class MinecraftClientWrapper implements IMinecraftClientWrapper
{
if (lightMap == null)
{
sendChatMessage("new");
//sendChatMessage("new");
// make sure the lightMap is up-to-date
getCurrentLightMap();
}
@@ -195,23 +195,6 @@ public class MinecraftClientWrapper implements IMinecraftClientWrapper
return lightMap.getPixelRGBA(blockLight, skyLight);
}
/**
* Returns the Color at the given pixel coordinates
* from the current lightmap.
* @param blockLight x location in texture space
* @param skyLight z location in texture space
*/
@Override
public Color getColorFromLightMap(int blockLight, int skyLight) {
if (lightMap == null) {
// make sure the lightMap is up-to-date
getCurrentLightMap();
}
return LodUtil.intToColor(lightMap.getPixelRGBA(blockLight, skyLight));
}
//=============//
@@ -235,7 +235,7 @@ public class MinecraftRenderWrapper implements IMinecraftRenderWrapper
// this could probably be kept as a int, but
// it is easier to test and see the colors when debugging this way.
// When creating a new release this should be changed to the int version.
Color c = LodUtil.intToColor(lightMap.getLightValue(u, v));
int col = lightMap.getLightValue(u, v);
// these should both create a totally white image
// int col =
@@ -245,12 +245,12 @@ public class MinecraftRenderWrapper implements IMinecraftRenderWrapper
// (0b11111111 << 8) + // green
// (0b11111111 << 16) + // blue
// (0b11111111 << 24); // blue
int col =
((c.getRed() & 0xFF) << 16) | // blue
((c.getGreen() & 0xFF) << 8) | // green
((c.getBlue() & 0xFF)) | // red
((c.getAlpha() & 0xFF) << 24); // alpha
// int col =
// ((c.getRed() & 0xFF) << 16) | // blue
// ((c.getGreen() & 0xFF) << 8) | // green
// ((c.getBlue() & 0xFF)) | // red
// ((c.getAlpha() & 0xFF) << 24); // alpha
// 2D array stored in a 1D array.
// Thank you Tim from College ;)
@@ -110,9 +110,11 @@ public class BiomeWrapper implements IBiomeWrapper
case SAVANNA:
case SWAMP:
default:
Color tmp = LodUtil.intToColor(biome.getGrassColor(x, z));
tmp = tmp.darker();
colorInt = LodUtil.colorToInt(tmp);
colorInt = biome.getGrassColor(x,z);
//FIXME: Repair what James did - LeeTom
// Color tmp = LodUtil.intToColor(biome.getGrassColor(x, z));
// tmp = tmp.darker();
// colorInt = LodUtil.colorToInt(tmp);
break;
}
+1 -1
Submodule core updated: 4f2bf9b834...ca625f9f8b