Results 1 to 5 of 5

Thread: Pathing Problem (Recursion)

Threaded View

  1. #1

    Thread Starter
    Junior Member
    Join Date
    Jan 2001
    Location
    New York City, NY
    Posts
    16

    Exclamation

    Here's a bit of a puzzle I've been working on the past day or so. I imagine it's not as difficult as I'm making it to be, so I thought someone here might be able to help me out. It's basically a "pathing" routine.

    In this particular application (in my case, it's a board game), I have 500 different "sectors" or units where a player could be located. Unfortunately, the board is not really set up in a system with coordinates and it has no definite shape. The playing field is set up randomly each game and the only rule in how the game is set up is that one sector must border between 1 and 5 other sectors.

    My goal is to create a routine which will generate the shortest path between "sectors" (which sectors the user must traverse).

    So far, I have come up with the following, but it is so slow and unwieldy that it craps out if the sectors are more than 12 or so spaces from one another.
    Attached Files Attached Files

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width