Jump to content

Widget tutorial request


Recommended Posts

Posted

Sorry, if it's out there somewhere, but was unable to find one. Is there/or could someone write a decent tutorial on how to use widget debugger, use widgets in code etc. with examples? For example I want to make the bot to click on GE Box1. I can see that the Action for it is "View offer" when I hover my mouse on it, but using widget debugger I'm unable to find which widget it is, that has the action.

 

Also, I've seen in multiple topics that using static widget ID's in code is like punching your grandma. As I understood you can use 

RS2Widget allWidget = getWidgets().singleFilter(getWidgets().getAll(), new ActionFilter("SOME ACTION HERE")); 

but isn't it extremely inefficient, cause as I understand it goes though all the widgets? And is it safe to filter by action alone?

 

Thanks in advance

Posted

Sorry, if it's out there somewhere, but was unable to find one. Is there/or could someone write a decent tutorial on how to use widget debugger, use widgets in code etc. with examples? For example I want to make the bot to click on GE Box1. I can see that the Action for it is "View offer" when I hover my mouse on it, but using widget debugger I'm unable to find which widget it is, that has the action.

Also, I've seen in multiple topics that using static widget ID's in code is like punching your grandma. As I understood you can use

RS2Widget allWidget = getWidgets().singleFilter(getWidgets().getAll(), new ActionFilter("SOME ACTION HERE"));
but isn't it extremely inefficient, cause as I understand it goes though all the widgets? And is it safe to filter by action alone?

Thanks in advance

Enable widgets in options.

Hover over the widget, you will see the widget IDs in the same colour as the box surrounding your widget.

Input those IDs into the debugger

Posted

Thanks, fiddled around a little bit and got the ID's. 

 

 

 

Also note if its not showing up as an action, it might be a tooltip (.getTooltip())

 

This is just for information gathering right? Cause I don't believe that I'll be able to interact with a widget through the info of its' tooltip.

 

Anyway thanks for the responses.

 

But how about getting the widgets without hardcoding ID's?

Posted

Thanks, fiddled around a little bit and got the ID's. 

 

 

This is just for information gathering right? Cause I don't believe that I'll be able to interact with a widget through the info of its' tooltip.

 

Anyway thanks for the responses.

 

But how about getting the widgets without hardcoding ID's?

 

For example, the pottery interface for the "Make 1", "Make 5", "Make 10", "Make X" is all separate widgets with the "Make X" being the tooltip. Might be only on older content, but it happens (and its the action basically).

Posted

Thanks, fiddled around a little bit and got the ID's.

This is just for information gathering right? Cause I don't believe that I'll be able to interact with a widget through the info of its' tooltip.

Anyway thanks for the responses.

But how about getting the widgets without hardcoding ID's?

You can get them using filters like in the example you posted, and then just store the result. You would only need to do it once and it wouldn't be that inefficient

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