aboutsummaryrefslogtreecommitdiff
path: root/src/Java/gtPlusPlus/core/material
diff options
context:
space:
mode:
authorJordan Byrne <draknyte1@hotmail.com>2017-12-29 02:11:59 +1000
committerJordan Byrne <draknyte1@hotmail.com>2017-12-29 02:11:59 +1000
commit2625df7eb11b16c3aa55ff1099e821cb79d55a8b (patch)
tree9037781fe5bba80ad3fe08b930560d910745b3b1 /src/Java/gtPlusPlus/core/material
parent2092e4056de6c31594779679b80e7dbdb76a573c (diff)
downloadGT5-Unofficial-2625df7eb11b16c3aa55ff1099e821cb79d55a8b.tar.gz
GT5-Unofficial-2625df7eb11b16c3aa55ff1099e821cb79d55a8b.tar.bz2
GT5-Unofficial-2625df7eb11b16c3aa55ff1099e821cb79d55a8b.zip
% Localized the Plasma Death Message.
$ Fixed electrolyzer recipes for ore dust. $ Fixed bug with material generation system. + Added a custom renderer for the ore blocks. $ Fixed renderer issue where the background texture was incorrect.
Diffstat (limited to 'src/Java/gtPlusPlus/core/material')
-rw-r--r--src/Java/gtPlusPlus/core/material/Material.java17
1 files changed, 16 insertions, 1 deletions
diff --git a/src/Java/gtPlusPlus/core/material/Material.java b/src/Java/gtPlusPlus/core/material/Material.java
index 796d48b967..751a371bdb 100644
--- a/src/Java/gtPlusPlus/core/material/Material.java
+++ b/src/Java/gtPlusPlus/core/material/Material.java
@@ -104,7 +104,10 @@ public class Material {
try {
this.unlocalizedName = Utils.sanitizeString(materialName);
this.localizedName = materialName;
+
this.materialState = defaultState;
+ Logger.MATERIALS(this.getLocalizedName()+" is "+defaultState.name()+".");
+
this.RGBA = rgba;
this.vGenerateCells = generateCells;
@@ -332,12 +335,24 @@ public class Material {
return this.materialState;
}
- final public short[] getRGBA(){
+ final public short[] getRGB(){
if (this.RGBA != null) {
return this.RGBA;
}
return new short[] {255,0,0};
}
+
+ final public short[] getRGBA(){
+ if (this.RGBA != null) {
+ if (this.RGBA.length == 4){
+ return this.RGBA;
+ }
+ else {
+ return new short[]{this.RGBA[0], this.RGBA[1], this.RGBA[2], 0};
+ }
+ }
+ return new short[] {255,0,0, 0};
+ }
final public int getRgbAsHex(){