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.

Scripts Wont shop up?

Featured Replies

Show up****

 

The local script i made will correctly show up on my desktop osbot. But when i try to transfer it to my laptop OSBot. It will not work. They dont show up. Any help?

 

Script is in spoiler.

package net.hero3128;


import org.osbot.rs07.api.ui.Tab;
import org.osbot.rs07.script.Script;
import org.osbot.rs07.script.ScriptManifest;


import java.awt.*;
import java.util.concurrent.TimeUnit;


@ScriptManifest(name = "hAFK", author = "Hero3128", version = 1.0, info = "AFK's 24 hours", logo = "")
public final class hAFK extends Script {

    private long timeBegan;
    private long timeRan;
    private long newStartTime = 0;// new start time
    private long newSleepTime = 0;// Time till next
    private long timeTillNext = 0;

    public int ACTIONS = 0;
    private static Tab[] Tabs = {Tab.ATTACK, Tab.INVENTORY, Tab.CLANCHAT, Tab.EMOTES, Tab.EQUIPMENT,
            Tab.FRIENDS, Tab.IGNORES, Tab.LOGOUT, Tab.MAGIC, Tab.MUSIC,
            Tab.PRAYER, Tab.QUEST, Tab.SETTINGS, Tab.SKILLS};


    private State state = State.Idle;

    @Override
    public void onStart() {
        timeBegan = System.currentTimeMillis();
        newSleepTime = random(60000, 180000);
        log("hAFK Started");
    }

    @Override
    public void onExit() {
        log("hAFK has stopped!");

    }


    @Override
    public int onLoop() throws InterruptedException {
        switch (state = whatDo()) {
            case Idle:
                return 100;
            case Action:
                if (tabs.open(Tabs[random(Tabs.length)])) {
                    ACTIONS++;
                    newStartTime = System.currentTimeMillis();
                    newSleepTime = random(60000, 180000);
                    return 100;
                } else return 100;


        }
        return 100;
    }

    private State whatDo() {
        if (System.currentTimeMillis() - newStartTime > newSleepTime) return State.Action;


        return State.Idle;
    }

    @Override
    public void onPaint(Graphics2D g) {
        //START: Code generated using Enfilade's Easel
        timeRan = System.currentTimeMillis() - timeBegan;
        timeTillNext = newSleepTime - (System.currentTimeMillis() - newStartTime);

        final Color color1 = new Color(153, 153, 153);
        final Color color2 = new Color(0, 0, 0);
        final Color color3 = new Color(255, 255, 255);

        final BasicStroke stroke1 = new BasicStroke(1);

        final Font font1 = new Font("Comic Sans MS", 1, 10);


        //Graphics2D g = (Graphics2D)g1;
        g.setColor(color1);
        g.fillRect(282, 4, 236, 115);
        g.setColor(color2);
        g.setStroke(stroke1);
        g.drawRect(282, 4, 236, 115);
        g.setFont(font1);
        g.setColor(color3);
        g.drawString("Time Running: " + ft(timeRan), 288, 20);
        g.drawString("State: " + state, 288, 40);
        g.drawString("Actions Done: " + ACTIONS, 288, 60);
        g.drawString("Time Till Next Action: " + ft(timeTillNext), 288, 80);
        g.drawString("hAFK By Hero3128", 412, 116);


        //END: Code generated using Enfilade's Easel
    }


    private enum State {
        Idle("Idling..."),
        Action("Changing Action");

        State(String name) {
            this.name = name;
        }

        private final String name;

        @Override
        public String toString() {
            return name;

        }
    }


    private String ft(long duration) {
        String res = "";
        long days = TimeUnit.MILLISECONDS.toDays(duration);
        long hours = TimeUnit.MILLISECONDS.toHours(duration)
                - TimeUnit.DAYS.toHours(TimeUnit.MILLISECONDS.toDays(duration));
        long minutes = TimeUnit.MILLISECONDS.toMinutes(duration)
                - TimeUnit.HOURS.toMinutes(TimeUnit.MILLISECONDS
                .toHours(duration));
        long seconds = TimeUnit.MILLISECONDS.toSeconds(duration)
                - TimeUnit.MINUTES.toSeconds(TimeUnit.MILLISECONDS
                .toMinutes(duration));
        if (days == 0) {
            res = (hours + ":" + minutes + ":" + seconds);
        } else {
            res = (days + ":" + hours + ":" + minutes + ":" + seconds);
        }
        return res;
    }
}
 

Edited by hero3128

Show up****

The local script i made will correctly show up on my desktop osbot. But when i try to transfer it to my laptop OSBot. It will not work. They dont show up. Any help?

did you place it in the OSBot scripts folder on your laptop?
  • Author

did you place it in the OSBot scripts folder on your laptop?

yes... where else would i put them

yes... where else would i put them

 

He means, did you seperately download them on your laptop and placed them in your script folder (extra on your laptop) ?

  • Author

He means, did you seperately download them on your laptop and placed them in your script folder (extra on your laptop) ?

Yes, i put them on my flashdrive and threw them into OSbot/scripts

 

I tried it with the class files and building a .jar both of which work on my desktop, but my laptop they dont show up to run

Edited by hero3128

Yes, i put them on my flashdrive and threw them into OSbot/scripts

 

I tried it with the class files and building a .jar

 

Try to just download the local .jar again on your laptop, add them to the script folder start osbot, click refresh and let me know if they appear.

 

