Thread: Model dumper OutOfMemoryError

Results 1 to 3 of 3
  1. #1 Model dumper OutOfMemoryError 
    EXALTED

    Join Date
    Nov 2012
    Posts
    396
    Thanks given
    35
    Thanks received
    33
    Rep Power
    5
    I'm trying to dump models from an 861 cache and I'm getting this error:

    Code:
    Exception in thread "main" java.lang.OutOfMemoryError: Requested array size exce
    eds VM limit
            at com.alex.store.ReferenceTable.decodeHeader(ReferenceTable.java:192)
            at com.alex.store.ReferenceTable.<init>(ReferenceTable.java:26)
            at com.alex.store.Index.<init>(Index.java:28)
            at com.alex.store.Store.<init>(Store.java:38)
            at com.alex.store.Store.<init>(Store.java:27)
            at com.rs.tools.ModelDumper.main(ModelDumper.java:14)
    Here's the model dumper script I'm using:

    Code:
    package com.rs.tools;
    
    import java.io.FileOutputStream;
    import java.io.IOException;
    import java.io.OutputStream;
    
    import com.alex.store.Index;
    import com.alex.store.Store;
    import com.rs.cache.Cache;
    
    public class ModelDumper {
    
    	public static void main(String[] args) throws IOException {
    		Cache.STORE = new Store(
    				"C:/Users/4545/Desktop/data861/",
    				false);
    		Index index = Cache.STORE.getIndexes()[7];
    		System.out.println(index.getLastArchiveId());
    		for (int i = 0; i < index.getLastArchiveId(); i++) {
    			byte[] data = index.getFile(i);
    			if (data == null)
    				continue;
    			// if(!(data[data.length + -1] == -1 && data[-2 + data.length] ==
    			// -1))
    			// if((data[-1 + data.length] ^ 0xffffffff) != 0 || data[-2 +
    			// data.length] != -1)
    			// System.out.println(i);
    			writeFile(data, "C:/Users/4545/Desktop/861models/" + i + ".dat");
    		}
    
    	}
    
    	public static void writeFile(byte[] data, String fileName) throws IOException {
    		OutputStream out = new FileOutputStream(fileName);
    		out.write(data);
    		out.close();
    	}
    
    }
    Any help would be greatly appreciated, I tried searching for another model dumper but the two threads I found had broken links.

    Edit: Thought I might add that dumping models from the OSRS cache works
    Reply With Quote  
     

  2. #2  
    Contributor

    clem585's Avatar
    Join Date
    Sep 2013
    Posts
    3,556
    Thanks given
    652
    Thanks received
    640
    Rep Power
    358
    Quote Originally Posted by databomb View Post
    I'm trying to dump models from an 861 cache and I'm getting this error:

    Code:
    Exception in thread "main" java.lang.OutOfMemoryError: Requested array size exce
    eds VM limit
            at com.alex.store.ReferenceTable.decodeHeader(ReferenceTable.java:192)
            at com.alex.store.ReferenceTable.<init>(ReferenceTable.java:26)
            at com.alex.store.Index.<init>(Index.java:28)
            at com.alex.store.Store.<init>(Store.java:38)
            at com.alex.store.Store.<init>(Store.java:27)
            at com.rs.tools.ModelDumper.main(ModelDumper.java:14)
    Here's the model dumper script I'm using:

    Code:
    package com.rs.tools;
    
    import java.io.FileOutputStream;
    import java.io.IOException;
    import java.io.OutputStream;
    
    import com.alex.store.Index;
    import com.alex.store.Store;
    import com.rs.cache.Cache;
    
    public class ModelDumper {
    
    	public static void main(String[] args) throws IOException {
    		Cache.STORE = new Store(
    				"C:/Users/4545/Desktop/data861/",
    				false);
    		Index index = Cache.STORE.getIndexes()[7];
    		System.out.println(index.getLastArchiveId());
    		for (int i = 0; i < index.getLastArchiveId(); i++) {
    			byte[] data = index.getFile(i);
    			if (data == null)
    				continue;
    			// if(!(data[data.length + -1] == -1 && data[-2 + data.length] ==
    			// -1))
    			// if((data[-1 + data.length] ^ 0xffffffff) != 0 || data[-2 +
    			// data.length] != -1)
    			// System.out.println(i);
    			writeFile(data, "C:/Users/4545/Desktop/861models/" + i + ".dat");
    		}
    
    	}
    
    	public static void writeFile(byte[] data, String fileName) throws IOException {
    		OutputStream out = new FileOutputStream(fileName);
    		out.write(data);
    		out.close();
    	}
    
    }
    Any help would be greatly appreciated, I tried searching for another model dumper but the two threads I found had broken links.

    Edit: Thought I might add that dumping models from the OSRS cache works
    You need to update your reference table. Just use the one from the matrix 838 release.
    Project thread
    [Only registered and activated users can see links. ]
    Reply With Quote  
     

  3. Thankful user:


  4. #3  
    EXALTED

    Join Date
    Nov 2012
    Posts
    396
    Thanks given
    35
    Thanks received
    33
    Rep Power
    5
    Thank you!
    Reply With Quote  
     


Thread Information
Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)


User Tag List

Similar Threads

  1. Runescape Model Dumper
    By Apfelsuchti in forum Requests
    Replies: 0
    Last Post: 11-19-2010, 05:27 PM
  2. 484 model dump / 484 model dumper
    By jordan641 in forum Requests
    Replies: 1
    Last Post: 05-16-2010, 07:35 AM
  3. Model Dumper / viewer
    By Pitbull in forum Requests
    Replies: 4
    Last Post: 09-25-2008, 11:51 PM
  4. [REQ] Need a model dumper
    By Elid in forum Models
    Replies: 3
    Last Post: 06-01-2008, 11:26 PM
Posting Permissions
  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •