Page 9 of 10 FirstFirst ... 78910 LastLast
Results 201 to 225 of 247

Thread: Roached

  1. #201
    Join Date
    Sep 2008
    Location
    Not here.
    Posts
    5,422
    Mentioned
    13 Post(s)
    Quoted
    242 Post(s)

    Default

    Quote Originally Posted by Darcy_Oner View Post
    Does this loot charms?
    Yes.

    I'm thinking about rewriting this...but that won't happen until after lape's release.

  2. #202
    Join Date
    Apr 2012
    Posts
    35
    Mentioned
    1 Post(s)
    Quoted
    8 Post(s)

    Default

    A little bug is if the monster drops 2 items. It will only pick up the top item, it will pick up the 2nd drop (usually a charm) after it kills the NEXT roach. It always kills it intime though before the charm disappears.
    Awesome script though LOVE IT

    P.S. also add an option for only picking up charms and not mith ore ect?

    Thanks a ton.


    EDIT: I think it is cause when I am standing ontop of the double loot it picks up one and then doesnt see the other.
    Last edited by k9thebeast; 05-19-2012 at 01:20 AM.

  3. #203
    Join Date
    May 2012
    Posts
    1
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Hi!
    I love this script and I really want to use it but it wont never run over ~1/1,5 hour.
    I'm f2p and I use swordfishes. Tested debugging enabled and disabled. When i log back in runescape my character is on bank or walking has failed. I turned off world hopping because it slows down my xp. I hope this helped you to help me
    I want to bot when I'm idle. Thanks!

    http://aijaa.com/0096110218610.jpg
    Last edited by ihanjees; 05-19-2012 at 12:28 PM.

  4. #204
    Join Date
    Dec 2011
    Posts
    41
    Mentioned
    0 Post(s)
    Quoted
    5 Post(s)

    Default

    sometimes it fails climb up rope and when i check my account is dead

  5. #205
    Join Date
    Feb 2012
    Posts
    6
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Great script man!
    I just have one problem, it always logs out after an hour or less for some reason.

  6. #206
    Join Date
    Nov 2011
    Location
    England
    Posts
    3,072
    Mentioned
    296 Post(s)
    Quoted
    1094 Post(s)

    Default

    Quote Originally Posted by mormonman View Post
    Yes.

    I'm thinking about rewriting this...but that won't happen until after lape's release.

    If you do plan on you should add a loot grabber like this http://villavu.com/forum/showthread.php?t=76643 although im most likely going to attempt to add it in myself :P

  7. #207
    Join Date
    Sep 2008
    Location
    Not here.
    Posts
    5,422
    Mentioned
    13 Post(s)
    Quoted
    242 Post(s)

    Default

    Quote Originally Posted by Ollybest View Post
    If you do plan on you should add a loot grabber like this http://villavu.com/forum/showthread.php?t=76643 although im most likely going to attempt to add it in myself :P
    The problem with a loot grabber like that is that I am picking up rune items, and everyone that fights roaches wears rune items. So it would be moving its mouse all over the screen.

  8. #208
    Join Date
    Nov 2011
    Location
    England
    Posts
    3,072
    Mentioned
    296 Post(s)
    Quoted
    1094 Post(s)

    Default

    Quote Originally Posted by mormonman View Post
    The problem with a loot grabber like that is that I am picking up rune items, and everyone that fights roaches wears rune items. So it would be moving its mouse all over the screen.
    Good point actually, If/when you do get round to updating this maybe make sure it double loots as it will only pick up 1 drop even when there's a stack of 2

  9. #209
    Join Date
    Jan 2012
    Posts
    3
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Hey,

    Awesome script, only one problem.
    Doesnt pick up crimson charms, is there any way to fix?

  10. #210
    Join Date
    Dec 2011
    Posts
    88
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Good script overall first I finally got working with simba I like the bot format if somehow a repository could be added sort of like MSI has if you open the defaults

  11. #211
    Join Date
    Dec 2011
    Posts
    88
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    will post proggies

  12. #212
    Join Date
    Sep 2008
    Location
    Not here.
    Posts
    5,422
    Mentioned
    13 Post(s)
    Quoted
    242 Post(s)

    Default

    Quote Originally Posted by Ollybest View Post
    Good point actually, If/when you do get round to updating this maybe make sure it double loots as it will only pick up 1 drop even when there's a stack of 2
    I could add some sort of quickfix when I get the time.

  13. #213
    Join Date
    Dec 2011
    Posts
    88
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    mormom the find crevice is a little buggy a few times i've gotten logged cause it can't find it and after it climbs out it when its out of food it will just sit there till it logs out but other than that it works great keep up the good scripting

  14. #214
    Join Date
    Feb 2012
    Posts
    30
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Bookmarked think i'll try this script out sometime.

  15. #215
    Join Date
    Nov 2011
    Location
    England
    Posts
    3,072
    Mentioned
    296 Post(s)
    Quoted
    1094 Post(s)

    Default

    Quote Originally Posted by mormonman View Post
    I could add some sort of quickfix when I get the time.
    Go for it if you ever do, would save alot of time and running about :P

  16. #216
    Join Date
    May 2012
    Posts
    1
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    R U lds 2?

  17. #217
    Join Date
    Sep 2008
    Location
    Not here.
    Posts
    5,422
    Mentioned
    13 Post(s)
    Quoted
    242 Post(s)

    Default

    Quote Originally Posted by happydish View Post
    R U lds 2?
    da fuq?

  18. #218
    Join Date
    May 2012
    Posts
    5
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Is this broken for anyone?

    Ranging is not working. The script can't find the bank in Edgeville bank. It fights one or two cockroaches and then runs up the rope to the bank despite having one of the supported foods remaining in inventory.

  19. #219
    Join Date
    Apr 2012
    Posts
    34
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    Quote Originally Posted by f33dback View Post
    Is this broken for anyone?

    Ranging is not working. The script can't find the bank in Edgeville bank. It fights one or two cockroaches and then runs up the rope to the bank despite having one of the supported foods remaining in inventory.
    Same, doesn't work for me.

  20. #220
    Join Date
    Sep 2008
    Location
    Not here.
    Posts
    5,422
    Mentioned
    13 Post(s)
    Quoted
    242 Post(s)

    Default

    The only thing wrong with the script is the food colors, banking colors, and for some reason this version has the old rope-climbing. My pc is currently packed away, so I can't upload any fixes for a while.

  21. #221
    Join Date
    Jun 2012
    Posts
    39
    Mentioned
    0 Post(s)
    Quoted
    5 Post(s)

    Default

    got through a couple of pages and couldn't find my answer so sorry if this has already been answered,
    but is there a way to only make it pick up charms/rare loot table/runes/ores? It keeps eating my swordies to pick up other players vials....
    Thanks.

  22. #222
    Join Date
    Nov 2011
    Location
    England
    Posts
    3,072
    Mentioned
    296 Post(s)
    Quoted
    1094 Post(s)

    Default

    This script (banking wise) is currently broken because Jagex changed the bankers, If you know how to use ACA to get a good colour + hue and sat mods you could easily edit it, I may put a "fixed" version up if I use this again.

  23. #223
    Join Date
    May 2012
    Posts
    28
    Mentioned
    0 Post(s)
    Quoted
    2 Post(s)

    Default

    xp/h ?

  24. #224
    Join Date
    Feb 2012
    Posts
    12
    Mentioned
    0 Post(s)
    Quoted
    0 Post(s)

    Default

    can you make it so it picks up the charms effiges ores runes shit like that . . .

    java Code:
    Manifest(authors = { "JustRS" }, name = "JustRoaches", description = "Kills Cockroach Soldiers, Loots Items, Banks for Food.", version = 2.1, website = "http://www.powerbot.org/community/topic/686539-justroaches-30k-40k-xphr-charms-cash/")

    public class JustRoaches extends ActiveScript implements PaintListener, MouseListener {

        public int PICKUP_ITEMS[] = {
                10266//Clue Scroll
                7282,   //Clue Scroll (medium)
                5316,   //Magic Seed
                5304,   //Torstol Seed
                5300,   //Snapdragon Seed
                5321,   //Watermelon Seed
                563,    //Law Rune
                560,    //Death Rune
                565,    //Blood Rune
                554,    //Fire Rune
                1333,   //Rune Scimitar
                1185,   //Rune Sq Shield
                450,    //Adamantite Ore
                448,    //Mithril Ore
                1631,   //Uncut Dragonstone
                12163//Blue Charm
                12160//Crimson Charm
                12159//Green Charm
                12158//Gold Charm
                24154//Spin Ticket
        //      995,    //Coins
                985     //Tooth Half of Key
            };
        // Do not edit past this point

        int EAT_PERCENT;
        int FOOD_ID;
        int WITHDRAW_AMT;
        String ATTACK_STYLE = "Attack";
       
        public long StartTime;
        public int StartXPAttack;
        public int StartXPStrength;
        public int StartXPDefense;
        public int StartXPRange;
        public int StartXPConstitution;
        public int FoodEaten = 0;
        public int BankWithdraws = 0;
       
        public int BlueCharms = 0;
        public int CrimsonCharms = 0;
        public int GreenCharms = 0;
        public int GoldCharms = 0;
        public int MithOre = 0;
        public int AdamOre = 0;
        public int LawRunes = 0;
        public int DeathRunes = 0;
        public int BloodRunes = 0;
        public int FireRunes = 0;
        public int RuneScimitar = 0;
        public int RuneShield = 0;
        public int WatermelonSeed = 0;
        public int TorstolSeed = 0;
        public int SnapdragonSeed = 0;
        public int MagicSeed = 0;
        public int UncutDragonstone = 0;
        public int SpinTickets = 0;
        public int Coins = 0;
       
        public int PrBlueCharms;
        public int PrCrimsonCharms;
        public int PrGreenCharms;
        public int PrGoldCharms;
        public int PrMithOre;
        public int PrAdamOre;
        public int PrLawRunes;
        public int PrDeathRunes;
        public int PrBloodRunes;
        public int PrFireRunes;
        public int PrRuneScimitar;
        public int PrRuneShield;
        public int PrWatermelonSeed;
        public int PrTorstolSeed;
        public int PrSnapdragonSeed;
        public int PrMagicSeed;
        public int PrUncutDragonstone;
        public int PrSpinTickets;
        public int PrCoins;
        public int TotalPriceLooted;
        public int TotalPriceLootedInK;
       
        public boolean TabLoot = false;
        public boolean TabCombat = true;
        Rectangle RecTabCombat = new Rectangle(8, 346, 110, 28);
        Rectangle RecTabLoot = new Rectangle(119, 346, 100, 28);
        Point p;
        boolean guiRunning = true;
       
        public int ROACHES = 7160;
        public int ROPE_ID = 29729;
        public int CREVICE_ID = 29728;
        public int BANK_ID = 42217;

        private final Tile[] ToBank = { new Tile(3080, 3463, 0),
                new Tile(3080, 3470, 0), new Tile(3080, 3477, 0),
                new Tile(3083, 3486, 0), new Tile(3093, 3491, 0) };
        private final Tile[] ToCrevice = { new Tile(3093, 3491, 0),
                new Tile(3083, 3486, 0), new Tile(3080, 3477, 0),
                new Tile(3080, 3470, 0), new Tile(3080, 3463, 0) };
       
        public String Status = "Script Started";
        private final Color color3 = new Color(255, 255, 255);
        private final Font body = new Font("Verdana", 0, 10);
        private final Font title = new Font("Verdana", 1, 10);
        private final Image img = getImage("http://img829.imageshack.us/img829/8426/justroachesv21.jpg");
       
        protected void setup() {

            log.info("_____________JustRoaches V2.1_____________");
            log.info("Loading GE Prices...");
            try {
                PrMithOre = getPrice(447);
                PrAdamOre = getPrice(449);
                PrLawRunes = getPrice(563);
                PrBloodRunes = getPrice(565);
                PrDeathRunes = getPrice(560);
                PrFireRunes = getPrice(554);
                PrRuneScimitar = getPrice(1333);
                PrRuneShield = getPrice(1185);
                PrTorstolSeed = getPrice(5304);
                PrSnapdragonSeed = getPrice(5300);
                PrWatermelonSeed = getPrice(5321);
                PrUncutDragonstone = getPrice(1631);
            } catch (IOException e) {
                e.printStackTrace();
            }
            log.info("Launching GUI");
           
            guiBuild();
           
            StartXPAttack = Skills.getExperience(Skills.ATTACK);
            StartXPStrength = Skills.getExperience(Skills.STRENGTH);
            StartXPDefense = Skills.getExperience(Skills.DEFENSE);
            StartXPRange = Skills.getExperience(Skills.RANGE);
            StartXPConstitution = Skills.getExperience(Skills.CONSTITUTION);

            if (Tabs.getCurrent() != Tabs.INVENTORY) {
                Tabs.INVENTORY.open();
            }
            Camera.setPitch(true);
            StartTime = System.currentTimeMillis();
           
            provide(new WalkToCrevice());
            provide(new Loot());
            provide(new EatFood());
            provide(new ClimbRope());
            provide(new AttackRoaches());
            provide(new WalkToBank());
            provide(new BankItems());
        }

        public void guiBuild() {
            SwingUtilities.invokeLater(new Runnable() {
                public void run() {
                    final JustRoachesGUI GUI = new JustRoachesGUI();
                    GUI.setVisible(true);
                    final guiBuild GUIBUILD = new guiBuild();
                    final Strategy GUIBUILD_STRATEGY = new Strategy(GUIBUILD, GUIBUILD);
                    provide(GUIBUILD_STRATEGY);
                    guiRunning = true;
                }
            });
        }
       
        private class guiBuild extends Strategy implements Task, Condition {
            public void run() {
                    while(guiRunning) Time.sleep(100);
            }      
            public boolean validate() {
                    return guiRunning;
            }
        }
        private class Loot extends Strategy implements Task {
            @Override
            public boolean validate() {
                    return !guiRunning && NeedToLoot()
                             && Players.getLocal().getLocation().getX() >= 3100;
            }
            @Override
            public void run() {
                for(int l : PICKUP_ITEMS) {
                    GroundItem g = GroundItems.getNearest(l);
                    if (g != null) {
                        Status = "Looting Items";
                        if (!g.isOnScreen() && g.getLocation().getY() >= 4274) {
                            Walking.walk(g);
                            sleep(500,800);
                        } else {
                                g.interact("Take", g.getGroundItem().getName());
                                if (Calculations.distanceTo(g.getLocation()) > 2) {
                                    sleep(1300,1500);
                                }

                                sleep(1300,1500);
                                if (g.getId() == 12163) { BlueCharms = BlueCharms+1; }
                                if (g.getId() == 12160) { CrimsonCharms = CrimsonCharms+1; }
                                if (g.getId() == 12159) { GreenCharms = GreenCharms+1; }
                                if (g.getId() == 12158) { GoldCharms = GoldCharms+1; }
                                if (g.getId() == 1333) { RuneScimitar = RuneScimitar+1; }
                                if (g.getId() == 1185) { RuneShield = RuneShield+1; }
                                if (g.getId() == 448) { MithOre = MithOre+(g.getGroundItem().getStackSize()); }
                                if (g.getId() == 450) { AdamOre = AdamOre+(g.getGroundItem().getStackSize()); }
                                if (g.getId() == 563) { LawRunes = LawRunes+(g.getGroundItem().getStackSize()); }
                                if (g.getId() == 560) { DeathRunes = DeathRunes+(g.getGroundItem().getStackSize()); }
                                if (g.getId() == 565) { BloodRunes = BloodRunes+(g.getGroundItem().getStackSize()); }
                                if (g.getId() == 554) { FireRunes = FireRunes+(g.getGroundItem().getStackSize()); }
                                if (g.getId() == 5304) { TorstolSeed = TorstolSeed+1; }
                                if (g.getId() == 5300) { SnapdragonSeed = SnapdragonSeed+1; }
                                if (g.getId() == 5321) { WatermelonSeed = WatermelonSeed+1; }
                                if (g.getId() == 5316) { MagicSeed = MagicSeed+(g.getGroundItem().getStackSize()); }
                                if (g.getId() == 1631) { UncutDragonstone = UncutDragonstone+1; }
                                if (g.getId() == 995) { Coins = Coins+(g.getGroundItem().getStackSize()); }
                        }
                    }
                }
            }
        }
        private class AttackRoaches extends Strategy implements Task {
            @Override
            public boolean validate() {
                    return !guiRunning && Players.getLocal().getLocation().getX() >= 3100
                                && !NeedToEat()
                                && !NeedToLoot()
                                && !FullInventory();
            }
            @Override
            public void run() {
                if (GetRoaches()==null && !NeedToLoot()) {
                    AntiBan();
                }
                if (GetRoaches().getLocation().getY() >= 4274 && !NeedToLoot()) {
                    if(GetRoaches().isOnScreen()) {
                        if(!Players.getLocal().isInCombat() && Players.getLocal().getInteracting()==null) {
                            GetRoaches().click(true);
                            Status = "Fighting Cockroach";
                            sleep(500,700);
                        } else {
                            AntiBan();
                        }
                    } else {
                        while (!GetRoaches().isOnScreen()) {
                            Walking.walk(GetRoaches().getLocation());
                            sleep(300,500);
                        }
                    }
                }
            }
        }
        private class EatFood extends Strategy implements Task {
            @Override
            public boolean validate() {
                    return !guiRunning && HaveFood()
                                && NeedToEat()
                                || FullInventory();
            }
            @Override
            public void run() {
                if(!Tabs.getCurrent().equals(Tabs.INVENTORY)) {
                    Tabs.INVENTORY.open();
                }
                for(Item i : Inventory.getItems()){
                    if(i.getId() == FOOD_ID && validate() && Players.getLocal().getAnimation()==-1){
                        i.getWidgetChild().click(true);
                        Status = "Eating Food";
                        sleep(900,1000);
                        FoodEaten = FoodEaten+1;
                    }
                }
            }
        }
        private class ClimbRope extends Strategy implements Task {
            @Override
            public boolean validate() {
                    return !guiRunning && !HaveFood()
                                && Players.getLocal().getLocation().getX() >= 3100
                                && NeedToEat()
                                && !NeedToLoot();
            }
            @Override
            public void run() {
                if (GetRope().isOnScreen()) {
                    Status = "Climbing Rope";
                    sleep(100,300);
                    GetRope().interact("Climb");
                    sleep(800,1000);
                } else {
                    Walking.walk(GetRope());
                    sleep(300,500);
                }

            }
        }
        private class WalkToBank extends Strategy implements Task {
            @Override
            public boolean validate() {
                    return !guiRunning && !HaveFood()
                                && !Bank.isOpen()
                                && Players.getLocal().getLocation().getX() <= 3100;
            }
            @Override
            public void run() {
                    Status = "Walking to Bank";
                    if (GetBank().isOnScreen() && Calculations.distanceTo(GetBank().getLocation()) <= 6) {
                            sleep(500, 700);
                            GetBank().interact("Bank");
                            sleep(800, 1000);
                    } else {
                        Walking.newTilePath(ToBank).traverse();
                    }
            }
        }
        private class WalkToCrevice extends Strategy implements Task {
            @Override
            public boolean validate() {
                    return !guiRunning && HaveFood()
                                && Players.getLocal().getLocation().getX() <= 3100;
            }
            @Override
            public void run() {
                    Status = "Walking to Crevice";
                    if (GetCrevice().isOnScreen() && Calculations.distanceTo(GetCrevice()) <= 5) {
                        Status = "Entering Crevice";
                        sleep(500, 700);
                        GetCrevice().interact("Enter");
                    } else {
                        Walking.newTilePath(ToCrevice).traverse();
                    }
            }
        }
        private class BankItems extends Strategy implements Task {
            @Override
            public boolean validate() {
                return !guiRunning && Bank.isOpen()
                        && !HaveFood()
                        && Players.getLocal().getLocation().getX() <= 3100;
            }
            @Override
            public void run() {
                Status = "Banking";
                sleep(500, 700);
                for(Item t:Inventory.getItems()){
                    if(t.getId() != FOOD_ID && Inventory.getCount() != 0){
                        Bank.depositInventory();
                        sleep(500,700);
                    }
                }
                if (WITHDRAW_AMT==5) {
                    sleep(500, 750);
                    Bank.withdraw(FOOD_ID, 5);
                    sleep(500, 750);
                }
                if (WITHDRAW_AMT==10) {
                    sleep(500, 750);
                    Bank.withdraw(FOOD_ID, 10);
                    sleep(500, 750);
                }
                if (WITHDRAW_AMT==15) {
                    sleep(500, 750);;
                    Bank.withdraw(FOOD_ID, 15);
                    sleep(500, 750);
                }
                if (WITHDRAW_AMT==20) {
                    sleep(500, 750);
                    Bank.withdraw(FOOD_ID, 20);
                    sleep(500, 750);;
                }
                sleep(500, 750);
                Bank.close();
                BankWithdraws++;
            }
        }

       
        public static void sleep(int min, int max){
            Time.sleep(Random.nextInt(min, max));      
        }
        public boolean FullInventory(){
            if (Inventory.getCount() == 28) {
                return true;
            }
            return false;
        }
        public NPC GetRoaches() {
            return NPCs.getNearest(ROACHES);
        }
        private SceneObject GetRope() {
            return SceneEntities.getNearest(ROPE_ID);
        }
        private SceneObject GetBank() {
            return SceneEntities.getNearest(BANK_ID);
        }
        private SceneObject GetCrevice() {
            return SceneEntities.getNearest(CREVICE_ID);
        }
        public boolean HaveFood() {
            if (Inventory.getCount(FOOD_ID) >= 1) {
                return true;
            }
            return false;
        }
        public boolean NeedToEat(){
            if (Integer.parseInt(Widgets.get(748, 8).getText()) <= (Skills.getLevel(Skills.CONSTITUTION))*EAT_PERCENT) {
                return true;
            }
            return false;
        }
        public boolean NeedToLoot() {
            for(int l : PICKUP_ITEMS) {
                GroundItem g = GroundItems.getNearest(l);
                if (g != null) {
                    return true;
                }
            }
            return false;
        }
       
        public int getPrice(int id) throws IOException {
            String price;
            URL url = new URL("http://services.runescape.com/m=itemdb_rs/viewitem.ws?obj=" + id);
            URLConnection con = url.openConnection();
            BufferedReader in = new BufferedReader(new InputStreamReader(con.getInputStream()));
            String line;
            while ((line = in.readLine()) != null) {
                if (line.contains("<td>")) {
                    price = line.substring(line.indexOf(">") + 1, line.indexOf("/") - 1);
                    try {
                        return Integer.parseInt(price);
                    } catch (NumberFormatException e) {
                        return 0;
                    }
                }
            }
            return 0;
        }
       
       
        private void AntiBan() {
            if (Players.getLocal().getInteracting()!=null) {
                switch (Random.nextInt(0, 50)) {
                    case 10:
                        Status = "Moving the Mouse";
                        Mouse.move(Random.nextInt(0, 700), Random.nextInt(0, 500));
                        break;
                    case 20:
                        Status = "Moving the Camera Angle";
                        Camera.setAngle(Random.nextInt(320, 20));
                        break;
                    case 30:
                        Status = "Moving the Camera Angle";
                        Camera.setAngle(Random.nextInt(20, 320));
                        break;
                    case 40:
                        Status = "Moving the Mouse";
                        Mouse.move(Random.nextInt(0, 700), Random.nextInt(0, 500));
                        break;
                }
            }
        }
       
       
        private Image getImage(String url) {
            try {
                return ImageIO.read(new URL(url));
            } catch (IOException e) {
                return null;
            }
        }
        public void onRepaint(Graphics g1) {
           
           
            TotalPriceLooted =
                (PrMithOre*MithOre) +
                (PrAdamOre*AdamOre) +
                (PrLawRunes*LawRunes) +
                (PrBloodRunes*BloodRunes) +
                (PrDeathRunes*DeathRunes) +
                (PrFireRunes*FireRunes) +
                (PrRuneScimitar*RuneScimitar) +
                (PrRuneShield*RuneShield) +
                (PrTorstolSeed*TorstolSeed) +
                (PrSnapdragonSeed*SnapdragonSeed) +
                (PrWatermelonSeed*WatermelonSeed) +
                (PrUncutDragonstone*UncutDragonstone) +
                (Coins);

            TotalPriceLootedInK = (TotalPriceLooted/1000);
            int CashPrHr = (int) (Math.floor((TotalPriceLooted * 3000000D) / (System.currentTimeMillis() - StartTime))/1000);      
                   
                   
            long RunTime = System.currentTimeMillis() - StartTime;

            int GainedXPConstitution = (Skills.getExperience(Skills.CONSTITUTION) - StartXPConstitution);
            int GainedXPAttack = (Skills.getExperience(Skills.ATTACK) - StartXPAttack);
            int GainedXPStrength = (Skills.getExperience(Skills.STRENGTH) - StartXPStrength);
            int GainedXPDefense = (Skills.getExperience(Skills.DEFENSE) - StartXPDefense);
            int GainedXPRange = (Skills.getExperience(Skills.RANGE) - StartXPRange);

            int XPUntilConstitution = (Skills.getExperienceRequired(Skills.getLevel(Skills.CONSTITUTION)+1) - Skills.getExperience(Skills.CONSTITUTION));
            int XPUntilAttack = (Skills.getExperienceRequired(Skills.getLevel(Skills.ATTACK)+1) - Skills.getExperience(Skills.ATTACK));
            int XPUntilStrength = (Skills.getExperienceRequired(Skills.getLevel(Skills.STRENGTH)+1) - Skills.getExperience(Skills.STRENGTH));
            int XPUntilDefense = (Skills.getExperienceRequired(Skills.getLevel(Skills.DEFENSE)+1) - Skills.getExperience(Skills.DEFENSE));
            int XPUntilRange = (Skills.getExperienceRequired(Skills.getLevel(Skills.RANGE)+1) - Skills.getExperience(Skills.RANGE));

            int CurLvlConstitution = Skills.getLevel(Skills.CONSTITUTION);
            int CurLvlAttack = Skills.getLevel(Skills.ATTACK);
            int CurLvlStrength = Skills.getLevel(Skills.STRENGTH);
            int CurLvlDefense = Skills.getLevel(Skills.DEFENSE);
            int CurLvlRange = Skills.getLevel(Skills.RANGE);

            int PerHrConstitution = (int) Math.floor((GainedXPConstitution * 3600000D) / (System.currentTimeMillis() - StartTime));
            int PerHrAttack = (int) Math.floor((GainedXPAttack * 3600000D) / (System.currentTimeMillis() - StartTime));          
            int PerHrStrength = (int) Math.floor((GainedXPStrength * 3000000D) / (System.currentTimeMillis() - StartTime));      
            int PerHrDefense = (int) Math.floor((GainedXPDefense * 3600000D) / (System.currentTimeMillis() - StartTime));      
            int PerHrRange = (int) Math.floor((GainedXPRange * 3000000D) / (System.currentTimeMillis() - StartTime));      

            int PercentToConstitution =  Skills.getExperienceRequired(CurLvlConstitution+1) / XPUntilConstitution;
            int PercentToAttack =  Skills.getExperienceRequired(CurLvlAttack+1) / XPUntilAttack;
            int PercentToStrength =  Skills.getExperienceRequired(CurLvlStrength+1) / XPUntilStrength;
            int PercentToDefense =  Skills.getExperienceRequired(CurLvlDefense+1) / XPUntilDefense;
            int PercentToRange =  Skills.getExperienceRequired(CurLvlRange+1) / XPUntilRange;
           
            Graphics2D g = (Graphics2D)g1;

            // Draw Paint
            g.drawImage(img, 6, 344, null);
           
            // Draw Tabs
            if (TabCombat==true)
                g.setColor(new Color(0,0,0));
            else
                g.setColor(new Color(0,0,0,150));
            g.fillRect(8, 346, 110, 28);
            if (TabLoot==true)
                g.setColor(new Color(0,0,0));
            else
                g.setColor(new Color(0,0,0,150));
            g.fillRect(119, 346, 100, 28);
            g.setColor(new Color(255,255,255));
            g.setFont(title);
            g.drawString("Combat Stats", 22, 363);
            g.drawString("Loot Stats", 140, 363);
           
            // TAB Combat
            if (TabCombat==true) {
                g.setColor(new Color(0,0,0));
                g.fillRect(18, 418, 252, 5);
                g.fillRect(18, 463, 252, 5);
               
                g.setColor(color3);
                g.setFont(body);
               
                g.drawString(PerHrConstitution + "xp/hr", 18, 402);
                g.drawString("Gained: " + GainedXPConstitution + "xp | " + PercentToConstitution + "% TNL ("+ (CurLvlConstitution+1) + ") " + XPUntilConstitution + "xp", 18, 414);
                g.setColor(new Color(255,255,255));
                g.fillRect(19, 419, ((250*PercentToConstitution)/100), 3);
                g.setColor(color3);
               
                if (ATTACK_STYLE=="Attack") {
                    g.drawString(PerHrAttack + "xp/hr", 18, 447);
                    g.drawString("Gained: " + GainedXPAttack + "xp | " + PercentToAttack + "% TNL ("+ (CurLvlAttack+1) + ") " + XPUntilAttack + "xp", 18, 459);
                    g.setColor(new Color(220,220,0));
                    g.fillRect(19, 464, ((250*PercentToAttack)/100), 3);
                    g.setColor(color3);
                }
                if (ATTACK_STYLE=="Strength") {
                    g.drawString(PerHrStrength + "xp/hr", 18, 447);
                    g.drawString("Gained: " + GainedXPStrength + "xp | " + PercentToStrength + "% TNL ("+ (CurLvlStrength+1) + ") " + XPUntilStrength + "xp", 18, 459);
                    g.setColor(new Color(220,20,20));
                    g.fillRect(19, 464, ((250*PercentToStrength)/100), 3);
                    g.setColor(color3);
                }
                if (ATTACK_STYLE=="Defense") {
                    g.drawString(PerHrDefense + "xp/hr", 18, 447);
                    g.drawString("Gained: " + GainedXPDefense + "xp | " + PercentToDefense + "% TNL ("+ (CurLvlDefense+1) + ") " + XPUntilDefense + "xp", 18, 459);
                    g.setColor(new Color(0,220,220));
                    g.fillRect(19, 464, ((250*PercentToDefense)/100), 3);
                    g.setColor(color3);
                    }
                if (ATTACK_STYLE=="Range") {
                    g.drawString(PerHrRange + "xp/hr", 18, 447);
                    g.drawString("Gained: " + GainedXPRange + "xp | " + PercentToRange + "% TNL ("+ (CurLvlRange+1) + ") " + XPUntilRange + "xp", 18, 459);
                    g.setColor(new Color(0,110,30));
                    g.fillRect(19, 464, ((250*PercentToRange)/100), 3);
                    g.setColor(color3);
                }

                g.drawString(Time.format(RunTime), 350, 390);
                g.drawString(""+FoodEaten, 365, 404);
                g.drawString(""+BankWithdraws, 394, 418);
                g.drawString(TotalPriceLootedInK+"k ("+CashPrHr+"k/hr) "+TotalPriceLooted+"gp", 328, 432);
                g.drawString(Status, 290, 460);
               
                g.setFont(title);
                g.drawString("Constitution:  " + CurLvlConstitution, 14, 390);
                if (ATTACK_STYLE=="Attack") {
                    g.drawString("Attack:  " + CurLvlAttack, 14, 436);
                }
                if (ATTACK_STYLE=="Strength") {
                    g.drawString("Strength:  " + CurLvlStrength, 14, 436);
                }
                if (ATTACK_STYLE=="Defense") {
                    g.drawString("Defence:  " + CurLvlDefense, 14, 436);
                }
                if (ATTACK_STYLE=="Range") {
                    g.drawString("Range:  " + CurLvlRange, 14, 436);
                }
                g.drawString("RunTime:", 290, 390);
                g.drawString("Food Eaten:", 290, 404);
                g.drawString("Bank Withdraws:", 290, 418);
                g.drawString("Cash:", 290, 432);
                g.drawString("Script Status", 290, 446);
            }

            // TAB Stats
            if (TabLoot==true) {
                g.setFont(body);
                g.drawString(BlueCharms + " Blue Charms", 18, 393);
                g.drawString(CrimsonCharms + " Crimson Charms", 18, 407);
                g.drawString(GreenCharms + " Green Charms", 18, 421);
                g.drawString(GoldCharms + " Gold Charms", 18, 435);
                g.drawString(RuneShield + " Rune Shields", 18, 449);
                g.drawString(RuneScimitar + " Rune Scimitars", 18, 463);

                g.drawString(MithOre + " Mithril Ore", 180, 393);
                g.drawString(AdamOre + " Adamanite Ore", 180, 407);
                g.drawString(LawRunes + " Law Runes", 180, 421);
                g.drawString(DeathRunes + " Death Runes", 180, 435);
                g.drawString(BloodRunes + " Blood Runes", 180, 449);
                g.drawString(FireRunes + " Fire Runes", 180, 463);

                g.drawString(TorstolSeed + " Torstol Seeds", 320, 393);
                g.drawString(SnapdragonSeed + " Snapdragon Seeds", 320, 407);
                g.drawString(WatermelonSeed + " Watermelon Seeds", 320, 421);
                g.drawString(MagicSeed + " Magic Seeds", 320, 435);
                g.drawString(UncutDragonstone + " Uncut Dragonstone", 320, 449);
                g.drawString(Coins + " Coins", 320, 463);
            }
           
           
            // Draw mouse
            if (System.currentTimeMillis() - Mouse.getPressTime() < 300)
                g.setColor(new Color(255,255,255));
            else
                g.setColor(new Color(255,255,255,80));
            g.drawLine(Mouse.getLocation().x - 7, Mouse.getLocation().y + 1, Mouse.getLocation().x + 7, Mouse.getLocation().y + 1);
            g.drawLine(Mouse.getLocation().x + 1, Mouse.getLocation().y - 7,Mouse.getLocation().x + 1, Mouse.getLocation().y + 7);
            g.drawLine(Mouse.getLocation().x - 7, Mouse.getLocation().y - 1, Mouse.getLocation().x + 7, Mouse.getLocation().y - 1);
            g.drawLine(Mouse.getLocation().x - 1, Mouse.getLocation().y - 7,Mouse.getLocation().x - 1, Mouse.getLocation().y + 7);

            g.setColor(new Color(0,0,0));
            g.drawLine(Mouse.getLocation().x - 7, Mouse.getLocation().y, Mouse.getLocation().x + 7, Mouse.getLocation().y);
            g.drawLine(Mouse.getLocation().x, Mouse.getLocation().y - 7,Mouse.getLocation().x, Mouse.getLocation().y + 7);
            g.fillOval(Mouse.getLocation().x - 2, Mouse.getLocation().y - 2, 4, 4);
           
        }
       
        @Override
        public void mouseClicked(MouseEvent e) {
            p = e.getPoint();
            if (RecTabCombat.contains(p) && !TabCombat) {
                TabCombat = true;
                TabLoot = false;
            }
            if (RecTabLoot.contains(p) && !TabLoot) {
                TabLoot = true;
                TabCombat = false;
            }
        }
        @Override
        public void mousePressed(MouseEvent e) {}
        @Override
        public void mouseReleased(MouseEvent e) {}
        @Override
        public void mouseEntered(MouseEvent e) {}
        @Override
        public void mouseExited(MouseEvent e) {}
       
        //GUI credit to SeyreZ
        @SuppressWarnings("serial")
        public class JustRoachesGUI extends JFrame {
            public JustRoachesGUI() {
                initComponents();
            }
            private void okButtonActionPerformed(ActionEvent e) {
               
                String f = foodid.getSelectedItem().toString();
                if (f.equals("Lobster")) {
                    FOOD_ID = 379;
                } else if (f.equals("Monkfish")) {
                    FOOD_ID = 7946;
                } else if (f.equals("Shark")) {
                    FOOD_ID = 385;
                } else if (f.equals("Rocktail")) {
                    FOOD_ID = 15272;
                } else if (f.equals("Tuna")) {
                    FOOD_ID = 361;
                } else if (f.equals("Swordfish")) {
                    FOOD_ID = 373;
                } else if (f.equals("Bass")) {
                    FOOD_ID = 365;
                } else if (f.equals("Manta Ray")) {
                    FOOD_ID = 391;
                }
                String a = combatStyle.getSelectedItem().toString();
                if (a.equals("Attack")) {
                    ATTACK_STYLE = "Attack";
                } else if (a.equals("Strength")) {
                    ATTACK_STYLE = "Strength";
                } else if (a.equals("Defense")) {
                    ATTACK_STYLE = "Defense";
                } else if (a.equals("Range")) {
                    ATTACK_STYLE = "Range";
                }
                String w = withdraw.getSelectedItem().toString();
                if (w=="5") {
                    WITHDRAW_AMT = 5;
                } else if (w=="10") {
                    WITHDRAW_AMT = 10;
                } else if (w=="15") {
                    WITHDRAW_AMT = 15;
                } else if (w=="20") {
                    WITHDRAW_AMT = 20;
                }
                String h = eatpercent.getSelectedItem().toString();
                if (h=="85") {
                    EAT_PERCENT = (int) 8.5;
                } else if (h=="80") {
                    EAT_PERCENT = 8;
                } else if (h=="75") {
                    EAT_PERCENT = (int) 7.5;
                } else if (h=="70") {
                    EAT_PERCENT = 7;
                } else if (h=="65") {
                    EAT_PERCENT = (int) 6.5;
                } else if (h=="60") {
                    EAT_PERCENT = 6;
                } else if (h=="55") {
                    EAT_PERCENT = (int) 5.5;
                } else if (h=="50") {
                    EAT_PERCENT = 5;
                } else if (h=="45") {
                    EAT_PERCENT = (int) 4.5;
                } else if (h=="40") {
                    EAT_PERCENT = 4;
                }
               
                log.info("Starting Script");
                setVisible(false);
                guiRunning = false;
                dispose();
            }

            private void initComponents() {
                dialogPane = new JPanel();
                contentPanel = new JPanel();
                tabs = new JTabbedPane();
                settingspanel = new JPanel();
                combatStyle = new JComboBox();
                label2 = new JLabel();
                label3 = new JLabel();
                foodid = new JComboBox();
                label4 = new JLabel();
                withdraw = new JComboBox();
                label5 = new JLabel();
                eatpercent = new JComboBox();
                label6 = new JLabel();
                lootpanel = new JPanel();
                label1 = new JLabel();
                buttonBar = new JPanel();
                okButton = new JButton();

                setResizable(false);
                Container contentPane = getContentPane();
                contentPane.setLayout(new BorderLayout());

                {
                    dialogPane.setBorder(new EmptyBorder(12, 12, 12, 12));
                    dialogPane.setLayout(new BorderLayout());

                    {
                        contentPanel.setLayout(null);

                        {
                            tabs.setFont(tabs.getFont().deriveFont(tabs.getFont().getStyle() | Font.BOLD));

                            {
                                settingspanel.setBackground(Color.white);
                                settingspanel.setLayout(null);

                                combatStyle.setModel(new DefaultComboBoxModel(new String[] {
                                    "Attack",
                                    "Strength",
                                    "Defense",
                                    "Range"
                                }));
                                settingspanel.add(combatStyle);
                                combatStyle.setBounds(185, 15, 120, combatStyle.getPreferredSize().height);

                                label2.setText("Combat Style");
                                settingspanel.add(label2);
                                label2.setBounds(15, 15, 180, 20);

                                label3.setText("Food to Eat");
                                settingspanel.add(label3);
                                label3.setBounds(15, 55, 180, 20);

                                foodid.setModel(new DefaultComboBoxModel(new String[] {
                                    "Lobster",
                                    "Swordfish",
                                    "Shark",
                                    "Monkfish",
                                    "Rocktail",
                                    "Manta Ray",
                                    "Tuna",
                                    "Bass"
                                }));
                                settingspanel.add(foodid);
                                foodid.setBounds(185, 55, 120, 20);

                                label4.setText("Withdraw Amount");
                                settingspanel.add(label4);
                                label4.setBounds(15, 95, 180, 20);

                                withdraw.setModel(new DefaultComboBoxModel(new String[] {
                                    "5",
                                    "10",
                                    "15",
                                    "20"
                                }));
                                settingspanel.add(withdraw);
                                withdraw.setBounds(240, 95, 65, 20);

                                label5.setText("Eat at Health%");
                                settingspanel.add(label5);
                                label5.setBounds(15, 135, 180, 20);

                                eatpercent.setModel(new DefaultComboBoxModel(new String[] {
                                    "85",
                                    "80",
                                    "75",
                                    "70",
                                    "65",
                                    "60",
                                    "55",
                                    "50",
                                    "45",
                                    "40"
                                }));
                                settingspanel.add(eatpercent);
                                eatpercent.setBounds(240, 135, 65, 20);

                                label6.setText("60% is best");
                                label6.setFont(label6.getFont().deriveFont(label6.getFont().getStyle() | Font.ITALIC, label6.getFont().getSize() - 1f));
                                settingspanel.add(label6);
                                label6.setBounds(175, 135, 65, 20);

                                {
                                    Dimension preferredSize = new Dimension();
                                    for(int i = 0; i < settingspanel.getComponentCount(); i++) {
                                        Rectangle bounds = settingspanel.getComponent(i).getBounds();
                                        preferredSize.width = Math.max(bounds.x + bounds.width, preferredSize.width);
                                        preferredSize.height = Math.max(bounds.y + bounds.height, preferredSize.height);
                                    }
                                    Insets insets = settingspanel.getInsets();
                                    preferredSize.width += insets.right;
                                    preferredSize.height += insets.bottom;
                                    settingspanel.setMinimumSize(preferredSize);
                                    settingspanel.setPreferredSize(preferredSize);
                                }
                            }
                            tabs.addTab("Settings", settingspanel);

                            {
                                lootpanel.setBackground(Color.white);
                                lootpanel.setLayout(null);

                                {
                                    Dimension preferredSize = new Dimension();
                                    for(int i = 0; i < lootpanel.getComponentCount(); i++) {
                                        Rectangle bounds = lootpanel.getComponent(i).getBounds();
                                        preferredSize.width = Math.max(bounds.x + bounds.width, preferredSize.width);
                                        preferredSize.height = Math.max(bounds.y + bounds.height, preferredSize.height);
                                    }
                                    Insets insets = lootpanel.getInsets();
                                    preferredSize.width += insets.right;
                                    preferredSize.height += insets.bottom;
                                    lootpanel.setMinimumSize(preferredSize);
                                    lootpanel.setPreferredSize(preferredSize);
                                }
                            }
                            tabs.addTab("Loot Options", lootpanel);

                        }
                        contentPanel.add(tabs);
                        tabs.setBounds(0, 35, 320, 205);

                        label1.setText("JustRoaches GUI");
                        label1.setFont(new Font("Verdana", Font.BOLD, 26));
                        contentPanel.add(label1);
                        label1.setBounds(new Rectangle(new Point(40, -5), label1.getPreferredSize()));

                        {
                            Dimension preferredSize = new Dimension();
                            for(int i = 0; i < contentPanel.getComponentCount(); i++) {
                                Rectangle bounds = contentPanel.getComponent(i).getBounds();
                                preferredSize.width = Math.max(bounds.x + bounds.width, preferredSize.width);
                                preferredSize.height = Math.max(bounds.y + bounds.height, preferredSize.height);
                            }
                            Insets insets = contentPanel.getInsets();
                            preferredSize.width += insets.right;
                            preferredSize.height += insets.bottom;
                            contentPanel.setMinimumSize(preferredSize);
                            contentPanel.setPreferredSize(preferredSize);
                        }
                    }
                    dialogPane.add(contentPanel, BorderLayout.CENTER);

                    {
                        buttonBar.setBorder(new EmptyBorder(12, 0, 0, 0));
                        buttonBar.setLayout(new GridBagLayout());
                        ((GridBagLayout)buttonBar.getLayout()).columnWidths = new int[] {0, 80};
                        ((GridBagLayout)buttonBar.getLayout()).columnWeights = new double[] {1.0, 0.0};

                        okButton.setText("Start Script");
                        okButton.addActionListener(new ActionListener() {
                            @Override
                            public void actionPerformed(ActionEvent e) {
                                okButtonActionPerformed(e);
                            }
                        });
                        buttonBar.add(okButton, new GridBagConstraints(1, 0, 1, 1, 0.0, 0.0,
                            GridBagConstraints.CENTER, GridBagConstraints.BOTH,
                            new Insets(0, 0, 0, 0), 0, 0));
                    }
                    dialogPane.add(buttonBar, BorderLayout.SOUTH);
                }
                contentPane.add(dialogPane, BorderLayout.CENTER);
                pack();
                setLocationRelativeTo(getOwner());
            }
            private JPanel dialogPane;
            private JPanel contentPanel;
            private JTabbedPane tabs;
            private JPanel settingspanel;
            private JComboBox combatStyle;
            private JLabel label2;
            private JLabel label3;
            private JComboBox foodid;
            private JLabel label4;
            private JComboBox withdraw;
            private JLabel label5;
            private JComboBox eatpercent;
            private JLabel label6;
            private JPanel lootpanel;
            private JLabel label1;
            private JPanel buttonBar;
            private JButton okButton;
        }

     
    }
    any of that help idk i found in a old script i had

    sorry if it was jsut a spamm or anytthing its one of the powerbot scripts so idk if it could hlep you with the double item picking up and shit buti tried?
    Last edited by Nava2; 06-09-2012 at 11:50 PM.

  25. #225
    Join Date
    Nov 2011
    Location
    England
    Posts
    3,072
    Mentioned
    296 Post(s)
    Quoted
    1094 Post(s)

    Default

    Quote Originally Posted by leftnad View Post
    sorry if it was jsut a spamm or anytthing its one of the powerbot scripts so idk if it could hlep you with the double item picking up and shit buti tried?
    Triple post... spamming like crazy with a script that is java and is nothing to do with simba, regardless he wont add custom looting because #1 currently he doesn't even have a pc and #2 because of colours.

Page 9 of 10 FirstFirst ... 78910 LastLast

Thread Information

Users Browsing this Thread

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

Posting Permissions

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