Jump to content
View in the app

A better way to browse. Learn more.

OSBot :: 2007 OSRS Botting

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Open AFK Splasher | Free & Open Source

Featured Replies

Open AFK Splasher by Eliot

What:

  • It splashes autocast spells
  • Moves mouse to prevent your character from not retaliating
  • Logs back in and attacks NPC after being logged out by 6 hour timer

How:

  1. Have at least -65 magic bonus & have an autocast spell selected
  2. Attack the NPC you wish to splash on (suggestion: spiders, chickens)
  3. Start script

Why:

  • Splashing requires very few interactions with the client, drastically decreasing the chance of being banned.

Source:

import org.osbot.rs07.api.model.NPC;
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 = "Open AFK Splasher", author = "Eliot", version = 1.0, info = "", logo = "")

public class Splasher extends Script {
  private long startTime;
  private String npcName = null;
  private String state = "Initializing";
  private Font font = new Font("Arial", Font.BOLD, 14);

  /**
   * Formats time ran into a human readable String
   * @param time the time in ms to be converted
   * @return (Human readable) how long the script has been running
   */
  public final String formatTime(final long time) {
    long s = time / 1000, m = s / 60, h = m / 60;
    s %= 60; m %= 60; h %= 24;
    return String.format("%02d:%02d:%02d", h, m, s);
  }

  @Override
  public void onStart() {
    startTime = System.currentTimeMillis();
    getExperienceTracker().start(Skill.MAGIC);
  }

  @Override
  public int onLoop() throws InterruptedException {
    if (npcName == null && myPlayer().getInteracting() != null) {
      npcName = myPlayer().getInteracting().getName();
    } else if (npcName != null && myPlayer().getInteracting() == null) {
      state = "Attacking " + npcName;
      NPC attack = getNpcs().closest(npc -> npc.getName().equals(npcName) && npc.getInteracting() == null);
      if (attack != null && attack.interact("Attack")) {
        new ConditionalSleep(5000) {
          @Override
          public boolean condition() throws InterruptedException {
            return myPlayer().isUnderAttack();
          }
        }.sleep();
      }
    } else if (npcName != null) {
      state = "Preventing AFK timer";
      if (mouse.click(random(556, 730), random(220, 450), false)) {
        int randomTime = random(180000, 1080000);
        state = "Sleeping (for " + formatTime(randomTime) + ")";
        new ConditionalSleep(randomTime) {
          @Override
          public boolean condition() throws InterruptedException {
            return myPlayer().getInteracting() == null;
          }
        }.sleep();
      }
    } else {
      state = "YOU MUST ATTACK SOMETHING MANUALLY";
    }
    return 100;
  }

  @Override
  public void onPaint(Graphics2D g) {
    Point mP = getMouse().getPosition();
    long runTime = System.currentTimeMillis() - startTime;
    g.setColor(Color.white);
    g.setFont(font);
    g.drawLine(mP.x, 501, mP.x, 0);
    g.drawLine(0, mP.y, 764, mP.y);
    g.drawString("State: " + state, 10, 210);
    g.drawString("Target: " + (npcName == null ? "????" : npcName), 10, 230);
    g.drawString("XP Gained: "+ getExperienceTracker().getGainedXP(Skill.MAGIC), 10, 250);
    g.drawString("XP / HR: "+ getExperienceTracker().getGainedXPPerHour(Skill.MAGIC), 10, 270);
    g.drawString("Time to LVL: "+ formatTime(getExperienceTracker().getTimeToLevel(Skill.MAGIC)), 10, 290);
    g.drawString("Time Ran: "+ formatTime(runTime), 10, 310);
  }
}

I suggest compiling on your own, but if you'd rather download a jar click here.

 

Credits:
Some aspects of this script were taken from @Mumble's script: https://osbot.org/forum/topic/116394-mumbles-ez-afk-splasher/

 

 

Find a bug? Report it in this thread.

Edited by Eliot

:gnome:TFW I finally thought you released your alcher. 

But I'm probably gonna use this :P Thanks hombre. 

  • Author
1 hour ago, Turkoize said:

:gnome:TFW I finally thought you released your alcher. 

But I'm probably gonna use this :P Thanks hombre. 

Hah, maybe someday.

1 hour ago, Botre said:

 50 * new font / second

:boge:

:troll: fixed

1 hour ago, Mumble said:

Great work, and thanks for giving me credit! (some people wouldn't)

Np.

  • 2 weeks later...
  • 2 weeks later...
  • 4 weeks later...
  • 2 weeks later...

Could you please reupload the JAR? Link is only for premium members now. Alternatively can you tell us how to compile ourselves?

Create an account or sign in to comment

Recently Browsing 0

  • No registered users viewing this page.

Account

Navigation

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.