You are just setting a variable, you actually need to prevent the person from going past this if statement with a "return;"
|
I tried adding this to my rs2loginprotocoldecoder, but it didn't work. It's suppose to ban all of the ips that start with that.
Code:if (cl.connectedFrom.startsWith("11.11")) { returnCode = 4; }
You are just setting a variable, you actually need to prevent the person from going past this if statement with a "return;"
Like this?
if (cl.connectedFrom.startsWith("11.11")) {
returnCode = 4;
return;
}
I tried that and it didn't work.
Are you sure that you're actually making it into the if statement?.. because it's unlikely your IP starts with "11.11", anyways check what that variable is equal to anyways with a simpleright above itCode:System.out.println(c1.connectedFrom);
Are you sure that method is returning the IP? Try
I don't know what your revision is, I generally stick with 503+Code:for (int i = 1; i < 255; i++) { if (cl.connectedFrom.startsWith("11.11.i.i")) { returnCode = 4; return; } }
Edit :
If you're using PI, you could try adding this tutorial which is probably a better way to ban someone.
http://www.rune-server.org/runescape...d-banning.html
« Previous Thread | Next Thread » |
Thread Information |
Users Browsing this ThreadThere are currently 1 users browsing this thread. (0 members and 1 guests) |