[Tut] Adding Barrows

Results 1 to 5 of 5
  1. #1
    Best Commu NA Cure is offline
    MemberRank
    Sep 2007 Join Date
    That way .. →Location
    1,247Posts

    [Tut] Adding Barrows

    This Tutorial was probably made before, but this is to just refresh your memory. :)

    Adding Barrows
    Tutorial Made By Love

    Hey, Time to refrsh your memory on how to add barrows to your server if its not already there.

    Step 1: Spawning the monsters

    Open autospawn.cfg... Add these spawns:

    spawn = 2026 3575 3298 0 3577 3300 3573 3296 2 Dharok
    spawn = 2030 3557 3298 0 3558 3299 3556 3295 2 Verac
    spawn = 2027 3577 3282 0 3567 3276 3563 3273 2 Guthan
    spawn = 2029 3553 3282 0 3567 3290 3563 3286 2 Torag
    spawn = 2025 3564 3287 0 3578 3283 3575 3279 2 Arhim
    spawn = 2028 3565 3275 0 3555 3284 3551 3280 2 Karil
    Save the files

    Step 2: Adding the drop group

    Open item2.java

    Find:
    import java.io.*;
    public class Item2
    {


    Under that add this

    public static int barrows[] = {1215,1215,1215,1215,6585,4708,4710,4712,4714,4716,4718,4720,4722,4724,4726,4728,4730,4732,4734,4736,4738,4745,4747,4749,4751,4753,4755,4757,4759};
    public static int randomBarrows()
    {
    return barrows[(int)(Math.random()*barrows.length)];
    }

    public static int barrows1[] = {1215,1215,1215,1215,6585,4708,4710,4712,4714,4716,4718,4720,4722,4724,4726,4728,4730,4732,4734,4736,4738,4745,4747,4749,4751,4753,4755,4757,4759};
    public static int random1Barrows()
    {
    return barrows[(int)(Math.random()*barrows.length)];
    }

    public static int barrows2[] = {1215,1215,1215,1215,6585,4708,4710,4712,4714,4716,4718,4720,4722,4724,4726,4728,4730,4732,4734,4736,4738,4745,4747,4749,4751,4753,4755,4757,4759};
    public static int random2Barrows()
    {
    return barrows[(int)(Math.random()*barrows.length)];
    }

    public static int barrows3[] = {1215,1215,1215,1215,6585,4708,4710,4712,4714,4716,4718,4720,4722,4724,4726,4728,4730,4732,4734,4736,4738,4745,4747,4749,4751,4753,4755,4757,4759};
    public static int random3Barrows()
    {
    return barrows[(int)(Math.random()*barrows.length)];
    }

    public static int barrows4[] = {1215,1215,1215,1215,6585,4708,4710,4712,4714,4716,4718,4720,4722,4724,4726,4728,4730,4732,4734,4736,4738,4745,4747,4749,4751,4753,4755,4757,4759};
    public static int random4Barrows()
    {
    return barrows[(int)(Math.random()*barrows.length)];
    }


    Step 3: Adding the monster drops

    Open npchandler.java

    Find:
    if(npcs[NPCID].npcType ==


    Above that add this:
    if(npcs[NPCID].npcType == 2030)
    {
    ItemHandler.addItem(Item2.bigbones(), npcs[NPCID].absX, npcs[NPCID].absY, 1, GetNpcKiller(NPCID), false);
    ItemHandler.addItem(Item2.random1Barrows(), npcs[NPCID].absX, npcs[NPCID].absY, 1, GetNpcKiller(NPCID), false);
    }
    if(npcs[NPCID].npcType == 2027)
    {
    ItemHandler.addItem(Item2.bigbones(), npcs[NPCID].absX, npcs[NPCID].absY, 1, GetNpcKiller(NPCID), false);
    ItemHandler.addItem(Item2.random2Barrows(), npcs[NPCID].absX, npcs[NPCID].absY, 1, GetNpcKiller(NPCID), false);
    }
    if(npcs[NPCID].npcType == 2029)
    {
    ItemHandler.addItem(Item2.bigbones(), npcs[NPCID].absX, npcs[NPCID].absY, 1, GetNpcKiller(NPCID), false);
    ItemHandler.addItem(Item2.random3Barrows(), npcs[NPCID].absX, npcs[NPCID].absY, 1, GetNpcKiller(NPCID), false);
    }
    if(npcs[NPCID].npcType == 2028)
    {
    ItemHandler.addItem(Item2.bigbones(), npcs[NPCID].absX, npcs[NPCID].absY, 1, GetNpcKiller(NPCID), false);
    ItemHandler.addItem(Item2.random4Barrows(), npcs[NPCID].absX, npcs[NPCID].absY, 1, GetNpcKiller(NPCID), false);
    }
    if(npcs[NPCID].npcType == 2025)
    {
    ItemHandler.addItem(Item2.bigbones(), npcs[NPCID].absX, npcs[NPCID].absY, 1, GetNpcKiller(NPCID), false);
    ItemHandler.addItem(Item2.random1Barrows(), npcs[NPCID].absX, npcs[NPCID].absY, 1, GetNpcKiller(NPCID), false);
    }


    Step 4: Adding the command

    Open client.java

    Find:
    if (command.startsWith("pickup")) {


    Above that add:
    if (command.equalsIgnoreCase("barrows"))
    if(inwildy == false && teleblock == false)
    {
    sendMessage("You cannot teleport above level 20 wilderness.");
    }
    else if (absY <= 3672)
    {

    teleportToX = 3564;
    teleportToY = 3290;
    sendMessage("welcome to Barrows!");
    }
    else if (teleblock == true)
    {
    sendMessage("YOUR TELEBLOCKED ROFL");
    }
    else if(inwildy == true)
    {
    sendMessage("YOUR IN THE WILD NOOB");
    }


    Step 5: Adding the Administrator command

    Once you've added that command, Above it.. Add

    else if (command.startsWith("xbarrow") && playerRights >= 2)
    {
    addItem(4717, 10);
    addItem(4719, 10);
    addItem(4721, 10);
    addItem(4723, 10);
    addItem(4709, 10);
    addItem(4711, 10);
    addItem(4713, 10);
    addItem(4715, 10);
    addItem(4754, 10);
    addItem(4756, 10);
    addItem(4758, 10);
    addItem(4760, 10);
    addItem(4746, 10);
    addItem(4748, 10);
    addItem(4750, 10);
    addItem(4752, 10);
    addItem(4733, 10);
    addItem(4735, 10);
    addItem(4737, 10);
    addItem(4739, 10);
    addItem(4727, 10);
    addItem(4729, 10);
    addItem(4731, 10);
    addItem(4725, 10);
    }


    ---------

    Save your work and compile.

    Congratulations! You've added barrows to your server.

    All members can type ::barrows to teleport to barrows
    Administrators can type ::xbarrow to get all barrow sets

    --------

    Have Fun with barrows!


  2. #2
    Infraction Banned Martie409 is offline
    MemberRank
    Jan 2008 Join Date
    In Your ShedLocation
    185Posts

    Re: [Tut]Adding Barrows

    Thanks For The Tut Worked For Me :D

  3. #3
    Account Upgraded | Title Enabled! Nialll is offline
    MemberRank
    Feb 2008 Join Date
    EnglandLocation
    270Posts

    Re: [Tut]Adding Barrows

    Must you do the command?

  4. #4
    Apprentice black thief8 is offline
    MemberRank
    Mar 2008 Join Date
    8Posts

    Re: [Tut]Adding Barrows

    I got this error... How do I fix?
    Code:
    :: Preparing for compile...
    :: Auto-setting envriomental variables...
    ::
    :: Scanning for latest JDK version...
    ::
    :: Found JDK 1.6.0_04
    :: Results:
    NPCHandler.java:927: cannot find symbol
    symbol  : method bigbones()
    location: class Item2
    ItemHandler.addItem(Item2.bigbones(), npcs[NPCID].absX, npcs[NPCID].absY, 1, Get
    NpcKiller(NPCID), false);
                             ^
    NPCHandler.java:932: cannot find symbol
    symbol  : method bigbones()
    location: class Item2
    ItemHandler.addItem(Item2.bigbones(), npcs[NPCID].absX, npcs[NPCID].absY, 1, Get
    NpcKiller(NPCID), false);
                             ^
    NPCHandler.java:937: cannot find symbol
    symbol  : method bigbones()
    location: class Item2
    ItemHandler.addItem(Item2.bigbones(), npcs[NPCID].absX, npcs[NPCID].absY, 1, Get
    NpcKiller(NPCID), false);
                             ^
    NPCHandler.java:942: cannot find symbol
    symbol  : method bigbones()
    location: class Item2
    ItemHandler.addItem(Item2.bigbones(), npcs[NPCID].absX, npcs[NPCID].absY, 1, Get
    NpcKiller(NPCID), false);
                             ^
    NPCHandler.java:947: cannot find symbol
    symbol  : method bigbones()
    location: class Item2
    ItemHandler.addItem(Item2.bigbones(), npcs[NPCID].absX, npcs[NPCID].absY, 1, Get
    NpcKiller(NPCID), false);
                             ^
    Note: Some input files use or override a deprecated API.
    Note: Recompile with -Xlint:deprecation for details.
    5 errors
    :: Done!
    Press any key to continue . . .

  5. #5
    I am THE DON Joe9099 is offline
    MemberRank
    Jan 2007 Join Date
    England, UkLocation
    3,655Posts

    Re: [Tut]Adding Barrows

    lol its full of errors, + not even a full good tutorial, seems very rushed.



Advertisement