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.

Why does acceptTrade not work?

Featured Replies

It listens if the other player accepted but never accepts the trade. What's the problem?

@Override
	public int onLoop() throws InterruptedException {
				if (trade.isFirstInterfaceOpen()) {
					new ConditionalSleep(10000) {
						@Override
						public boolean condition() {
							return trade.getTheirOffers().getAmount("Coins") >= 10;
						}	
					}.sleep();
					log("slept untill coins are more than 10");
					if (trade.getTheirOffers().getAmount("Coins") < 10) {
						log("checking coins if less than 10");
						trade.declineTrade();
					}
					else {
						new ConditionalSleep(10000) {
							@Override
							public boolean condition() {
								return trade.didOtherAcceptTrade();
							}	
						}.sleep();
						log("checked if other player accepts");
						if (!trade.didOtherAcceptTrade()) {
							trade.declineTrade();
						}
						else {
							trade.acceptTrade();
						}
					}
				}
				
				return random(700, 900);
			}

 

Accept trades

Set a timer for 20 seconds or so for coins to appear 

if it's greater than 20s and no coins, decline, else accept. 

 

  • Author
15 hours ago, Tylersbored said:

trade.getTheirOffers().getAmount("Coins")

what if there are no coins in the trade window?

The trade gets declined.

13 hours ago, Juggles said:

Accept trades

Set a timer for 20 seconds or so for coins to appear 

if it's greater than 20s and no coins, decline, else accept. 

 

Other than the timer it is basically what I have now. I've set the timer to 10 just for testing purposes.

I'm asking why acceptTrade is not working. When I put 10 coins in the trade and do not accept, the trade gets declined, but when I put 10 coins in the trade and accept, it will not accept and instead be stuck in an enless loop.

I'm pretty sure acceptTrade isn't working (possibly cause of a change in widget numbers?) I ran into a similar problem when trying to use it. Instead I just got the actual widgets for the accept buttons and used those

  • Author
5 hours ago, d0zza said:

I'm pretty sure acceptTrade isn't working (possibly cause of a change in widget numbers?) I ran into a similar problem when trying to use it. Instead I just got the actual widgets for the accept buttons and used those

Haven't thought of that. Will try to get that working. Thank you :)

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.