Maybe something went wrong by transfering via flashdrive. Just try to download them ok?

  • Author

Try to just download the local .jar again on your laptop, add them to the script folder start osbot, click refresh and let me know if they appear.

 

Maybe something went wrong by transfering via flashdrive. Just try to download them ok?

uploaded it via dropbox and downloaded it. Still nothing. Then OsBot updated to the 2.3.53. Still nothing.

here ill post the script. I highly doubt anythings wrong with it though

package net.hero3128;


import org.osbot.rs07.api.ui.Tab;
import org.osbot.rs07.script.Script;
import org.osbot.rs07.script.ScriptManifest;


import java.awt.*;
import java.util.concurrent.TimeUnit;


@ScriptManifest(name = "hAFK", author = "Hero3128", version = 1.0, info = "AFK's 24 hours", logo = "")
public final class hAFK extends Script {

    private long timeBegan;
    private long timeRan;
    private long newStartTime = 0;// new start time
    private long newSleepTime = 0;// Time till next
    private long timeTillNext = 0;

    public int ACTIONS = 0;
    private static Tab[] Tabs = {Tab.ATTACK, Tab.INVENTORY, Tab.CLANCHAT, Tab.EMOTES, Tab.EQUIPMENT,
            Tab.FRIENDS, Tab.IGNORES, Tab.LOGOUT, Tab.MAGIC, Tab.MUSIC,
            Tab.PRAYER, Tab.QUEST, Tab.SETTINGS, Tab.SKILLS};


    private State state = State.Idle;

    @Override
    public void onStart() {
        timeBegan = System.currentTimeMillis();
        newSleepTime = random(60000, 180000);
        log("hAFK Started");
    }

    @Override
    public void onExit() {
        log("hAFK has stopped!");

    }


    @Override
    public int onLoop() throws InterruptedException {
        switch (state = whatDo()) {
            case Idle:
                return 100;
            case Action:
                if (tabs.open(Tabs[random(Tabs.length)])) {
                    ACTIONS++;
                    newStartTime = System.currentTimeMillis();
                    newSleepTime = random(60000, 180000);
                    return 100;
                } else return 100;


        }
        return 100;
    }

    private State whatDo() {
        if (System.currentTimeMillis() - newStartTime > newSleepTime) return State.Action;


        return State.Idle;
    }

    @Override
    public void onPaint(Graphics2D g) {
        //START: Code generated using Enfilade's Easel
        timeRan = System.currentTimeMillis() - timeBegan;
        timeTillNext = newSleepTime - (System.currentTimeMillis() - newStartTime);

        final Color color1 = new Color(153, 153, 153);
        final Color color2 = new Color(0, 0, 0);
        final Color color3 = new Color(255, 255, 255);

        final BasicStroke stroke1 = new BasicStroke(1);

        final Font font1 = new Font("Comic Sans MS", 1, 10);


        //Graphics2D g = (Graphics2D)g1;
        g.setColor(color1);
        g.fillRect(282, 4, 236, 115);
        g.setColor(color2);
        g.setStroke(stroke1);
        g.drawRect(282, 4, 236, 115);
        g.setFont(font1);
        g.setColor(color3);
        g.drawString("Time Running: " + ft(timeRan), 288, 20);
        g.drawString("State: " + state, 288, 40);
        g.drawString("Actions Done: " + ACTIONS, 288, 60);
        g.drawString("Time Till Next Action: " + ft(timeTillNext), 288, 80);
        g.drawString("hAFK By Hero3128", 412, 116);


        //END: Code generated using Enfilade's Easel
    }


    private enum State {
        Idle("Idling..."),
        Action("Changing Action");

        State(String name) {
            this.name = name;
        }

        private final String name;

        @Override
        public String toString() {
            return name;

        }
    }


    private String ft(long duration) {
        String res = "";
        long days = TimeUnit.MILLISECONDS.toDays(duration);
        long hours = TimeUnit.MILLISECONDS.toHours(duration)
                - TimeUnit.DAYS.toHours(TimeUnit.MILLISECONDS.toDays(duration));
        long minutes = TimeUnit.MILLISECONDS.toMinutes(duration)
                - TimeUnit.HOURS.toMinutes(TimeUnit.MILLISECONDS
                .toHours(duration));
        long seconds = TimeUnit.MILLISECONDS.toSeconds(duration)
                - TimeUnit.MINUTES.toSeconds(TimeUnit.MILLISECONDS
                .toMinutes(duration));
        if (days == 0) {
            res = (hours + ":" + minutes + ":" + seconds);
        } else {
            res = (days + ":" + hours + ":" + minutes + ":" + seconds);
        }
        return res;
    }
}

Edited by hero3128

Do you have any other scripts in the folder? Removing all scripts, adding just the script that didn't show up and refreshing did the trick for me.

  • Author

Do you have any other scripts in the folder? Removing all scripts, adding just the script that didn't show up and refreshing did the trick for me.

My script is the only one in there

Did you place this above the public class?

@ScriptManifest(author = "Rumble", info = "Smelts Ores", logo = "", name = "OreSmelter", version = 1.01)

  • Author

Did you place this above the public class?

@ScriptManifest(author = "Rumble", info = "Smelts Ores", logo = "", name = "OreSmelter", version = 1.01)

Yes i do have that in there. I posted the script. you can see for yourself

  • Author

Still Looking for a fix

@Oliver

@Precise


did you place it in the OSBot scripts folder on your laptop?

Do you know any other fixes?

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.