-
-
Save Vulcanacht/d4d77dc87da3220ba6f3 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public static void main(String[] args) throws Exception { | |
int fileId = 4151; | |
if (args.length == 1) { | |
try { | |
fileId = Integer.parseInt(args[0]); | |
} catch (NumberFormatException e) { | |
} | |
} | |
RuneFS runefs = new RuneFS(); | |
runefs.init("test_data"); | |
Js5 configClient = runefs.getJs5Client(JS5Indices.CONFIGURATION.getStoreId()); | |
byte[] data = configClient.getFile(JS5Configuration.OBJTYPE.getGroupid(), fileId); | |
if (data != null) { | |
ObjType type = new ObjType(); | |
type.decode(new Buffer(data)); | |
System.out.println("Name: " + type.getName()); | |
System.out.println("Cost: " + type.getCost()); | |
} | |
runefs.cleanup(); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment