Jump to content

Troubles with walking on a ship


BoBP

Recommended Posts

Hey,

Ive been working on a fishing trawler script, but I cant seem to figure out how to walk on the ship.

The script is finished, but when I wanted to reposition the character after his contribution was reached, I hit a wall.

The positions I get from Explv's Location Assistant can't be found by webwalk or walk.

Anyone know what the right approach is here?

Thanks in advance.

Edited by BoBP
Link to comment
Share on other sites

The best way would be to interact with a tile or to use getWalking().walk to the tile. I personally prefer:

Position yourTargetTile = new Position(…,…,…);

and then in your onLoop do yourTargetTile.interact(“Walk here”);

 

or the easy way is just getWalking().walk(yourTargetTile)

 

and to find the coordinates for the tile you must use entity debugger tool in osbot right-side panel and hover over the tile you want to explore.

if the area is instanced then you will need to find an anchor object (any object that is always there for every game e.g. ladders), get its x/y and then find the difference in x/y to the tile you want to walk to.

  • Like 1
Link to comment
Share on other sites

13 minutes ago, Czar said:

if the area is instanced then you will need to find an anchor object (any object that is always there for every game e.g. ladders), get its x/y and then find the difference in x/y to the tile you want to walk to.

This seems like something that could work.

I'l give that a try. Thanks!

Link to comment
Share on other sites

15 minutes ago, BoBP said:

This seems like something that could work.

I'l give that a try. Thanks!

Use local coordinates instead of world coordinates as it's always on the same place ina  certain region :)
To go from local to world again, script.getMap().getBaseX() and Y

Edited by Khaleesi
  • Heart 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...