Skip 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.

Entity help

Featured Replies

How do I check if there is an entity at a certain position?

 

EDIT: I mean get a reference to an entity using a position oopsy

Edited by Chicken Wing

How do I check if there is an entity at a certain position?

#ENTITY HERE#getPosition().equals(the position);

EntityAPI.get(x,y) returns a list of entities on pos x,y,z with z = myPlayer.getZ()

!EntityAPI.get(x,y).isEmpty()   --> there is something at position x,y

EntityAPI is one of npcs, objects, grounditems

  • Author

EntityAPI.get(x,y) returns a list of entities on pos x,y,z with z = myPlayer.getZ()

!EntityAPI.get(x,y).isEmpty()   --> there is something at position x,y

EntityAPI is one of npcs, objects, grounditems

 

This is exactly what I was looking for, thank you QwPha8E.png

 

EDIT: EntityAPI is an abstract class? So I have to make those methods myself? I think I've found a solution to my problem so its ok now anyway.

 

Edited by Chicken Wing

This is exactly what I was looking for, thank you QwPha8E.png

 

EDIT: EntityAPI is an abstract class? So I have to make those methods myself? I think I've found a solution to my problem so its ok now anyway.

Yes it is an abstract class, subclassed by concrete classes Objects, NPCS and GroundItems. So you could do objects.get(x,y) or npcs.get(x,y) or groundItems.get(x,y)

  • Author

Yes it is an abstract class, subclassed by concrete classes Objects, NPCS and GroundItems. So you could do objects.get(x,y) or npcs.get(x,y) or groundItems.get(x,y)

 

Oh I didn't realise it was the parent class (/facepalm), TY!

Create an account or sign in to comment

Recently Browsing 0

  • No registered users viewing this page.

Account

Navigation

Search

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.