mirror of
https://github.com/MinecraftForge/MinecraftForge.git
synced 2026-11-12 16:27:47 +00:00
fixed NPE during loading of B3D models without textures/brushes.
changed default B3D color to have full opacity.
This commit is contained in:
1 parent
f0d96b7c50
commit
9e90febd37
2 files changed
+4
-3
No files matched your search
@@ -498,7 +498,7 @@ public class B3DLoader implements ICustomModelLoader
|
||||
}
|
||||
else
|
||||
{
|
||||
put(e, 1, 1, 1, 0);
|
||||
put(e, 1, 1, 1, 1);
|
||||
}
|
||||
break;
|
||||
case UV:
|
||||
|
||||
@@ -9,6 +9,7 @@ import java.nio.channels.FileChannel;
|
||||
import java.util.ArrayDeque;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Arrays;
|
||||
import java.util.Collections;
|
||||
import java.util.Deque;
|
||||
import java.util.HashMap;
|
||||
import java.util.HashSet;
|
||||
@@ -187,8 +188,8 @@ public class B3DModel
|
||||
throw new IOException("Unsupported major model version: " + ((float)version / 100));
|
||||
if(version % 100 > this.version % 100)
|
||||
logger.warn(String.format("Minor version differnce in model: ", ((float)version / 100)));
|
||||
List<Texture> textures = null;
|
||||
List<Brush> brushes = null;
|
||||
List<Texture> textures = Collections.EMPTY_LIST;
|
||||
List<Brush> brushes = Collections.EMPTY_LIST;
|
||||
Node<?> root = null;
|
||||
while(buf.hasRemaining())
|
||||
{
|
||||
|
||||
Reference in new issue
Block a user