Jump to content

Search the Community

Showing results for tags 'comile'.



More search options

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • RuneLocus
    • News & Announcements
    • Information Booth
    • Website Support
    • Introductions
    • Chat
    • Forum Games
  • RuneScape Development
    • RSPS General
    • RuneScape Private Server (RS2)
    • RuneScape Private Server (503+)
    • RuneScape Private Server (EoC 742+)
  • Other
    • Digital Art
    • Gaming
    • Webdevelopment
    • Computers
  • Marketplace
    • RuneScape Market
    • RSPS Market
    • Others Market
    • Freelance Middleman Services
  • Super Secret Club's Topics

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


Found 1 result

  1. I need to compile or run this code to dump music [CODE]import java.io.*; import java.util.zip.GZIPInputStream; public class MidiDumper { private static final String folder = "C:\\WINDOWS\\.file_store_32\\runescape\\"; private static final String savefolder = "C:\\save\\"; private static DataInputStream cache; public static void main(String args[]) throws Exception { File f = new File(folder + "main_file_cache.dat2"); byte bytes[] = new byte[(int) f.length()]; new FileInputStream(f).read(bytes); BufferedInputStream cache2 = new BufferedInputStream(new ByteArrayInputStream(bytes)); cache = new DataInputStream(cache2); cache.mark(bytes.length); DataInputStream midi = new DataInputStream(new FileInputStream(folder + "main_file_cache.idx11")); int count = 0; while (midi.available() > 0) { int length = (midi.readUnsignedByte() << 16) + (midi.readUnsignedByte() << 8) + midi.readUnsignedByte(); int offset = (midi.readUnsignedByte() << 16) + (midi.readUnsignedByte() << 8) + midi.readUnsignedByte(); byte[] b = readFile(length, offset); if(b == null) continue; File file = new File(savefolder + "midi" + (++count) + ".mid"); if(!file.exists()) if(!file.createNewFile()) continue; RandomAccessFile raf = new RandomAccessFile(file, "rw"); raf.write(b); raf.close(); } } public static byte[] getParody(int index) throws Exception { cache.reset(); byte buffer[] = new byte[520]; int jump = index * 520; cache.skipBytes(jump); cache.readFully(buffer); return buffer; } public static byte[] readFile(int size, int offset) throws Exception { byte b[] = getFile(size, offset); int length = ((b[5] & 0xff) << 24) + ((b[6] & 0xff) << 16) + ((b[7] & 0xff) << 8) + b[8]; if(length > 0) { if(b[0] == 2) { GZIPInputStream d = new GZIPInputStream(new ByteArrayInputStream(b, 9, length)); byte z[] = new byte[b.length]; int i = d.read(z); byte x[] = new byte[i]; System.arraycopy(z, 0, x, 0, i); return x; } else if(b[0] == 1) { System.out.println("Fu**in' sh**, it's not a midi!!!"); return null; } return b; } return null; } public static byte[] getFile(int size, int offset) throws Exception { if(offset <= 0) return null; byte outfile[] = new byte[size]; int bits = offset; int length = 0; while(true) { byte buffer[] = getParody(bits); if(buffer == null) return null; bits = ((buffer[4] & 0xff) << 16) + ((buffer[5] & 0xff) << 8) + (buffer[6] & 0xff); if(size - length - 8 > 512) { System.arraycopy(buffer, 8, outfile, length, 512); } else { System.arraycopy(buffer, 8, outfile, length, size - length - 8); return outfile; } length += 512; } } }[/CODE] But i dont know how.
×