Jump to content
  • 0
manpaint55

(823 deob) how to fix this error

Question

Java HotSpot(TM) Client VM warning: Using incremental CMS is deprecated and will
likely be removed in a future release
Error: client.init:21752 sun.reflect.NativeMethodAccessorImpl.invoke0 sun.reflec
t.NativeMethodAccessorImpl.invoke sun.reflect.DelegatingMethodAccessorImpl.invok
e java.lang.reflect.Method.invoke RS3Applet.startClient:69 RS3Applet.main:56 | j
ava.lang.RuntimeException |
java.lang.reflect.InvocationTargetException
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at RS3Applet.startClient(RS3Applet.java:69)
at RS3Applet.main(RS3Applet.java:56)
Caused by: java.lang.NumberFormatException: For input string: "true"
at java.lang.NumberFormatException.forInputString(Unknown Source)
at java.lang.Integer.parseInt(Unknown Source)
at java.lang.Integer.parseInt(Unknown Source)
at client.init(client.java:21680)
... 6 more


code in run .bat

[MENTION=7458]echo[/MENTION] off
"C:\Program Files (x86)\Java\jre1.8.0_40\bin\java.exe" -Xmx256m -Xss2m -Dsun.java2d.noddraw=true -XX:+CreateMinidumpOnCrash -XX:CompileThreshold=1500 -Xincgc -XX:+UseConcMarkSweepGC -XX:+UseParNewGC -cp bin;./clientlibs.jar; RS3Applet
pause

Share this post


Link to post
Share on other sites

3 answers to this question

Recommended Posts

  • 0
Tried compiling with eclipse? Might make a difference probably not but worth a shot.

Share this post


Link to post
Share on other sites
  • 0
There is an error in RS3Applet:
[code]
Caused by: java.lang.NumberFormatException: For input string: "true"
at java.lang.NumberFormatException.forInputString(Unk nown Source)
at java.lang.Integer.parseInt(Unknown Source)
at java.lang.Integer.parseInt(Unknown Source)
at client.init(client.java:21680)
[/code]

The CMS is just a warning and does not affect the client.

Share this post


Link to post
Share on other sites
  • 0
But the game not loading

edit: the two RS3Apelet code

[CODE]package rs2.client;

import java.applet.Applet;
import java.applet.AppletStub;
import java.awt.Dimension;
import java.io.BufferedReader;
import java.io.FileNotFoundException;
import java.io.FileReader;
import java.io.IOException;
import java.net.MalformedURLException;
import java.net.URL;
import java.util.Properties;

import javax.swing.JFrame;

/**
* An Applet used for loading the RS3 Client.
*/
public class RS3Applet extends Applet implements AppletStub {

/**
* An generated serial UID.
*/
private static final long serialVersionUID = 1670498001014004354L;

/**
* The parameters of the client.
*/
private Properties client_parameters = new Properties();

/**
* The current frame of the client application.
*/
public JFrame clientFrame = null;

/**
* Chooses the Host
*/
public static String Host = "http://world4.runescape.com";

/**
* The main entry point of the current application.
* [MENTION=75098]Para[/MENTION]m args The command line arguments.
*/
public static void main(String... args) {
RS3Applet rs3applet = new RS3Applet();
rs3applet.doFrame();
}

/**
* Performs the operations needed to show the client.
*/
private void doFrame() {
readParameters();
openFrame();
startClient();
clientFrame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
}

/**
* Starts the actual client.
*/
private void startClient() {
try {
client RS3Client = new client();
RS3Client.supplyApplet(this);
RS3Client.init();
RS3Client.start();
} catch(Exception e) {
e.printStackTrace();
}
}

/**
* Opens the actual frame application.
*/
private void openFrame() {
clientFrame = new JFrame("Jagex");
clientFrame.add(this);
clientFrame.setVisible(true);
clientFrame.setSize(800, 600);
}

/**
* Reads the parameters text file, and stores the parameters.
*/
[MENTION=19271]supp[/MENTION]ressWarnings("resource")
private void readParameters() {

}

/*
* (non-Javadoc)
* [MENTION=73428]see[/MENTION] java.applet.AppletStub#appletResize(int, int)
*/
[MENTION=15855]Over[/MENTION]ride
public void appletResize(int dimensionX, int dimensionY) {
super.resize(new Dimension(dimensionX, dimensionY));
}

/*
* (non-Javadoc)
* [MENTION=73428]see[/MENTION] java.applet.Applet#getParameter(java.lang.String)
*/
[MENTION=15855]Over[/MENTION]ride
public String getParameter(String paramName) {
return (String) client_parameters.get(paramName);
}

/*
* (non-Javadoc)
* [MENTION=73428]see[/MENTION] java.applet.Applet#getDocumentBase()
*/
[MENTION=15855]Over[/MENTION]ride
public URL getDocumentBase() {
try {
return new URL(Host);
} catch (MalformedURLException e) {
e.printStackTrace();
}
return null;
}

/*
* (non-Javadoc)
* [MENTION=73428]see[/MENTION] java.applet.Applet#getCodeBase()
*/
[MENTION=15855]Over[/MENTION]ride
public URL getCodeBase() {
try {
return new URL(Host);
} catch (MalformedURLException e) {
e.printStackTrace();
}
return null;
}
}
[/CODE]

