Jump to content

First script please be gentle lol


freedom1

Recommended Posts

On 7/5/2019 at 2:39 AM, FuryShark said:

Im also getting the same error on another script

[ERROR][Bot #1][07/05 01:38:00 AM]: Inventory widget is null, trying to guess position.

I had the same after the .50 update for some reason, I fixed it by first getting the inventory tab & only then interacting with anything in the inventory. Something like this:

tabs.open(Tab.INVENTORY);
Sleep.sleepUntil(() -> tabs.isOpen(Tab.INVENTORY), 5000);

 

 

On 7/5/2019 at 3:30 AM, freedom1 said:

Thanks to everyone who helped!

I have a working script only took 12hrs, but I did learn a lot.

I have no programing experience.

I could not get the spell to work, so I had to mouse click it =(.

Saturday Ill try to get it banking.

 

Using static sleeps is not a great idea, try to use conditional sleeps there or even random sleeps.
Also what is the mouse click doing? Is it opening the inventory? If so use the code above.

  • Like 1
Link to comment
Share on other sites

Thanks for the help once again, I have gotten rid of the sleep, it was late and I was trying things.

After talking with another scripter, he said the arceuus spell book is currently broken. The method of using the castSpell(), waiting, then a mouse click over the spell area does work. This also gets rid of the error.

Link to comment
Share on other sites

1 hour ago, freedom1 said:

Thanks for the help once again, I have gotten rid of the sleep, it was late and I was trying things.

After talking with another scripter, he said the arceuus spell book is currently broken. The method of using the castSpell(), waiting, then a mouse click over the spell area does work. This also gets rid of the error.

I see :)

Does the script currently work? Any issues?

Link to comment
Share on other sites

4 hours ago, freedom1 said:

Thanks for the help once again, I have gotten rid of the sleep, it was late and I was trying things.

After talking with another scripter, he said the arceuus spell book is currently broken. The method of using the castSpell(), waiting, then a mouse click over the spell area does work. This also gets rid of the error.

Try making your own Spellbook API with widgets. This would be good experience for you. :)

Link to comment
Share on other sites

24 minutes ago, freedom1 said:

it does run, no issues, just really primitive, no banking, no antiban, but it does work

no idea how to even start making an api lol

Banking shouldn't be too hard to implement, as for antiban it is debatable if this actually does lower banrate. Look into moving your outside screen while afk, minimizing clicks & mouse movement, anti pattern...

The less you have to click/move mouse the less you can be flagged on. That's why agility & RC have such huge banrates.

Link to comment
Share on other sites

On 7/6/2019 at 7:54 PM, freedom1 said:

it does run, no issues, just really primitive, no banking, no antiban, but it does work

no idea how to even start making an api lol

An API could just be a class that does the spellbook handling for you. For learning how to interact with widgets, I again recommend you Explv's guide, check out section 12. Widgets.

 

Basically the class could have a method which would find the correct spell using widgets as demonstrated in the guide above. And then you can later extend it to be able to cast whichever spell you want, or whatever, and there you have your own API. I know from experience that creating your own api sounds very intimidating and difficult when you are a beginner programmer, but it really is nothing scary :)

 

  • Like 1
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recently Browsing   0 members

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