Page 1 of 2 12 LastLast
Results 1 to 10 of 12

Thread: Need help with pathfinding script

  1. #1
    Join Date
    Mar 2007
    Location
    Dublin, Ireland
    Posts
    23
    Thanks
    0
    Thanked 1 Time in 1 Post

    Question Need help with pathfinding script

    Hi, I need help creating a pathfinding script in JavaScript for an online game which currently uses keyboard for moving. General concepts for this script should be:

    - pathfinding levels (smoother or sharper),
    - passable/impassable tiles

    If anyone can help I will provide you with the URL of the game. Thanks and waiting for an answer.

  2. #2
    Join Date
    Mar 2007
    Location
    Dublin, Ireland
    Posts
    23
    Thanks
    0
    Thanked 1 Time in 1 Post

    Default

    So no one knows how to build a pathfinding script? I remember I once found one but I don't remember where. The game is Dawn, and I need this script to make navigation easier.

  3. #3
    Join Date
    Feb 2007
    Location
    England
    Posts
    254
    Thanks
    0
    Thanked 5 Times in 5 Posts

    Default Well... I think you understimate people

    I know many people in this forum *could* create a path finding algorithm, but you are asking them to do a big job with little detail and little reward.

    Why don't you start it off - write what object you want, where they have to go to, what size blocks to use etc. maybe, just maybe someone would be willing to help (People like to help people who help themselves).

  4. #4
    Join Date
    Feb 2007
    Posts
    601
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    I recommend PHP for this...

  5. #5
    Join Date
    Mar 2007
    Location
    Dublin, Ireland
    Posts
    23
    Thanks
    0
    Thanked 1 Time in 1 Post

    Default

    Well, actually PHP is not an option as this game does not have PHP server support. It is still a hobby and I know this can be done with JavaScript and DHTML. The game is located at http://dawn.butterflymedia.ro. The block size/tile size in my game is 30px/30px. What other details should I provide?

    Thanks in advance.

  6. #6
    Join Date
    Jul 2006
    Location
    Canada
    Posts
    2,581
    Thanks
    13
    Thanked 28 Times in 28 Posts

    Default

    I recommend PHP for this...
    Why would you recommend PHP for this? A server-side language like this cannot do things on the fly (without changing the page).
    - Mike

  7. #7
    Join Date
    Feb 2007
    Location
    England
    Posts
    254
    Thanks
    0
    Thanked 5 Times in 5 Posts

    Default Hello.

    Check out my attempts. See my signature link for the code.


    What do you think? If you want I can tailor it to your needs.

  8. #8
    Join Date
    Mar 2007
    Location
    Dublin, Ireland
    Posts
    23
    Thanks
    0
    Thanked 1 Time in 1 Post

    Talking Sure, why not?

    Well, we could work together on this. Remember, it's a hobby project so there's no money in it

    Let me know what you need, the source, the specifications. And if you agree to work with me on this game, I will put your name on the credits section.

    Thanks for your interest.

  9. #9
    Join Date
    Feb 2007
    Location
    England
    Posts
    254
    Thanks
    0
    Thanked 5 Times in 5 Posts

    Default Hey

    Right, my original script was crap as it was home made.

    I started to implement an algoritm called A* (A Star), but I found a javascript A* algorithm on the web.

    Here http://www.devpro.it/javascript_id_137.html

    It is probably the one you saw all that time ago. It should be easy enough to implement in the game. You'll just have to give credit to him (Andrea).


  10. #10
    Join Date
    Mar 2007
    Location
    Dublin, Ireland
    Posts
    23
    Thanks
    0
    Thanked 1 Time in 1 Post

    Default

    Well, thanks for the link. There seems to be only one problem. I might need a "liitle" help implementing it in my page. I have to code the movement for my character along the generated path. Some help would be appreciated. Source code will be provided.

Bookmarks

Posting Permissions

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