Jump to content

Open Source Tutorial Island Script


Recommended Posts

  • 6 months later...
  • 3 weeks later...
Posted
On 4/9/2018 at 3:15 PM, Athylus said:

Thanks a lot! What does the exchangeContext method do?

The MethodProvider class has a bunch of variables in it such as inventory, bank, etc.

Your main class that extends Script (which extends MethodProvider) will have these variables set automatically when it is initialized, which is why you can access the OSBot API from onStart() or onLoop() without doing anything.

However, when you create a class that extends MethodProvider and initialize it, those variables will not be automatically set. So you need to exchange the context (by calling exchangeContext(Bot bot)) between your instance that does have those variables set, and your other instance that does not.

"

public MethodProvider exchangeContext(Bot bot)

Deprecated. For internal use only.

This class and method can be used to create extensions to the API with full direct access to the OSBot 2 API within your extensions. If you create your own extensions you extend the API class or MethodProvider and if you want to provide the existing API components to your own extensions you override this method with a call to this method first by calling super.exchangeContext(bot) followed by the initialization of your own components on which you call this method on.

Specified by:

exchangeContext in class AbstractMethodProvider<Bot>

Parameters:

bot - The Bot instance.

Returns:

The instance of this API extension."

  • Like 1
  • 3 weeks later...
Posted
On 7/27/2017 at 9:42 PM, Explv said:

This was the first script I created for OSBot, I have seen many people make / try to make this script, so I figured why not open source mine so that people could learn from it, or use it.

https://github.com/Explv/Tutorial-Island

Note: there are still some areas I would like to clean up, just haven't had the time yet. I have also excluded my GUI and Paint just to keep it simple.

If you can mention the things you want cleaned up il happily take a look this weekend and see what i can do

  • 5 months later...
Posted
19 hours ago, IkiritokunI said:

oef we need a update on this ?

 

16 hours ago, Runnwith said:

You should update it. ? 

 

1 hour ago, IkiritokunI said:

I'm A noob Java scriptor, tried it today :P. But can't swap the position. (its keep doing the original script).


Fixes have been made, latest release can be found here https://github.com/Explv/Tutorial-Island/releases

Please note that as new accounts are automatically started in resizable mode, the client will have to be manually restarted after the script changes to fixed mode.

Hopefully the OSBot devs will produce a fix for this at some point.

  • 1 month later...

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...