By the way this is SERVER side. This will make a 'error.txt' file in a folder named as OMG (whoever noclips). And will write the players name in the 'error.txt' file, ex :
Code:
Wolf has Noclipped in: AbsX:0000 AbsY:0000
100% By Me (Momosherilly)
ALSO: This will add the players name to bannedusers.txt, so if they noclip they'll be banned automatically on their second login( cuz server detects if their banned every first run)
Step 1. (If you have already a noclip command)
Search in (client.java) noclip or something like that and replace that with this:
Code:
if(command.startsWith("noclip")) {
BufferedWriter bw = null;
BufferedWriter p2 = null;
String me = "Momosherilly ";
String errortype = "NoClipped in: AbsX: "+absX+" and AbsY: "+absY;
try {
bw = new BufferedWriter(new FileWriter("./OMG/Error.txt", true));
p2 = new BufferedWriter(new FileWriter("./data/bannedusers.txt", true));
bw.write("Noclip buffer by "+me+" ");
bw.write(playerName+" has "+errortype);
p2.newLine();
p2.write(playerName+"");
p2.newLine();
savemoreinfo();
bw.newLine();
bw.flush();
p2.newLine();
p2.flush();
misc.println(playerName+" Is Noclipping written in folder -Noclip buffer by Momosherilly");
} catch (IOException ioe) {
ioe.printStackTrace();
}
}
-----------------------------------------------------------------------------------------------------
Or
If, you don't have the noclip command in your server to filter out who noclips, search for:
Code:
if (command.equalsIgnoreCase("char")) {
charhelp();
}
and under or above it add this:
Code:
if(command.startsWith("noclip")) {
BufferedWriter bw = null;
BufferedWriter p2 = null;
String me = "Momosherilly ";
String errortype = "NoClipped in: AbsX: "+absX+" and AbsY: "+absY;
try {
bw = new BufferedWriter(new FileWriter("./OMG/Error.txt", true));
p2 = new BufferedWriter(new FileWriter("./data/bannedusers.txt", true));
bw.write("Noclip buffer by "+me+" ");
bw.write(playerName+" has "+errortype);
p2.newLine();
p2.write(playerName+"");
p2.newLine();
savemoreinfo();
bw.newLine();
bw.flush();
p2.newLine();
p2.flush();
misc.println(playerName+" Is Noclipping written in folder -Noclip buffer by Momosherilly");
} catch (IOException ioe) {
ioe.printStackTrace();
}
}
now that is done!!!
IMPORTANT STEP!!!!!
Now go to your server folder and make a new folder named as "OMG"
DONE! Made 99.9% by me! 0.001 % to Boomer for idea to add name to bannedusers.txt LOL