the second

[CODE]import java.applet.Applet;
import java.applet.AppletStub;
import java.awt.Dimension;
import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.net.MalformedURLException;
import java.net.URL;
import java.util.ArrayList;
import java.util.Properties;

import javax.swing.JFrame;

/**
* An Applet used for loading the RS3 Client.
* @author Im Frizzy <Skype:kfriz1998>
*/
public class RS3Applet extends Applet implements AppletStub {

/**
* An generated serial UID.
*/
private static final long serialVersionUID = 1670498001014004354L;

/**
* Connecting to Rs or a Rsps
*/
public static boolean RSPS = false;

/**
* Chooses ip based on if Rs or Rsps
*/
public static String Host = RSPS ? "http://127.0.0.1" : "http://world4.runescape.com";

/**
* The parameters of the client.
*/
private Properties client_parameters = new Properties();

/**
* The current frame of the client application.
*/
public JFrame clientFrame = null;

/**
* The main entry point of the current application.
* [MENTION=75098]Para[/MENTION]m args The command line arguments.
* @throws IOException
* @throws MalformedURLException
*/
public static void main(String... args) throws MalformedURLException, IOException {
RS3Applet rs3applet = new RS3Applet();

rs3applet.readParameters();
rs3applet.openFrame();
rs3applet.startClient();
rs3applet.clientFrame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
}

/**
* Starts the actual client.
*/
private void startClient() {
try {
Class<?> client_class = Class.forName("client");

Object v_client = client_class.getConstructor().newInstance();
client_class.getSuperclass().getMethod("supplyApplet", Applet.class).invoke(v_client, this);
client_class.getMethod("init").invoke(v_client);
client_class.getMethod("start").invoke(v_client);
} catch(Exception e) {
e.printStackTrace();
}
}

/**
* Opens the actual frame application.
*/
private void openFrame() {
clientFrame = new JFrame("823 Deob");
clientFrame.add(this);
clientFrame.setVisible(true);
clientFrame.setSize(800, 600);
}

/**
* Reads the parameters text file, and stores the parameters.
* @throws IOException
* @throws MalformedURLException
*/
private void readParameters() throws MalformedURLException, IOException {
if (!RSPS) {
for (String line : fetchPageDetails()) {
if (line.contains("<param name=")) {
String key = line.split("<param name=\"")[1].split("\" ")[0];
String value = line.split("value=\"")[1].split("\">'")[0];
if (value.isEmpty())
value = "";
client_parameters.put(key, value);

}
}
} else {

}
}

/*
* (non-Javadoc)
* [MENTION=73428]see[/MENTION] java.applet.AppletStub#appletResize(int, int)
*/
[MENTION=15855]Over[/MENTION]ride
public void appletResize(int dimensionX, int dimensionY) {
super.resize(new Dimension(dimensionX, dimensionY));
}

/*
* (non-Javadoc)
* [MENTION=73428]see[/MENTION] java.applet.Applet#getParameter(java.lang.String)
*/
[MENTION=15855]Over[/MENTION]ride
public String getParameter(String paramName) {
return (String) client_parameters.get(paramName);
}

/*
* (non-Javadoc)
* [MENTION=73428]see[/MENTION] java.applet.Applet#getDocumentBase()
*/
[MENTION=15855]Over[/MENTION]ride
public URL getDocumentBase() {
try {
return new URL(Host);
} catch (MalformedURLException e) {
e.printStackTrace();
}
return null;
}

/*
* (non-Javadoc)
* [MENTION=73428]see[/MENTION] java.applet.Applet#getCodeBase()
*/
[MENTION=15855]Over[/MENTION]ride
public URL getCodeBase() {
try {
return new URL(Host);
} catch (MalformedURLException e) {
e.printStackTrace();
}
return null;
}

/**
* Fetches the current parameters from the specified address
* [MENTION=184045]return[/MENTION]
* @throws MalformedURLException
* @throws IOException
*/
public static ArrayList<String> fetchPageDetails() throws MalformedURLException, IOException {
ArrayList<String> pageSource = new ArrayList<String>();
BufferedReader reader = new BufferedReader(new InputStreamReader(new URL("http://world2.runescape.com").openStream()));
String line;
while ((line = reader.readLine()) != null)
pageSource.add(line);
reader.close();
return pageSource;
}

}
[/CODE] Edited by manpaint55

Share this post


Link to post
Share on other sites

×