Question: I'm currently running and developing game server, but thing is i can't run it on eclipse, but i can run the server with run.bat
I'm getting the error: 

```
Exception in thread "main" java.lang.ArrayIndexOutOfBoundsException: 3
at com.rs.ServerLauncher.main(ServerLauncher.java:75)

```

relevant code

```
public static void main(String[] args) throws Exception {
                if (args.length < 3) {
                        System.out.println("USE: guimode(boolean) debug(boolean) hosted(boolean) port(integer)");
                        return;
                }
                Settings.ECONOMY_MODE = Boolean.parseBoolean(args[2]);
                Settings.DEBUG = Boolean.parseBoolean(args[1]);
                Settings.SERVER_PORT = Integer.parseInt(args[3]); 
.....
.....
.....

```

complete code -My ServerLauncher class: <http://pastebin.com/k1XZbqva>

Thanks in advance.

Answer: 
There is your error, arrays are starting with the index 0 and not with the index 1

```
Settings.ECONOMY_MODE = Boolean.parseBoolean(args[2]);
Settings.DEBUG = Boolean.parseBoolean(args[1]);
Settings.SERVER_PORT = Integer.parseInt(args[3]);

```
It's like the error says, the args array does not have a fourth(args[3]) element. Remember that arrays start with index 0.