aboutsummaryrefslogtreecommitdiffstats
path: root/src/jake2/qcommon/qfiles.java
diff options
context:
space:
mode:
authorCarsten Weisse <[email protected]>2005-05-07 22:15:05 +0000
committerCarsten Weisse <[email protected]>2005-05-07 22:15:05 +0000
commit826dccd33770d6a84d20d3d9258c61d0474c5e7b (patch)
tree6e95b10fe40b714cfde7725858aa7abfce36d38c /src/jake2/qcommon/qfiles.java
parent6f3e2d41bd7d2fdbddb3c7f3e859feb5ed9381d2 (diff)
this reduces the memory footprint massive;
you can now run city3 with 90MB heap
Diffstat (limited to 'src/jake2/qcommon/qfiles.java')
-rw-r--r--src/jake2/qcommon/qfiles.java33
1 files changed, 26 insertions, 7 deletions
diff --git a/src/jake2/qcommon/qfiles.java b/src/jake2/qcommon/qfiles.java
index 8e524a5..8805ce9 100644
--- a/src/jake2/qcommon/qfiles.java
+++ b/src/jake2/qcommon/qfiles.java
@@ -2,7 +2,7 @@
* qfiles.java
* Copyright (C) 2003
*
- * $Id: qfiles.java,v 1.4 2004-07-09 06:50:50 hzi Exp $
+ * $Id: qfiles.java,v 1.5 2005-05-07 22:15:04 cawe Exp $
*/
/*
Copyright (C) 1997-2001 Id Software, Inc.
@@ -195,14 +195,33 @@ public class qfiles {
}
public static class dtrivertx_t {
- public int v[] = { 0, 0, 0 }; // byte 0..255 scaled byte to fit in frame mins/maxs
- public int lightnormalindex; // byte 0 .. 255;
+ private byte v0; // byte 0..255 scaled byte to fit in frame mins/maxs
+ private byte v1;
+ private byte v2;
+
+ private byte lightnormalindex; // byte 0 .. 255;
public dtrivertx_t(ByteBuffer b) {
- v[0] = b.get() & 0xff; // unsigned byte
- v[1] = b.get() & 0xff; // unsigned byte
- v[2] = b.get() & 0xff; // unsigned byte
- lightnormalindex = b.get() & 0xff; // unsigned byte
+ v0 = b.get(); // unsigned byte
+ v1 = b.get(); // unsigned byte
+ v2 = b.get(); // unsigned byte
+ lightnormalindex = b.get(); // unsigned byte
+ }
+
+ public final int v0() {
+ return v0 & 0xFF;
+ }
+
+ public final int v1() {
+ return v1 & 0xFF;
+ }
+
+ public final int v2() {
+ return v2 & 0xFF;
+ }
+
+ public final int lightnormalindex() {
+ return lightnormalindex & 0xFF;
}
}