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.

NPC - Click question

Featured Replies

It's my first script; I'm trying to make a range guild script.

 

 

What should i use to talk to the Range judge?

 

 

I currently have:

 

 

 

 

import org.osbot.rs07.api.map.Position;
import org.osbot.rs07.script.Script;
import org.osbot.rs07.script.ScriptManifest;
 
import org.osbot.rs07.utility.Area;
 
import java.awt.*;
 
@ScriptManifest(author = "system64", info = "range guild", name = "SmartGuild", version = 0, logo = "")
public class Guild extends Script {
 
private static final int[] Judge_ID = { 6070 }; // competition judge
 
private Position[] path = {
    new Position(2659, 3437, 0),
    new Position(2660, 3436, 0),
    new Position(2662, 3434, 0),
    new Position(2664, 3431, 0),
    new Position(2666, 3426, 0),
    new Position(2670, 3418, 0),
    
};
 
 

Edited by system64

NPC judge = getNpcs().closest("Judge");

if(judge != null){

judge.interact("Talk-to");

}

 

I would suggest not using ids for NPCs or RS2Objects because they are subject to change on every RS update. Also you have an array of integers, which is unnecessary.

 

private static final int JUDGE_ID = 0;

  • Author

NPC judge = getNpcs().closest("Judge");

if(judge != null){

judge.interact("Talk-to");

}

 

I would suggest not using ids for NPCs or RS2Objects because they are subject to change on every RS update. Also you have an array of integers, which is unnecessary.

 

private static final int JUDGE_ID = 0;

NPC judge = getNpcs().closest("Judge");

if(judge != null){

judge.interact("Talk-to");

}

 
 
use that instead of NPCS/RS2objects? 
 
 

Edited by system64

 

NPC judge = getNpcs().closest("Judge");

if(judge != null){

judge.interact("Talk-to");

}

 
 
use that instead of NPCS/RS2objects? 

 

 

Use what instead?

  • 2 weeks later...

He's asking to use the getNPC method you suggested instead of the one he was using. Yes you should use Alek's method instead. That will prevent the tedious task of having to change your npc's ids every update (if they were changed of course).

Guest
This topic is now closed to further replies.

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.