You say "Don't tell me to look at the logout delay.... yet the logout delay is all you need. You're never going to get anywhere if all you do is copy/paste.
Anyways....
The logout method:
Code:
public void logout() {
if(System.currentTimeMillis() - logoutDelay > 10000) {
outStream.createFrame(109);
properLogout = true;
PlayerSave.saveGame(this);
} else {
sendMessage("Please wait "+logoutDelay+" seconds before logging out!");
}
}
Now.... as you can see it checks at the begining:
Code:
if(System.currentTimeMillis() - logoutDelay > 10000) {
So you would simple add that to the openUpBank method, like so:
Code:
public void openUpBank(){
if(c.inWild() && !c.safeZone())
{
c.sendMessage("You can't bank in the wilderness!");
return;
}
if(c.getOutStream() != null && c != null && System.currentTimeMillis() - c.logoutDelay > 10000) {
c.isBanking = true;
c.getItems().resetItems(5064);
c.getItems().rearrangeBank();
c.getItems().resetBank();
c.getItems().resetTempItems();
c.getOutStream().createFrame(248);
c.getOutStream().writeWordA(5292);
c.getOutStream().writeWord(5063);
c.flushOutStream();
}
}
Alright so we have the check to see if it has alredy been 10 seconds and now you need to add he message to send if it hasn't been 10 seconds.
So just like the logout method(Changed a bit):
Code:
} else {
sendMessage("Please wait "+logoutDelay+" seconds before logging out!");
Add it to the bank method like so:
Code:
public void openUpBank(){
if(c.inWild() && !c.safeZone())
{
c.sendMessage("You can't bank in the wilderness!");
return;
}
if(c.getOutStream() != null && c != null && System.currentTimeMillis() - c.logoutDelay > 10000) {
c.isBanking = true;
c.getItems().resetItems(5064);
c.getItems().rearrangeBank();
c.getItems().resetBank();
c.getItems().resetTempItems();
c.getOutStream().createFrame(248);
c.getOutStream().writeWordA(5292);
c.getOutStream().writeWord(5063);
c.flushOutStream();
} else {
c.sendMessage("You were recently in combat please wait 10 seconds before banking!");
}
}
There you go it's that easy.
I'm going to let you do the other two in hopes that you will actually learn something.
If you happen to have more questions, as long as there not "Can you do the other two for me" then i'd be happy to answer them.