88 |
|
|
89 |
private final Level[] levels; |
private final Level[] levels; |
90 |
|
|
91 |
|
public final float origWidth, origHeight; |
92 |
|
|
93 |
/** Open (if not already open) and return the ZipFile. |
/** Open (if not already open) and return the ZipFile. |
94 |
*/ |
*/ |
95 |
synchronized private ZipFile getZipFile() throws IOException { |
synchronized private ZipFile getZipFile() throws IOException { |
473 |
if(e == null) throw new IOException("Invalid format: no texformat in mipzip"); |
if(e == null) throw new IOException("Invalid format: no texformat in mipzip"); |
474 |
this.texFormat = e.getComment(); |
this.texFormat = e.getComment(); |
475 |
this.compressedFormat = texFormat.indexOf("COMPRESS") != -1; |
this.compressedFormat = texFormat.indexOf("COMPRESS") != -1; |
476 |
|
|
477 |
|
e = f.getEntry("origsize"); |
478 |
|
if(e == null) throw new IOException("Invalid format: no origsize in mipzip"); |
479 |
|
String origSize = e.getComment(); |
480 |
|
|
481 |
|
{ |
482 |
|
int i = origSize.indexOf('x'); |
483 |
|
if(i < 0) throw new IOException("Invalid size string"); |
484 |
|
origWidth = Float.parseFloat(origSize.substring(0,i)); |
485 |
|
origHeight = Float.parseFloat(origSize.substring(i+1)); |
486 |
|
} |
487 |
|
|
488 |
|
|
489 |
ArrayList l = new ArrayList(); |
ArrayList l = new ArrayList(); |
490 |
for(int i=0; i<100; i++) { |
for(int i=0; i<100; i++) { |
491 |
e = f.getEntry(""+i); |
e = f.getEntry(""+i); |