Assumed Knowledge: before doing this tut do this tut!!!!! :[Only registered and activated users can see links. ]
Server Base: probally most servers.
Classes Modified: client.java
Procedure Step 1: first search for
Code:
public void writePlayers() {
Step 2: under that boolean you will see something like this :
Code:
if(isInBarrows()) {
Step 3: under that ifisninbarrows code add
Code:
if(isInVarrock()) {
outStream.createFrame(74);//this sends the frame
outStream.writeWordBigEndian(125);//this is the music id (varrock)
}
}
this will make it send the sound . but now we must make the isInVarrock boolean step 4lets make the isinvarrock boolean. and add it right under the isInArea boolean
first we start off with the base that looks like this :
Code:
public boolean isInVarrock()
{
step 5now we need to tell when you are in varrock so under the last { add :
Code:
if (isInArea(3158,3469, 3258, 3258)) return true;
step 6and where a return true is is a return false too. so under
Code:
return true;
add
Code:
return false;
step 7now we close the boolean by adding this under it :
Code:
}
step 8 now we have something like this :
Code:
public boolean isInVarrock()
{
if (isInArea(3158,3469, 3258, 3258)) return true;
return false;
}
step 9: compile and run. now if you done my other tut and walk into varrock the music will start Credits: 40% for llama with explaining me the isninarea stuff.
60% me for making the tut