1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Question WebPath, RegionPath and PredefinedPath. When to use?

Discussion in 'Developer Support' started by sheel, Dec 4, 2017.

Tags:
  1. sheel

    Joined:
    Dec 2, 2017
    Messages:
    8
    Likes Received:
    0
    I've noticed atleast 3 different methods of navigation - WebPath, RegionPath and PredefinedPath.
    What are the best situations for using each of these? And what are some good conventions to follow when writing navigation code?
     
  2. Qosmiof2

    Qosmiof2 I've been called a god before.

    Joined:
    Aug 5, 2014
    Messages:
    3,212
    Likes Received:
    924
    Web path - long, obtacle-full paths (covers obstacles, teleportation etc.)
    RegionPaths - region paths xD (covers walking)
    BresehnamPath - straight lines, short distances (covers walking)
    PredefinedPath - never.
     
  3. Snufalufugus

    Joined:
    Aug 23, 2015
    Messages:
    1,961
    Likes Received:
    757
    Predefined path can traverse anywhere you define it to, incredibly reliable, but less randomized and the least flexible

    Regionpath can traverse anywhere inside your current region (104x104) as long as there aren't obstacles in the way

    Web can traverse anywhere that it supports (almost anywhere), including going past common obstacles like doors.

    You should join the slack
    Join Developer Chat | RuneMate
     
  4. sheel

    Joined:
    Dec 2, 2017
    Messages:
    8
    Likes Received:
    0
    So can I assume then that WebPath is probably a good general solution to everything?
    Would it have the same performance as a BresehnamPath for a short distance? (Ex: walking from door to door in a Dungeoneering room)
     
  5. Snufalufugus

    Joined:
    Aug 23, 2015
    Messages:
    1,961
    Likes Received:
    757
    I don't think web supports anything dungeoneering since it's instanced.
     
  6. sheel

    Joined:
    Dec 2, 2017
    Messages:
    8
    Likes Received:
    0
    I meant simply covering the small distance required to walk to the other end of a room. I could have separate logic for dealing with unlocking/opening doors.
     
  7. Qosmiof2

    Qosmiof2 I've been called a god before.

    Joined:
    Aug 5, 2014
    Messages:
    3,212
    Likes Received:
    924
    Webpath takes longer to generate.
     
  8. sheel

    Joined:
    Dec 2, 2017
    Messages:
    8
    Likes Received:
    0
    So what happens if I use WebPath to traverse to a coordinate that's not "walkable"? For example, if there's a tree on my destination coordinate. Would WebPath just try to navigate as close to it as possible or would it return a null path? I wanted to have a WebPath walk to a specfic range of coordinates (it'd choose one randomly) but some of them may be unwalkable.
     
  9. awesome123man

    awesome123man Go check out new bots and give helpful feedback.

    Joined:
    Jan 31, 2016
    Messages:
    5,413
    Likes Received:
    1,662
    I'm not sure exactly, but i would say it would fail... Try to use areas :) I believe it can build to them even if some of the coordinates contained aren't reachable. BTW (Breseham is fastest to be generated but only good for short distances or if the Defualt Web fails... Region is a very good one and is fast and generally paths like a normal person... Web is slow and can sometimes be funny, but is the best way to get to a far away destination.
     

Share This Page

Loading...