I will be using my barrows to explain this.
Purpose: make it so certain data writes to a text file
Difficulty 3/10
Credits to me and only me
First go into client.java and look for:
Code:
characterfile.write("character-height = ", 0, 19);
characterfile.write(Integer.toString(heightLevel), 0, Integer.toString(heightLevel).length());
characterfile.newLine();
That is the part that writes the data to the char file.
That tells the server to write that into character files when they are created.
That is the ints name you have to change all of them to the name of the int you want to use.
Next find where all your other ints/public static boolean are
and add some thing like
Code:
public static int barrowskillcount = 0;
That tells what the server is spouse to log.
Next find you might want to make a interface to show the kills but making a few different things like
Code:
public void BarrowsKillCountRegister() {
sendFrame126("@whi@Barrows Kill Count", 8144); // Helpmenu title
clearQuestInterface();
sendFrame126("@whi@Kill Count:" + barrowskillcount, 8145);
sendQuestSomething(8143);
showInterface(8134);
}
Add this command to make it able to been seen
Code:
if (command.startsWith("killcount")) {
BarrowsKillCountRegister();
}
To make it go up from killing the barrows npcs add this in your NPCHandeler.java
Code:
} else if (npcs[i].npcType == 2026){
npcs[i].animNumber = 0x900;//Barrows Dharok
client.barrowskillcount++;
} else if (npcs[i].npcType == 2025){
npcs[i].animNumber = 0x900;//Barrows Ahrim
client.barrowskillcount++;
} else if (npcs[i].npcType == 2027){
npcs[i].animNumber = 0x900;//Barrows Guthan
client.barrowskillcount++;
} else if (npcs[i].npcType == 2028){
npcs[i].animNumber = 0x900;//Barrows Karil
client.barrowskillcount++;
} else if (npcs[i].npcType == 2029){
npcs[i].animNumber = 0x900;//Barrows Torag
client.barrowskillcount++;
} else if (npcs[i].npcType == 2030){
npcs[i].animNumber = 0x900;//Barrows Verac
client.barrowskillcount++;
} else if (npcs[i].npcType == 2036){ //Barrows Skeletons
npcs[i].animNumber = 0x900;
}
Hope this helped and remember ***++ is always appreciated
The server with these barrows is Evolutionscape.no-ip.org
NOTE: this will **** your server if you try to log onto a recreated character.