Thread: Congratulations, you just advanced an attack level! You can now wear ...

Page 1 of 3 123 LastLast
Results 1 to 10 of 21
  1. #1 Congratulations, you just advanced an attack level! You can now wear ... 
    Registered Member

    Join Date
    Dec 2007
    Posts
    621
    Thanks given
    9
    Thanks received
    8
    Rep Power
    163
    Congratulations, you just advanced an attack level! You can now wear ...

    Description: To tell your players what they can wear when they reach a certain level

    Difficulty: -10/10

    Assumed Knowledge: Copy and paste

    Tested Server: None but it should work on all

    Files/Classes Modified: Client.java

    Procedure


    Declare this in UpdateNPCChat() or whatever

    Code:
    case 1:
    	sendFrame164(6247);
    	stillgfx(199, absX, absY);
    	sendFrame126("@[email protected], you just advanced an attack level!", 6248);
    	sendFrame126("@[email protected] attack level is now " + getLevelForXP(playerXP[0]) + " .", 6249);
    	NpcDialogueSend = true;
    break;
    case 2:
    switch (playerLevel[0]) {
    	case 5:
    		sendFrame164(6206);
    		sendFrame246(6210, 290, 1325);
    		sendFrame126("", 6207);
    		sendFrame126("You can now equip Steel weapons!", 6208);			
    		NpcDialogueSend = true;
    	break;
    	case 10:
    		sendFrame164(6206);
    		sendFrame246(6210, 290, 1327);
    		sendFrame126("", 6207);
    		sendFrame126("@[email protected] can now equip Black weapons!", 6208);
    		NpcDialogueSend = true;
    	break;
    	case 20:
    		sendFrame164(6206);
    		sendFrame246(6210, 290, 1329);
    		sendFrame126("", 6207);
    		sendFrame126("@[email protected] can now equip Mithril weapons!", 6208);
    		NpcDialogueSend = true;
    	break;
    	case 30:
    		sendFrame164(6206);
    		sendFrame246(6210, 290, 1331);
    		sendFrame126("", 6207);
    		sendFrame126("@[email protected] can now equip Adamant weapons!", 6208);
    		NpcDialogueSend = true;
    	break;
    	case 40:
    		sendFrame164(6206);
    		sendFrame246(6210, 290, 1333);
    		sendFrame126("", 6207);
    		sendFrame126("@[email protected] can now equip Runite weapons!", 6208);
    		NpcDialogueSend = true;
    	break;
    	case 50:
    		sendFrame164(6206);
    		sendFrame246(6210, 290, 4153);
    		sendFrame126("", 6207);
    		sendFrame126("@[email protected] can now equip Granite weapons with 50 strength!", 6208);
    		NpcDialogueSend = true;
    	break;
    	case 60:
    		sendFrame164(6206);
    		sendFrame246(6210, 290, 4587);
    		sendFrame126("", 6207);
    		sendFrame126("@[email protected] can now equip Dragon weapons!", 6208);
    		NpcDialogueSend = true;
    	break;
    	case 99:
    		sendFrame164(6206);
    		sendFrame246(6210, 290, 0000);//CHANGE 0000 TO THE SKILL CAPE ID
    		sendFrame126("You can now buy and wear an Attack skillcape!", 6207);
    		sendFrame126("@[email protected] can buy a skill cape from ------!", 6208);
    		NpcDialogueSend = true;
    	break;
    	default:
    		NpcDialogue = 0;
    		NpcDialogueSend = false;
    		RemoveAllWindows();
    	break;
    	}
    break;

    Add this in your Levelup method..

    Code:
    case 0: // Attack levelup
    	NpcDialogue = 1;
    	sendMessage("Congratulations, you just advanced an attack level.");
    break;
    And declare this method if you don't have it..

    Code:
    public void sendFrame246(int MainFrame, int SubFrame, int SubFrame2) {
    	outStream.createFrame(246);
    	outStream.writeWordBigEndian(MainFrame);
    	outStream.writeWord(SubFrame);
    	outStream.writeWord(SubFrame2);
    	flushOutStream();
    }
    And add this to packet 40

    Code:
    || NpcDialogue == 1
    I believe that is it.. I haven't tested this or anything but this is all you should have to do ;P

    If you want to add it for defense or strength you only really need to edit it a tiny bit..

    I KNOW THIS IS NOT THE BEST WAY TO DO THIS BUT I WANTED TO DO IT QUICK SO JDASWVFSKLRHBVKSHBKSFJH



    Credits: I wrote this tutorial but I'm sure it has been posted before


    Thank you Surfer25 for reminding me to use a switch
     

  2. #2  
    Professional Upsetter


    Join Date
    Jul 2006
    Posts
    5,392
    Thanks given
    163
    Thanks received
    447
    Rep Power
    2040
    Fairly simple, but a nice and creative Idea. I like it very much.
    Ex-super moderator of Rune-Server.org and RSBot.org
     

  3. #3  
    I LOVE CHEESE


    Join Date
    Oct 2007
    Age
    26
    Posts
    1,153
    Thanks given
    7
    Thanks received
    8
    Rep Power
    104
    Ypu forgot lvl 99 a skillcape goodjob rep+


     

  4. #4  
    Registered Member

    Join Date
    Dec 2007
    Posts
    621
    Thanks given
    9
    Thanks received
    8
    Rep Power
    163
    Quote Originally Posted by ♣Man0l0♣ View Post
    Ypu forgot lvl 99 a skillcape goodjob rep+

    Added it lol.
     

  5. #5  
    Officially Retired


    Join Date
    Oct 2007
    Age
    27
    Posts
    5,456
    Thanks given
    558
    Thanks received
    122
    Rep Power
    1364
    i need some skill code for this thx
     

  6. #6  
    Member

    Join Date
    Dec 2007
    Posts
    1,094
    Thanks given
    8
    Thanks received
    8
    Rep Power
    0
    Ahh great base to start from, cool thanks.
     

  7. #7  
    Old School Member

    Join Date
    Feb 2008
    Age
    26
    Posts
    2,163
    Thanks given
    372
    Thanks received
    40
    Rep Power
    687
    +8 thanks for this.

    Quote Originally Posted by Colby View Post
    Rofl, moron. They're ALL going to be null idiot. This is such complete bullshit, it makes me want to strangle you.
     

  8. #8  
    T
    T is offline
    Registered Member
    T's Avatar
    Join Date
    Aug 2007
    Posts
    815
    Thanks given
    1
    Thanks received
    2
    Rep Power
    286
    thanks alot for a base. maybe u could be a little more specific for people that dont know where to add the case's, but otherwise it is great to expand on
     

  9. #9  
    I LOVE CHEESE


    Join Date
    Oct 2007
    Age
    26
    Posts
    1,153
    Thanks given
    7
    Thanks received
    8
    Rep Power
    104
    He sayed were lol he sayed : Under updatenpcchat()


     

  10. #10  
    Registered Member
    zedex ranger's Avatar
    Join Date
    Mar 2008
    Age
    27
    Posts
    2,565
    Thanks given
    1
    Thanks received
    9
    Rep Power
    325
    nice item on interface!! thanks
    [Only registered and activated users can see links. ]
     

Page 1 of 3 123 LastLast

Thread Information
Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)


User Tag List

Posting Permissions
  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •