Thread: How to Make objects give you in item when you click in them!

Results 1 to 4 of 4
  1. #1 How to Make objects give you in item when you click in them! 
    black-pure-4-lyfe
    Guest
    Hello,

    Well this is my first tut and i havent really seen anyone have this i know everyone knows how to do this but maybe some ppl dont know soo yea here it is

    Purpose: so people can know how to get items when u click on a certain object

    Difficutly:1/10

    Knowledge:Finding, C+P

    Server base:Pimpscape (but works for ALL)

    Class Modified:Client.java

    Open your client.java and search for

    Code:
    case 1531:
    You should see this

    Code:
    if(GoodDistance2(absX, absY, objectX, objectY, 3)) {
    	if(actionTimer == 0)
    	{
    		sendMessage("YOU GET STRENGHT EXP!!!");
    		actionTimer = 20;
    		setAnimation(0x326);
    		addSkillXP((15*playerLevel[2]), 2);
    		addSkillXP((5*playerLevel[3]), 3);
                                    updateRequired = true;
                                    appearanceUpdateRequired = true;
    	}
    Reaplace that all with this:

    Code:
    if(GoodDistance2(absX, absY, objectX, objectY, 3)) {
    	if(actionTimer == 0)
    	{
    		sendMessage("YOU GET STRENGHT EXP!!!");
    		actionTimer = 20;
    		setAnimation(0x326);
    		addSkillXP((15*playerLevel[2]), 2);
    		addSkillXP((5*playerLevel[3]), 3)                             
                                    addItem(1038,1);
    		updateRequired = true;
                                   appearanceUpdateRequired = true;
    	}
    In that case we are using a rare which is (1038,1) but you can change it to anything you want.

    Now search for:

    Code:
    case 299:
    You will see this:

    Code:
    if(GoodDistance2(absX, absY, objectX, objectY, 3)) {
    if(actionTimer == 0)
    {
    sendMessage("YOU GET DEFENCE EXP!!!YOU HORSE!");
    addSkillXP((15*playerLevel[1]), 1);
    addSkillXP((5*playerLevel[18]), 18);
    actionTimer = 10;
    setAnimation(0x320);
    updateRequired = true;
    appearanceUpdateRequired = true;
    }
    }
    break;
    Replace that all with this:

    Code:
    if(GoodDistance2(absX, absY, objectX, objectY, 3)) {
    if(actionTimer == 0)
    {
    sendMessage("YOU GET DEFENCE EXP!!!YOU HORSE!");
    addSkillXP((15*playerLevel[1]), 1);
    addSkillXP((5*playerLevel[18]), 18);
    addItem(1038,1);
    actionTimer = 10;
    setAnimation(0x320);
    updateRequired = true;
    appearanceUpdateRequired = true;
    }
    }
    break;
    again we are using a rare so you change it to anything u want

    search for:
    Code:
    case 823:
    You should see this:

    Code:
    if (actionTimer == 0) {
    sendMessage("YOU GET ATTACK EXP!!!");
    setAnimation(0x326);
    addSkillXP((15*playerLevel[0]), 0);
    addSkillXP((5*playerLevel[3]), 3);
    actionTimer = 12;
    }
    break;
    Replace that all with this

    Code:
    if (actionTimer == 0) {
    sendMessage("YOU GET ATTACK EXP!!!");
    setAnimation(0x326);
    addSkillXP((5*playerLevel[0]), 0);
    addSkillXP((15*playerLevel[3]), 3);
    addItem(1038,1);
    actionTimer = 12;
    }
    break;
    Again we are using a rare but as i said you can change it to anythingn you want.

    This wasnt leached i used it out of my own source

    I really dont mind if you give me rep
    all i want is for you guys not to flame

    CREDITS:ME

    is this good for my first tut? i wouldnt know...
    Last edited by black-pure-4-lyfe; 08-13-2007 at 07:55 PM. Reason: Double posting is not allowed!
     

  2. #2  
    Registered Member
    JakobWolthers's Avatar
    Join Date
    Aug 2007
    Age
    31
    Posts
    616
    Thanks given
    16
    Thanks received
    3
    Rep Power
    84
    i got 3 errors it say the compiler can't find additem(1038,1);



    plz help me
     

  3. #3  
    rukia
    Guest
    change (1038,1)

    to

    (1038, 1)

    it needed a space but this is fairly nice for noob coders i guess but u need to remembe that not all sorces have the training on those objects so you need to explain it a liil more in depth but ill rep your for trying
     

  4. #4  
    Registered Member
    JakobWolthers's Avatar
    Join Date
    Aug 2007
    Age
    31
    Posts
    616
    Thanks given
    16
    Thanks received
    3
    Rep Power
    84
    i have tried but it's not working i get errors because it can't find the additem
     


Thread Information
Users Browsing this Thread

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


User Tag List

Similar Threads

  1. Replies: 25
    Last Post: 10-17-2010, 04:40 PM
  2. Replies: 1
    Last Post: 08-21-2009, 03:02 AM
  3. Replies: 0
    Last Post: 08-20-2009, 08:54 AM
  4. Replies: 2
    Last Post: 07-19-2009, 08:47 PM
Posting Permissions
  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •