April 5, 20187 yr In the process of making a quest bot. Using multiple classes to keep control of my code. Now I am making a method to grab an item in one of my classes, but I cannot call getCamera().toEntity(e);. I am guessing because I am not extending Script, since I have all the imports. If I am correct you are only allowed to extend Script in your main class. Is there a work around? All the imports are used listed on this page: https://osbot.org/api/org/osbot/rs07/api/Camera.html
April 5, 20187 yr I haven't done much with the OsBot API, but I would probably pass an instance of the main class to any other classes you use during initialization
April 5, 20187 yr As Blurper said, either pass a reference of script, or methodprovider (keep in mind script extends methodprovider)
April 5, 20187 yr Author Great, it's working! I actually passed my own main class as Script type. Thanks.
Create an account or sign in to comment