Jump to content
Sign in to follow this  
fegmo

WalkingPreference always set to MINIMAP

Recommended Posts

Hey all,

I'm fairly new to the scripting scene as well as Java, but tend to try figuring out issues I'm having with my own code by myself in hopes of becoming a better programmer. Although I'm getting tangled up with confusion with WalkingPreference. Here's the code:
 

public static void walkPrefTest() {
	ABUTil abc = new ABUtil();
	while (true) {
		int i = General.random(4, 13);
		System.out.println(abc.generateWalkingPreference(i) + i);
		General.sleep(100);
	}
}


I'm unsure if I'm using it completely incorrectly, if it's a stupid little mistake or if the SCREEN pref is insanely rare.
When using other generated preferences i.e. the bank preference, both preferences show up.

Thanks all in advanced! 

Share this post


Link to post
Share on other sites
17 minutes ago, fegmo said:


I'm unsure if I'm using it completely incorrectly, if it's a stupid little mistake or if the SCREEN pref is insanely rare.
When using other generated preferences i.e. the bank preference, both preferences show up.

Thanks all in advanced! 

From the api:

Some profiles specify that the player should walk using the screen if the distance is short. Others will specify to always use the minimap. 

Could just be the specific profile for your character, could be that it in general it is rare for screen pref, or it could be that the random number you are testing is a bit high, who knows. Try it with a static, lower number and see if it has any difference?

Share this post


Link to post
Share on other sites
10 minutes ago, FALSkills said:

Could just be the specific profile for your character, could be that it in general it is rare for screen pref, or it could be that the random number you are testing is a bit high, who knows. Try it with a static, lower number and see if it has any difference?

Hey FALSkills, thanks for the quick responds.

I also thought that was the case, which is why I tried on multiple accounts but had the same outcome (forgot to mention). Maybe I'm just absurdly unlucky haha. Thank you for the input though, I appreciate the help!

Share this post


Link to post
Share on other sites

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
Sign in to follow this  

  • Our picks

    • This release will:

      Add support for using custom F key bindings to switch between game tabs (Thanks @erickho123)


      Fix tab opening for "Skills" and "Kourend Tasks" (Thanks @erickho123)



      Note: If you are using LG, please restart both the RS client and TRiBot
      • 30 replies
    • This release will:

      Fix an issue where breaks would stop firing


      Fix Combat#getWildernessLevel, use dynamic search for text and cache ID for later calls


      Fix an NPE in the Combat API


      Fix Mouse#leaveGame bug where the mouse wouldn't actually leave the game screen
      • 21 replies
    • This release will:

      Add LG support for Runelite


      Fix NPCChat issues


      Fix a bug where the camera angle setter would just hold down a key for 5 seconds (the timeout)


      Slightly adjust the rotation via keys to be more accurate


      Add the ability for asynchronous camera movement via keys


      Make Camera rotation via mouse more fluid, with more antiban, and work much better in resizable mode


      Add a "Camera#setCamera" method, allowing the rotation and angle to be set in parallel


      Increase the likelihood of using the mouse for camera movements


      Add support for adjusting the camera to positionable entities (Positionable#adjustCameraTo)



      Upcoming updates:

      Improved CLI support


      Much more



      Note: If you are using LG, please restart both the RS client and TRiBot
      • 59 replies
    • This update will:

      Allow for clicking through the chat box when possible (Thanks @Todd)


      Fix Combat#selectIndex (Thanks @Encoded)


      Ensure worlds stay sorted and added a check to avoid misclicks in the in-game world hopper (Thanks @erickho123)


      Fix out-dated Options API interface indices (Thanks @Todd)



      Upcoming updates:

      Break handler bug fix


      Improved CLI support


      Much more



      Note: If you are using LG, please restart both the RS client and TRiBot
      • 12 replies
    • This release will:

      Fix login bot after today's game update (Thanks @JoeDezzy1)


      Fix latest in-game world hopping issues (Thanks @erickho123)


      Compact Settings UI and set location relative to TRiBot (Thanks @JoeDezzy1)


      Fix an older implementation of GrandExchange#getWindowState (Thanks @JoeDezzy1)


      Improve the preformance of NPCChat by only searching in certain interface parents (Thanks @JoeDezzy1)



      Upcoming updates:

      Break handler bug fix


      Improved CLI support


      LG support for RuneLite


      Much more



      Note: If you are using LG, please restart both the RS client and TRiBot
      • 16 replies
  • Recently Browsing   0 members

    No registered users viewing this page.

×