[Tut] [317] Working Genie Lamps

Results 1 to 2 of 2
  1. #1
    There's no RL just AFK -fedexer- is offline
    MemberRank
    May 2006 Join Date
    ScotlandLocation
    1,632Posts

    [Tut] [317] Working Genie Lamps

    Purpose: Working Genie Lamps

    Difficulty: 4

    Assumed Knowledge: you should know how to add voids

    Server Base: cheeazscape 78 (shpuld work on most )

    Classes Modified: client.java


    hey all well i havent seen anyone do genie lamps so i thought i would give it a shot so here goes,

    procedure
    step 1

    ok search this in client.java

    Code:
    case 51039: TeleTo("Ghorrock"); 
    break;
    directly under that put this code

    Code:
    			case 10255: 
                                                    sendMessage("The lamp gives you xp");
                                                    addSkillXP((2500*playerLevel[playerMagic]), playerMagic);
                                                    appearanceUpdateRequired = true;
                                                    updateRequired = true;
                                                    closeInterface(); 
                                                    break;
                                            case 10252: 
                                                    sendMessage("The lamp gives you xp");
                                                    addSkillXP((2500*playerLevel[playerAttack]), playerAttack);
                                                    appearanceUpdateRequired = true;
                                                    updateRequired = true;
                                                    closeInterface(); 
                                                    break;
                                            case 10253: 
                                                    sendMessage("The lamp gives you xp");
                                                    addSkillXP((2500*playerLevel[playerStrength]), playerStrength);
                                                    appearanceUpdateRequired = true;
                                                    updateRequired = true;
                                                    closeInterface(); 
                                                    CalculateMaxHit();
                                                    break;
                                            case 10254: 
                                                    sendMessage("The lamp gives you xp");
                                                    addSkillXP((2500*playerLevel[playerRanged]), playerRanged);
                                                    appearanceUpdateRequired = true;
                                                    updateRequired = true;
                                                    closeInterface(); 
                                                    CalculateMaxHit();
                                                    break;
                                            case 11000: 
                                                    sendMessage("The lamp gives you xp");
                                                    addSkillXP((2500*playerLevel[playerDefence]), playerDefence);
                                                    appearanceUpdateRequired = true;
                                                    updateRequired = true;
                                                    closeInterface(); 
                                                    break;
                                            case 11001: 
                                                    sendMessage("The lamp gives you xp");
                                                    addSkillXP((2500*playerLevel[playerHitpoints]), playerHitpoints);
                                                    appearanceUpdateRequired = true;
                                                    updateRequired = true;
                                                    closeInterface(); 
                                                    break;
                                            case 11002: 
                                                    sendMessage("The lamp gives you xp");
                                                    addSkillXP((2500*playerLevel[playerPrayer]), playerPrayer);
                                                    appearanceUpdateRequired = true;
                                                    updateRequired = true;
                                                    closeInterface(); 
                                                    break;
                                            case 11003: 
                                                    sendMessage("The lamp gives you xp");
                                                    addSkillXP((2500*playerLevel[playerAgility]), playerAgility);
                                                    appearanceUpdateRequired = true;
                                                    updateRequired = true;
                                                    closeInterface(); 
                                                    break;
                                            case 11004: 
                                                    sendMessage("The lamp gives you xp");
                                                    addSkillXP((2500*playerLevel[playerHerblore]), playerHerblore);
                                                    appearanceUpdateRequired = true;
                                                    updateRequired = true;
                                                    closeInterface(); 
                                                    break;
    				case 11005: 
                                                    sendMessage("The lamp gives you xp");
                                                    addSkillXP((2500*playerLevel[playerThieving]), playerThieving);
                                                    appearanceUpdateRequired = true;
                                                    updateRequired = true;
                                                    closeInterface(); 
                                                    break;
    				case 11006: 
                                                    sendMessage("The lamp gives you xp");
                                                    addSkillXP((2500*playerLevel[playerCrafting]), playerCrafting);
                                                    appearanceUpdateRequired = true;
                                                    updateRequired = true;
                                                    closeInterface(); 
                                                    break;
    				case 11007: 
                                                    sendMessage("The lamp gives you xp");
                                                    addSkillXP((2500*playerLevel[playerRunecrafting]), playerRunecrafting);
                                                    appearanceUpdateRequired = true;
                                                    updateRequired = true;
                                                    closeInterface(); 
                                                    break;
    				case 47002: 
                                                    sendMessage("The lamp gives you xp");
                                                    addSkillXP((2500*playerLevel[playerSlayer]), playerSlayer);
                                                    appearanceUpdateRequired = true;
                                                    updateRequired = true;
                                                    closeInterface(); 
                                                    break;
    				case 54090: 
                                                    sendMessage("The lamp gives you xp");
                                                    addSkillXP((2500*playerLevel[playerFarming]), playerFarming);
                                                    appearanceUpdateRequired = true;
                                                    updateRequired = true;
                                                    closeInterface(); 
                                                    break;
    				case 11008: 
                                                    sendMessage("The lamp gives you xp");
                                                    addSkillXP((2500*playerLevel[playerMining]), playerMining);
                                                    appearanceUpdateRequired = true;
                                                    updateRequired = true;
                                                    closeInterface(); 
                                                    break;
    				case 11009: 
                                                    sendMessage("The lamp gives you xp");
                                                    addSkillXP((2500*playerLevel[playerSmithing]), playerSmithing);
                                                    appearanceUpdateRequired = true;
                                                    updateRequired = true;
                                                    closeInterface(); 
                                                    break;
    				case 11010: 
                                                    sendMessage("The lamp gives you xp");
                                                    addSkillXP((2500*playerLevel[playerFishing]), playerFishing);
                                                    appearanceUpdateRequired = true;
                                                    updateRequired = true;
                                                    closeInterface(); 
                                                    break;
    				case 11011: 
                                                    sendMessage("The lamp gives you xp");
                                                    addSkillXP((2500*playerLevel[playerCooking]), playerCooking);
                                                    appearanceUpdateRequired = true;
                                                    updateRequired = true;
                                                    closeInterface(); 
                                                    break;
    				case 11012: 
                                                    sendMessage("The lamp gives you xp");
                                                    addSkillXP((2500*playerLevel[playerFiremaking]), playerFiremaking);
                                                    appearanceUpdateRequired = true;
                                                    updateRequired = true;
                                                    closeInterface(); 
                                                    break;
    				case 11013: 
                                                    sendMessage("The lamp gives you xp");
                                                    addSkillXP((2500*playerLevel[playerWoodcutting]), playerWoodcutting);
                                                    appearanceUpdateRequired = true;
                                                    updateRequired = true;
                                                    closeInterface(); 
                                                    break;
    				case 11014: 
                                                    sendMessage("The lamp gives you xp");
                                                    addSkillXP((2500*playerLevel[playerFletching]), playerFletching);
                                                    appearanceUpdateRequired = true;
                                                    updateRequired = true;
                                                    closeInterface(); 
                                                    break;
    step 2
    then search for
    Code:
    public boolean CheckForSkillUse3(int Item, int Slot) {
    		boolean GoOn = true;
    		switch (Item) {
    and then directly under that put this

    Code:
    case 2528: 
                                    deleteItem(2528, GetItemSlot(2528), 1); 
                                    showInterface(2808); 
                                    break;
    well thats it ;) hope this makes you all gain levels lol.... remember you still need a way of obtaining the genie lamps this doesnt give you them

    You may also need the closeInterface void if you dont already have it

    step 3
    Here's closeInterface:

    Code:
    	public void closeInterface() {
    		outStream.createFrame(219);
    	}
    credits : -fedexer- (myself)


  2. #2
    Alpha Member Jare is offline
    MemberRank
    Mar 2007 Join Date
    AB, CanadaLocation
    1,711Posts

    Re: [Tut] Working Genie Lamps

    This will help some people (if they read the coding not just C+P) somewhat understand boolean/case statement interaction. Random events are always fun to code.

    I have an idea about how to make the Dr. Jekyl random. Will try coding it on my server first. Then if it works well enough, I'll release it.



Advertisement