Jump to content

Manage Run/Walk state during webWalk()


Fanny

Recommended Posts

I haven't been able to find anything about this, and I am struggling to find a way to do this other than to manually start walking in the rough direction and then toggle run energy.

Is there a built in way to toggle run after a short duration of walking randomly? (like a player would realise they are only walking then turn run on)

Link to comment
Share on other sites

Will probably need to multithread your enable run class but this might be a bit resource heavy? Haven't tried yet...

Another idea could be to web walk to multiple 'checkpoints' and then enable run in between each checkpoint however, won't really be what you're after because you'll still be walking if the run energy depletes before you get to the checkpoint.

Link to comment
Share on other sites

1 hour ago, dubai said:

Will probably need to multithread your enable run class

This is a good idea actually, it would allow full control of the run energy

It could be programmed to be impatient sometimes and run with only 3% or 5% energy, or other times patiently walk, sometimes notice it has 60% run and switch run on shortly after starting the walk, etc.

A separate thread would allow repeatedly checking distance to target also, allowing further refinement to when run is switched on or not

1 hour ago, dubai said:

Another idea could be to web walk to multiple 'checkpoints'

I did consider this, but I think the webwalking is pretty well written, don't want to reinvent the wheel too much - but this would be less resource intensive. Would be a lot more programming though to handle obstacles like the webwalk does

 

If all of my async checks into a single additional thread, it shouldn't be too resource intensive hopefully, but would love to know if there is an easier way or even an existing method that we don't know about!

Link to comment
Share on other sites

1 hour ago, Fanny said:

I did consider this, but I think the webwalking is pretty well written, don't want to reinvent the wheel too much - but this would be less resource intensive. Would be a lot more programming though to handle obstacles like the webwalk does

100% what I thought, web walk is good with the only caveat being lack of control over other tasks unless we multithread them...

I'm kinda hoping someone else chimes in with a different way of solving this because it would be nice to have an easy way to run other tasks while webwalking. I have a "RememberInventory" class that  saves the inventory setup onstart, then when it's bank time it will sort the inventory exactly how it was on startup. Would be awesome if I could make it sort the inventory while it's walking to the next area etc. That'd be pretty human-like imo.

Link to comment
Share on other sites

2 hours ago, dubai said:

Would be awesome if I could make it sort the inventory while it's walking to the next area etc. That'd be pretty human-like imo.

That is a great idea

It is also a good idea to keep track of this information when depositing, as it can misclick deposit equipment instead of deposit all I noticed

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