Jump to content

Lol_marcus

Members
  • Posts

    201
  • Joined

  • Last visited

  • Days Won

    1
  • Feedback

    0%

Everything posted by Lol_marcus

  1. My guy! That makes so much more sense! Plus it opens up so many possibilities. Thank you!
  2. So I did some quick reading, but I still don't quite understand what the lack of the "@Override" handler for the 2nd and 3rd onLoops will do to my script, if anything at all? I'm using a simple drop down menu for the options. I've run to all banks and it works fine. When I ask if it'll work in the long run is, if I have a script that loops. Like a WCing script. If I give it the option to cut willows, and the other oaks, will it keep running fine without the Override? package core; import javax.swing.JOptionPane; import org.osbot.rs07.api.map.constants.Banks; import org.osbot.rs07.script.Script; import org.osbot.rs07.script.ScriptManifest; @ScriptManifest(name = "Bank Walker", version = 1, author = "Marcus", logo = "", info = "Walks and runs to banks") public class Main extends Script { @Override public void onStart() throws InterruptedException { String userOptions[] = {"Varrock", "Falador", "Edgeville"}; String userChoice = ""+(String)JOptionPane.showInputDialog(null, "Choose a location", "Bank Walker", JOptionPane.PLAIN_MESSAGE, null, userOptions, userOptions[1]); if(userChoice.equals("Varrock")) { onLoop(); } else if (userChoice.equals("Falador")) { onLoop2(); } else if (userChoice.equals("Edgeville")) { onLoop3(); } else { stop(false); } } @Override public int onLoop() throws InterruptedException { if (Banks.GRAND_EXCHANGE.contains(myPosition())) { stop(false); } else { combat.toggleAutoRetaliate(false); getWalking().webWalk(Banks.GRAND_EXCHANGE); } return 700; } public int onLoop2() throws InterruptedException { if (Banks.FALADOR_WEST.contains(myPosition())) { stop(false); } else { combat.toggleAutoRetaliate(false); getWalking().webWalk(Banks.FALADOR_WEST); } return 700; } public int onLoop3() throws InterruptedException { if (Banks.EDGEVILLE.contains(myPosition())) { stop(false); } else { combat.toggleAutoRetaliate(false); getWalking().webWalk(Banks.EDGEVILLE); } return 700; } }
  3. As far as I know WebWalking does all the interaction with objects. Maybe get the coords of where you want your character to go and let WebWalking do the rest?
  4. Misread what your error was. Let me take another look.
  5. Any ETA for future updates, such as more patches? Love the script so far.
  6. 40-50m. It'd depend on combat as well tbh. Bulk of the value would be access to crafting guild's bank. The skill itself isn't too desirable because there aren't too many money making methods related only to it, if that makes sense.
  7. Hi all, This is the very first version of the script. It runs flawlessly until it runs into unexpected problems. Some of them have been worked out, but further testing is being done to iron out all the problems. I'll be continuing to work on the script, making it more efficient and fail-safe with the intention of making it 100% flawless. new I've released a second version. It's better than the first in many aspects. You can start anywhere inside or outside your house and it'll do the rest. I've tested it until 82 construction and it didn't fail me, the longest I ran it was for 2.5 hours. Future updates to come and I slowly work on making it cleaner and more efficient. Any feedback is always more than welcome. FEATURES Makes oak larders Exchanges oak plank notes for unnoted with Phials Gets +- 80k construction xp/ph new Cool little pop up message in the beginning new Run time, XP gained and XP/ph is shown new Shows mouse trail so you know how to bot is doing everything (plus it's rainbow colored) INVENTORY SETUP - make sure these are the ONLY items in your inventory Saw Hammer Coins Noted Oak planks (and unnoted if you'd like to start straight away) HOW TO RUN - make sure you start ONLY once inside your house Start inside your house (preferable close to portal or larder) new Start anywhere inside or outside your house Have your house set to Rimmington Ideally have your camera set to half way, or further out new The script will adjust the camera by itself HOW TO ADD SCRIPT TO YOUR CLIENT Download the ConstructionLite.jar file Copy and paste it into: C:\Users\*YOURUSERNAME*\OSBot\Scripts New Source Code - you would have to remove the custom mouse and zoom control for it to work, because it's a separate class file package core; import org.osbot.rs07.api.map.Area; import org.osbot.rs07.api.model.NPC; import org.osbot.rs07.api.model.RS2Object; import org.osbot.rs07.api.ui.RS2Widget; import org.osbot.rs07.api.ui.Skill; import org.osbot.rs07.script.Script; import org.osbot.rs07.script.ScriptManifest; import org.osbot.rs07.utility.ConditionalSleep; import utils.MouseTrail; import utils.ZoomControl; import java.awt.*; import java.net.MalformedURLException; import java.net.URL; import javax.swing.ImageIcon; import javax.swing.JOptionPane; @ScriptManifest(name = "Construction Lite V1.1", version = 1.1, author = "Marcus", logo = "", info = "Creates oak larders") public class Main extends Script { private final Area portalPos = new Area(2953,3222,2954,3224); private final Area phialsPos = new Area(2951,3213,2952,3214); private MouseTrail trail = new MouseTrail(0, 255, 255, 2000, this); private long startTime = System.currentTimeMillis(); @Override public void onStart() throws InterruptedException { ImageIcon icon = null; try { icon = new ImageIcon(new URL("https://vignette.wikia.nocookie.net/2007scape/images/6/65/Demon_butler_chathead.png/revision/latest?cb=20151103211007")); } catch (MalformedURLException e) { // TODO Auto-generated catch block e.printStackTrace(); } JOptionPane.showMessageDialog(null, "MAKE SURE YOU HAVE COINS, OAK PLANKS, A SAW AND A HAMMER", "Construction Lite", JOptionPane.INFORMATION_MESSAGE, icon); getExperienceTracker().start(Skill.CONSTRUCTION); if (!ZoomControl.isInRange(getCamera().getScaleZ(), 500)) { ZoomControl.setZoom(getBot(), 500); } } @Override public int onLoop() throws InterruptedException { if(hasPlanks()){ if(larderExists()){ interactLarder(); }else{ goHome(); } }else{ if(larderExists()){ exitHome(); }else{ getMaterials(); unnote(); getAll(); } } return 700; } private boolean larderExists(){ return (getObjects().closest("Larder space") != null || getObjects().closest("Larder") != null); } public boolean hasPlanks() { return (inventory.contains(8794,2347,995,8779) && (inventory.contains(8778) && inventory.getAmount(8778) >= 8)); } public void interactLarder() throws InterruptedException { RS2Object larder = getObjects().closestThatContains("Larder"); if (larder != null); { if (larder.hasAction("Build")){ larder.interact("Build"); sleep(random(900, 1200)); buildit(); } else if (larder.hasAction("Remove")){ larder.interact("Remove"); sleep(random(900, 1200)); removeit(); } new ConditionalSleep(500, 20) { @Override public boolean condition() throws InterruptedException { return (getInventory().isEmptyExcept(8794,2347,995,8779)); } }.sleep(); } } public void buildit() throws InterruptedException { RS2Widget furni = getWidgets().get(458, 1); RS2Object larder = getObjects().closestThatContains("Larder"); if (furni != null && furni.isVisible()) { keyboard.typeString("2"); new ConditionalSleep(200, 20) { @Override public boolean condition() { return (!larder.hasAction("Build")); } }.sleep(); } } public void removeit() throws InterruptedException { RS2Widget furni2 = getWidgets().getWidgetContainingText(219,"Really remove it?"); RS2Object larder = getObjects().closestThatContains("Larder"); if (furni2 != null && furni2.isVisible()) { keyboard.typeString("1"); new ConditionalSleep(200, 20) { @Override public boolean condition() { return (!larder.hasAction("Remove")); } }.sleep(); } } private void exitHome() throws InterruptedException { RS2Object portal = getObjects().closest("Portal"); if (portal != null && getMap().isInHouse()) { portal.interact("Enter"); sleep(random(1000, 1500)); new ConditionalSleep(3000, 50) { @Override public boolean condition() { return (!getMap().isInHouse()); } }.sleep(); } } private void getMaterials() throws InterruptedException { NPC Phials = npcs.closest("Phials"); if(getInventory().isEmptyExcept(8794,2347,995,8779)) { if(!Phials.isVisible()) { getWalking().walk(phialsPos); sleep(random(500, 1000)); { } } } } public void unnote() throws InterruptedException { NPC Phials = npcs.closest("Phials"); RS2Widget widget = getWidgets().getWidgetContainingText(219,"Exchange All: 120 coins"); if(getInventory().isEmptyExcept(8794,2347,995,8779)) { if (!getInventory().isItemSelected()) { getInventory().getItem("Oak plank").interact("use"); sleep(random(250, 750)); if (Phials != null && Phials.isVisible()){ Phials.interact(); } new ConditionalSleep(3000, 50) { @Override public boolean condition() { return (widget != null && widget.isVisible()); } }.sleep(); } } } public void getAll() throws InterruptedException { RS2Widget widget = getWidgets().getWidgetContainingText(219,"Exchange All: 120 coins"); if(getInventory().isEmptyExcept(8794,2347,995,8779)) { if (widget != null && widget.isVisible()) { dialogues.selectOption("Exchange All: 120 coins"); sleep(random(250, 750)); new ConditionalSleep(1500, 20) { @Override public boolean condition() { return getInventory().contains(8778); } }.sleep(); }else{ stop(false); } } } private void goHome() throws InterruptedException { RS2Object portal = getObjects().closest("Portal"); if(getInventory().isEmptyExcept(8794,2347,995,8778,8779)) { if (portal != null && !portal.isVisible()) { getWalking().walk(portalPos); sleep(random(500, 1000)); }else if (portal != null && portal.isVisible()) { portal.interact("Build mode"); new ConditionalSleep(3000, 20) { @Override public boolean condition() { return getMap().isInHouse(); } }.sleep(); } } } @Override public void onPaint(Graphics2D g) { int cXp = getExperienceTracker().getGainedXP(Skill.CONSTRUCTION); int cXpph = getExperienceTracker().getGainedXPPerHour(Skill.CONSTRUCTION); int lvl = getSkills().getDynamic(Skill.CONSTRUCTION); g.setColor(new Color(0, 0, 0, 155)); g.fillRect(5, 238, 238, 99); g.setColor(new Color(255, 255, 255)); g.drawRect(5, 238, 238, 99); g.setFont(g.getFont().deriveFont(14.0f)); trail.paint(g); Point mP = getMouse().getPosition(); g.drawLine(mP.x, 501, mP.x, 0); g.drawLine(0, mP.y, 764, mP.y); super.onPaint(g); g.drawString("Construction level(Current): " + lvl, 15, 295); g.drawString("Construction XP: " + cXp, 15, 310); g.drawString("Construction XP/PH: " + cXpph, 15, 325); g.drawString("Construction Lite", 65, 255); g.drawString("Run time: " +String.valueOf(formatTime(System.currentTimeMillis() - startTime)), 15, 275); } private String formatTime(final long ms){ long s = ms / 1000, m = s / 60, h = m / 60; s %= 60; m %= 60; h %= 24; return String.format("%02d:%02d:%02d", h, m, s); } } ConstructionLite.jar Construct.jar
  8. Let me try to explain better. So, if the first statement isn't being met, it's shutting down. What I can't figure out is, if the larder has already been made, why isn't it going to the "else" statement? This would happen if for example someone started the script with the larder already made in the house, does that make sense? public int onLoop() throws InterruptedException { if (hasPlanks()) { makeLarder(); } else if (hasLarder()) { removeLarder(); Oh wow. I didn't even know there was that function! I'll try to implement this, could be the solution I was looking for! Thanks
  9. Hi all, Questions: The script runs fine if I start it with the Larder space is empty, but if I start it with something in the larder space, it doesn't do anything. Why? Do I have to declare the RS2Objects over and over again, or will it recognize if I declare it once at the beginning of the script? package core; import org.osbot.rs07.api.model.RS2Object; import org.osbot.rs07.api.ui.Skill; import org.osbot.rs07.script.Script; import org.osbot.rs07.script.ScriptManifest; import org.osbot.rs07.utility.ConditionalSleep; import java.awt.*; @ScriptManifest(name = "Construction Lite", version = 1, author = "Marcus", logo = "", info = "Creates oak larders") public class Main extends Script { @Override public void onStart() throws InterruptedException { getExperienceTracker().start(Skill.CONSTRUCTION); } @Override public int onLoop() throws InterruptedException { if (hasPlanks()) { makeLarder(); } else if (hasLarder()) { removeLarder(); } return 700; } public boolean hasPlanks() { return (inventory.contains(8794,2347,995,8779) && (inventory.contains(8778) && inventory.getAmount(8778) >= 8)); } public void makeLarder() throws InterruptedException { RS2Object larder = getObjects().closest("Larder space"); if (larder != null); { larder.interact("Build"); sleep(random(1600, 2000)); keyboard.typeString("2"); sleep(random(750, 900)); new ConditionalSleep(1800, 100) { @Override public boolean condition() throws InterruptedException { return getInventory().isEmptyExcept(8794,2347,995,8779); } }.sleep(); } } public boolean hasLarder() { RS2Object oaklarder = getObjects().closest("Larder"); return (oaklarder != null); } public void removeLarder() throws InterruptedException { RS2Object oaklarder = getObjects().closest("Larder"); if (oaklarder != null); { oaklarder.interact("Remove"); sleep(random(1600, 2000)); keyboard.typeString("1"); sleep(random(750, 900)); } } @Override public void onPaint(Graphics2D paint) { int cXp = getExperienceTracker().getGainedXP(Skill.CONSTRUCTION); int cXpph = getExperienceTracker().getGainedXPPerHour(Skill.CONSTRUCTION); super.onPaint(paint); paint.drawString("Construction XP: " + cXp, 387, 328); paint.drawString("Construction XP/ph: " + cXpph, 387, 313); } }
  10. I have almost 100 zulrah kills on the account. How is it not zulrah ready? Please read the post... 30M starting bid.
  11. What are these people even saying? If you meet all the requirements to sell the account, and can provide all the details on a recovery test, the account could be worth close to 100M. Why? It's a NMZ ready account It has a firecape 70 Slayer / slayer helm 70 Agility
  12. Bipity bopity bumpity humpity. How often are we allowed to bump threads?
  13. Hi all, This account was made with the intention of selling. It is blowpipe ready. It can use and wield (50 attack required) Ibans staff which has a max of 25 when casting Ibans blast. 1. Pictures of the account stats 2. Pictures of the total wealth (if there is any) Magic shortbow (i) - scroll to imbue it worth 200k+ Ibans staff Avas accumulator 3. Pictures of the quests completed 4. The price you will be starting bids at 30M 07gp. 5. The A/W (Auto-win) for your account 65M 07gp. 6. The methods of payment you are accepting 07gp only 7. Your trading conditions Will only trade if you're highly trusted, or through a MM. 8. Pictures of the account status 9. Original/previous owners AND Original Email Address I am the OO and the holder of the e-mail address.
  14. Awesome! Great updates ^^ I'll test it out and let you know how it goes
  15. Probably 7m. Although it has a 99, it's not a particularity lucrative 99 skill, nor a very sought out one at that. The max you could make is circa 300-400k p/h if I remember correctly. And that kind of gp/ph is do-able on some pretty low level stat accounts, such as unf. potion makers. You'd be getting paid for the fact it does have a 99 though.
  16. Thanks for the input. I'll try them out and see if it makes the script better. I had random sleeps between withdrawing the seaweed, but the clicks were too slow to be human-like. When you're getting 3 of the same thing out of the bank it's literally split seconds between the clicks. With the sleep I noticed it would click some-what slow. Any idea why?
  17. Roughly 20-25m. Having 50 or 60 thieving wouldn't make such a big difference, because it's only 170k xp. When you start ardy knights at 55 you're getting around 50-60k xp/ph, which would get you to 60 in 2 hours or so. If you're making the accounts to sell, I'd stick to getting them to 50 thieving/agility with rogues set. If you want to get more value out of the accounts I'd say try to get a thieving level of 80, which you can then use to start farming Master Farmers with decent profit.
  18. Fixed the script, for anyone who's actively looking for a NMZ script. I had to remove a few things, not sure if they're older code that the client doesn't recognize anymore. I've tested the script for 25 minutes and it works fine. You can find the .jar at the end of the post. package core; import java.awt.BasicStroke; import java.awt.Color; import java.awt.Font; import java.awt.Graphics; import java.awt.Graphics2D; import java.awt.Point; import java.awt.RenderingHints; import java.util.ArrayList; import java.util.List; import org.osbot.rs07.api.map.Area; import org.osbot.rs07.api.map.Position; import org.osbot.rs07.api.model.NPC; import org.osbot.rs07.api.model.Player; import org.osbot.rs07.api.ui.Skill; import org.osbot.rs07.api.ui.Tab; import org.osbot.rs07.script.Script; import org.osbot.rs07.script.ScriptManifest; @ScriptManifest(author = "Mgt Madness", info = "Nightmare Zone", name = "Nmz", version = 1.1, logo = "") public class Main extends Script { private final Color BACKGROUND_COLOUR = new Color(0, 0, 0, 80); private final Color BACKGROUND_OUTLINE_CLOUR = new Color(0, 0, 0, 80); private final Color MAIN_TEXT_COLOUR = new Color(102, 188, 255); private final BasicStroke stroke1 = new BasicStroke(1); private final Font font1 = new Font(Font.SANS_SERIF, 0, 12); private final int X = -134; private final int Y = 85; private final int BOX_ARC_AMOUNT = 8; private final String[] ABSORBTION_POTIONS = {"Absorption (1)", "Absorption (2)", "Absorption (3)", "Absorption (4)"}; private final String[] OVERLOAD_POTIONS = {"Overload (1)", "Overload (2)", "Overload (3)", "Overload (4)"}; private long timeScriptStarted = System.currentTimeMillis(); private String status = ""; private ArrayList<String> skillsExperienceStart = new ArrayList<String>(); private ArrayList<String> skillsExperienceGained = new ArrayList<String>(); private long timeToDrinkOverload; private int absorbtionDosesToDrink; private long timeCanCake; @Override public void onStart() { setStatus("Script started."); for (Skill data : Skill.values()) { skillsExperienceStart.add(data.name() + ":" + skills.getExperience(data)); } } @Override public int onLoop() throws InterruptedException { if (skills.getDynamic(Skill.HITPOINTS) == 0) { setStatus("Player is 0 hp."); } if (areaHasPlayers()) { setStatus("Area has players, stop script"); stop(); } updateExperienceGained(); overload(); absorbtion(); antiBan(); cake(); return random(500, 1000); } private void cake() { if (System.currentTimeMillis() < timeCanCake) { return; } if (System.currentTimeMillis() < timeToDrinkOverload) { return; } if (skills.getDynamic(Skill.STRENGTH) > skills.getStatic(Skill.STRENGTH)) { if (skills.getDynamic(Skill.HITPOINTS) > 2) { setStatus("Eat"); inventory.interact(random(1, 15) == 1 ? "Guzzle" : "Eat", "Dwarven rock cake"); moveMouse(3); } else if (skills.getDynamic(Skill.HITPOINTS) == 2) { long delay = random(61000, 170000); if (random(1, 7) == 1) { delay = random(170000, 360000); } if (random(1, 6) == 1) { // Do not guzzle. } else { setStatus("Eat"); inventory.interact("Guzzle", "Dwarven rock cake"); } moveMouse(3); timeCanCake = System.currentTimeMillis() + delay; } } } private void moveMouse(int i) { // TODO Auto-generated method stub } private void antiBan() throws InterruptedException { if (random(1, 200) == 1) { setStatus("Anti-ban random mouse movement"); moveMouse(1); } if (random(1, 300) == 1) { moveMouse(2); if (skills.getCombat().getSpecialPercentage() >= 55) { skills.getCombat().toggleSpecialAttack(true); setStatus("Anti-ban special attack activated"); } } if (random(1, 300) == 1) { int random = random(1, 50); if (random <= 5) { absorbtionDosesToDrink = random(1, 2); setStatus("Anti-ban drink abosrbtion"); sleep(random(2000, 10000)); skills.getMouse().moveOutsideScreen(); } else if (random <= 25) { attackRandomTarget(); } else if (random <= 30) { getWalking().walk(new Position((myPlayer().getX() - 10) + random(0, 10), (myPlayer().getY() - 10) + random(0, 10), myPlayer().getHeight())); setStatus("Anti-ban walk"); sleep(random(2000, 10000)); skills.getMouse().moveOutsideScreen(); } else if (random <= 40) { random = random(1, 10); if (random <= 4) { setStatus("Anti-ban friends"); getTabs().open(Tab.FRIENDS); sleep(random(3000, 10000)); getTabs().open(Tab.INVENTORY); } else if (random <= 7) { setStatus("Anti-ban attack tab"); getTabs().open(Tab.ATTACK); sleep(random(3000, 7000)); getTabs().open(Tab.INVENTORY); } else if (random <= 10) { setStatus("Anti-ban skills tab"); getTabs().open(Tab.SKILLS); sleep(random(4000, 12000)); getTabs().open(Tab.INVENTORY); } sleep(random(2000, 10000)); skills.getMouse().moveOutsideScreen(); } else if (random <= 50) { if (System.currentTimeMillis() < timeCanCake) { attackRandomTarget(); return; } if (skills.getDynamic(Skill.HITPOINTS) > 1) { setStatus("Anti-ban eat"); inventory.interact(random(1, 2) == 1 ? "Guzzle" : "Eat", "Dwarven rock cake"); } sleep(random(2000, 10000)); skills.getMouse().moveOutsideScreen(); } } } private void attackRandomTarget() throws InterruptedException { List<NPC> allNpcs = npcs.getAll(); for (int index = 0; index < allNpcs.size(); index++) { NPC npc = allNpcs.get(index); if (npc == null) { continue; } if (!npc.exists()) { continue; } if (!npc.isOnScreen()) { continue; } if (random(1, 2) == 1) { continue; } npc.interact("Attack"); setStatus("Anti-ban switch target"); sleep(random(2000, 10000)); skills.getMouse().moveOutsideScreen(); break; } } private void absorbtion() { if (absorbtionDosesToDrink > 0) { setStatus("Drinking absorbtion"); inventory.interact("Drink", ABSORBTION_POTIONS); moveMouse(10); absorbtionDosesToDrink--; if (absorbtionDosesToDrink == 0) { timeCanCake = System.currentTimeMillis() + random(500, 7000); } } } private void overload() throws InterruptedException { if (skills.getDynamic(Skill.HITPOINTS) < 51) { return; } if (timeToDrinkOverload == 0) { if (skills.getDynamic(Skill.STRENGTH) == skills.getStatic(Skill.STRENGTH)) { setStatus("Will overload shortly"); long delay = random(2000, 20000); if (random(1, 6) == 1) { delay = random(20000, 120000); setStatus("Will overload longly"); } timeToDrinkOverload = System.currentTimeMillis() + delay; } return; } if (System.currentTimeMillis() > timeToDrinkOverload) { setStatus("Drinking overload"); timeCanCake = System.currentTimeMillis() + random(10000, 25000); inventory.interact("Drink", OVERLOAD_POTIONS); timeToDrinkOverload = 0; moveMouse(3); sleep(random(1000, 8000)); absorbtionDosesToDrink = random(2, 7); } } @Override public void onExit() { setStatus("Script ended."); } @Override public void onPaint(Graphics2D g) { int ySize = skillsExperienceGained.size() * 16; g.setColor(BACKGROUND_COLOUR); g.fillRoundRect(143 + X, 8 + Y, 211, 40 + ySize, BOX_ARC_AMOUNT, BOX_ARC_AMOUNT); g.setColor(BACKGROUND_OUTLINE_CLOUR); g.setStroke(stroke1); g.drawRoundRect(143 + X, 8 + Y, 211, 40 + ySize, BOX_ARC_AMOUNT, BOX_ARC_AMOUNT); g.setFont(font1); g.setColor(MAIN_TEXT_COLOUR); g.drawString("Duration: " + getRuntime(), 147 + X, 24 + Y); g.drawString("Last action: " + status, 147 + X, 40 + Y); for (int index = 0; index < skillsExperienceGained.size(); index++) { g.drawString(skillsExperienceGained.get(index), 147 + X, 40 + Y + ((index + 1) * 16)); } drawMouse(g); } private void setStatus(String status) { log("Status: " + status); this.status = status; } /** * Get time since script started. */ private String getRuntime() { long seconds = (System.currentTimeMillis() - timeScriptStarted) / 1000; if (seconds < 60) { return seconds + "s"; } else if (seconds < 3600) { int remainder = (int) (seconds / 60); if (60 * remainder < seconds) { remainder = (int) (seconds - (60 * remainder)); } else { remainder = 0; } return (seconds / 60) + "m " + remainder + "s"; } else { int remainderMinutes = (int) seconds / 3600; int seconds1 = 0; if (3600 * remainderMinutes < seconds) { remainderMinutes = (int) (seconds - (3600 * remainderMinutes)); seconds1 = remainderMinutes; remainderMinutes /= 60; int remainder = (int) (seconds1 / 60); if (60 * remainder < seconds1) { remainder = (int) (seconds1 - (60 * remainder)); } else { remainder = 0; } seconds1 = remainder; } else { remainderMinutes = 0; } return (seconds / 3600) + "h " + remainderMinutes + "m " + seconds1 + "s"; } } /** * @return * The number in thousands with k at the end. */ private String getFormattedRunescapeNumber(int amount) { if (amount >= 1000) { return (amount / 1000) + "k"; } else { return amount + ""; } } private void updateExperienceGained() { int index = 0; skillsExperienceGained.clear(); for (Skill data : Skill.values()) { int currentXp = skills.getExperience(data); String[] parse = skillsExperienceStart.get(index).split(":"); int startXp = Integer.parseInt(parse[1]); if (currentXp > startXp) { int totalXp = currentXp - startXp; skillsExperienceGained.add(capitalize(parse[0]) + " xp: " + getFormattedRunescapeNumber(totalXp) + " (" + getFormattedRunescapeNumber(getExperienceperHour(totalXp)) + "/h)"); } index++; } } public int getExperienceperHour(int totalExperienceGained) { int minutes = (int) ((System.currentTimeMillis() - timeScriptStarted) / 60000); int beforeSeconds = 0; double multiplier = 1.0; if (minutes < 60) { beforeSeconds = (int) ((System.currentTimeMillis() - timeScriptStarted) / 1000); multiplier = 3600.0 / (double) beforeSeconds; minutes = 60; } double convert = (double) minutes; convert = convert / 60.0; return (int) ((totalExperienceGained / convert) * multiplier); } /** * Capitalize the first letter and other letters that before it is a space. * @param s * @return */ public static String capitalize(String s) { s = s.toLowerCase(); for (int i = 0; i < s.length(); i++) { if (i == 0) { s = String.format("%s%s", Character.toUpperCase(s.charAt(0)), s.substring(1)); } if (!Character.isLetterOrDigit(s.charAt(i))) { if (i + 1 < s.length()) { s = String.format("%s%s%s", s.subSequence(0, i + 1), Character.toUpperCase(s.charAt(i + 1)), s.substring(i + 2)); } } } return s; } public boolean areaHasPlayers() { Area area = myPlayer().getArea(10);//create your own area int amount = 0; for (Player player : players.getAll()) { if (player != null && !player.getName().equalsIgnoreCase(myPlayer().getName())) { if (area.contains(player)) { amount++; } } } return amount > 0; } public void drawMouse(Graphics g) { ((Graphics2D) g).setRenderingHints(new RenderingHints(RenderingHints.KEY_ANTIALIASING, RenderingHints.VALUE_ANTIALIAS_ON)); Point p = mouse.getPosition(); Graphics2D spinG = (Graphics2D) g.create(); Graphics2D spinGRev = (Graphics2D) g.create(); spinG.setColor(new Color(255, 255, 255)); spinGRev.setColor(Color.cyan); spinG.rotate(System.currentTimeMillis() % 2000d / 2000d * (360d) * 2 * Math.PI / 180.0, p.x, p.y); spinGRev.rotate(System.currentTimeMillis() % 2000d / 2000d * (-360d) * 2 * Math.PI / 180.0, p.x, p.y); final int outerSize = 20; final int innerSize = 12; spinG.setStroke(new BasicStroke(1.0f, BasicStroke.CAP_ROUND, BasicStroke.JOIN_ROUND)); spinGRev.setStroke(new BasicStroke(1.0f, BasicStroke.CAP_ROUND, BasicStroke.JOIN_ROUND)); spinG.drawArc(p.x - (outerSize / 2), p.y - (outerSize / 2), outerSize, outerSize, 100, 75); spinG.drawArc(p.x - (outerSize / 2), p.y - (outerSize / 2), outerSize, outerSize, -100, 75); spinGRev.drawArc(p.x - (innerSize / 2), p.y - (innerSize / 2), innerSize, innerSize, 100, 75); spinGRev.drawArc(p.x - (innerSize / 2), p.y - (innerSize / 2), innerSize, innerSize, -100, 75); } } NMZ.jar
  19. It depends if the account was quested or not. Those stats can easily be attained in a day of doing/botting p2p quests. I'd say somewhere between 3-6M.
  20. I believe myself to be a very fast learner as well as having some knowledge of other programming languages. I might not know a whole lot about JAVA, but I'm familiar with structuring code and implementing logic/flow. I'd excel more if I learned the actual way scripts are made and structured rather than learning basic "Hello world!" things, if that makes sense? I know how to do everything you've mentioned in regards to randomizing the actions. I had it originally in my script, but decided to remove it for the sake of XP. With all the randomizing I had on the script I was losing circa 20k xp/ph between magic and crafting, and for a throwaway account, the increase in ban potential outweighed the xp and gp /ph loss.
  21. Ah! I didn't notice I kept the same method names from my previous script! ^^ I had made a lunar spell hide tanner beforehand. The custom interaction sounds like a great idea! If it's not too much of a hassle, would you mind giving me a snippet of your custom inventory interaction event? If not I'll look through other scripts and have a gander with the API. Thanks for the input! I had originally left sleep(random(x,y))'s throughout the script, but I felt it made it messy, and removed them. I'll take a look into implementing it again, but with cleaner code. Thanks for the input and the offer to help, that's very kind of you!
  22. Hi all, this is a very simple GE Walker/Runner for people who are: Too lazy to walk to the GE Fresh off of Tutorial Island and are still, too lazy to walk to the GE Have just died, gone to the bank, realized you have no runes or teleport tabs, and are way too lazy to walk to the GE Features Will turn off auto-retaliate (in case you're coming from Lumbridge as a fresh level 3 and are attacked by those pesky dark wizards) Will turn on run if it's above 15 Uses Webwalking, which means it'll climb up/down stairs, open doors, and basically figure out the best way to the GE Ideally you're not going to want to start this from the other side of the map. If that is the case for your character, you're better off teleporting to Lumbridge first and only then running the script. Downloading the script You can find the .jar download at the end of the post and add it to: C:\Users\*YOURUSERNAME*\OSBot\Scripts or Source code package core; import org.osbot.rs07.api.map.constants.Banks; import org.osbot.rs07.script.Script; import org.osbot.rs07.script.ScriptManifest; @ScriptManifest(name = "GE Walker", version = 1, author = "Marcus", logo = "", info = "Walks and runs to the GE") public class Main extends Script { @Override public int onLoop() throws InterruptedException { if (Banks.GRAND_EXCHANGE.contains(myPosition())) { stop(true); } else { combat.toggleAutoRetaliate(false); getWalking().webWalk(Banks.GRAND_EXCHANGE); } return 700; } } Thanks and enjoy. Any feedback as well is more than welcome. GE Walker.jar
  23. That makes perfect sense, and the way you've written it out is great for visual learners like myself. Thanks for the input.
  24. Hi all, This script steals from either of the fruit stalls located in the houses in Kourend. Script features Uses either of the stalls inside the house Drops everything found in the inventory before beginning Uses a "Pick 1 Drop 1" method Though the task is fairly simple, the script does not offer any anti-bans, and its sole purpose is to steal the fruit to maximize XP/ph, so as with any bot, use it at your own discretion. Thanks and enjoy! To add the script; Download the .jar file and add it to your C:\Users\*YOURUSERNAME*\OSBot\Scripts folder. Open up Osbot and refresh the bot list, and it should come up as "Fruit Stall Thiever". or Scripts Source Code package core; import java.awt.Graphics2D; import org.osbot.rs07.api.model.RS2Object; import org.osbot.rs07.api.ui.Skill; import org.osbot.rs07.script.Script; import org.osbot.rs07.script.ScriptManifest; @ScriptManifest(author = "Marcus", info = "Steals fruits", name = "Fruit Stall Thiever", version = 1, logo = "") public class Main extends Script { @Override public void onStart() throws InterruptedException { getExperienceTracker().start(Skill.THIEVING); } @Override public int onLoop() throws InterruptedException { RS2Object stall = getObjects().closest("Fruit Stall"); if (!getInventory().isEmpty()) { getInventory().dropAll(); } else if (stall != null && !myPlayer().isAnimating()) { stall.interact("Steal-from"); } return 700; } @Override public void onPaint(Graphics2D paint) { int tXp = getExperienceTracker().getGainedXP(Skill.THIEVING); int tXpph = getExperienceTracker().getGainedXPPerHour(Skill.THIEVING); super.onPaint(paint); paint.drawString("Thieving XP: " + tXp, 387, 328); paint.drawString("Thieving XP/PH: " + tXpph, 387, 313); } } Fruit stalls.jar
  25. That's never occurred to me, but now that you mentioned it is ridiculously nonhuman-like that the bots do that. I can attest however that from past experience, the speed at which you click something isn't necessarily important. I've had a few accounts get 99 cooking by doing bank standing activities with color bots, and in those clients the mouse would jump from point A to point B around the screen, without leaving a mouse trail, if that makes sense? I believe as well that client detection is something more important than a lot of people give it credit. I've had accounts go on for weeks whilst being heavily botted through the official client/mirror mode, and then other accounts get the ban hammer the day after when doing the exact same activities, but on "injection" mode.
×
×
  • Create New...