Grid Pathfinding

This forum is currently in read-only mode.
  • This is a simple grid pathfinding system.

    Grid pathfinding

    The controls are:

    Left click mouse botten to set a goal.

    Double left click to path find.

    Right click to clear.

  • I notice that the .exe I posted the pathfinding was a little off.

    I fix it and added a NPC sprite that is using the grid movement behavior to move along the path.

    The controls are the same.

    To here it is.

    http://download938.mediafire.com/fygmnl ... vement.exe

    and a pic.

    <img src="http://i25.photobucket.com/albums/c87/TheLastTora/gridpathfindingmovement.jpg">

    And if any one is interested in knowing how it works.

    I will post cap.

    So leave a comment and let me know what you guys think of it.

  • I always wondered how one would be able to do this. :>

  • Looks interesting, now if you have a way to add multiple waypoints that would be nice.

  • I was thinking about doing just that.

    That might be easy to do.

    I have some questions.

    What would you it used for?

    How many waypoint do you won't?

  • It might work nice for a chess or similar type of game, perhaps even a top down tactics type.

    As to the way points I would guess you would want that to be as many as needed. In other words the player would decide.

  • It might work nice for a chess or similar type of game, perhaps even a top down tactics type.

    As to the way points I would guess you would want that to be as many as needed. In other words the player would decide.

    Well, for a chess you don't even need to use pathfinder at all.

    The grid movement behavior is all you need, the rest is just AI.

    As for the top down tactics type game way point would be useless in the sense that the grid based ones are all turn based.

    So on each of the NPC turn just reevaluate the goal based on conditions to change the path or keep the path the same.

    At this point I don't see a reason to add way points.

    But if I find a need for way points I will make it.

  • I'd be very interested in multi pathfinding, but what you have their seems quite good already, what I'm interested in is this:

    I'm working on a kind of turn based story based game (with retro graphics, dos like) but I would like to have npcs move around as I like according to the events of the story, moving around obstacles ether by me directly creating the path or with a simple pathfinding gist so the npc finds its own way once through obstacles, multi pathfinding would not be essential for this example I'd assume?

    ideas I would like to try at a later date:

    • turnbased trading and/or sim game
    • strategy game like master of orion, yes that sounds scary, just throwing it out
    • the story thing above would probibly just be story, no puzzles and what not

    I'm slightly new to constuct but have been learning/dabbling/experimenting for a couple months now, haven't hit the forums as of yet, till now : )

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • [quote:umr5tys9]At this point I don't see a reason to add way points.

    But if I find a need for way points I will make it.

    realeyes2 said it, obstacles.

    Unless we're talking about two different things.

  • yea basic obstacles for say an npc to find their way around, unless this is already implemented

  • I'd be very interested in multi pathfinding, but what you have their seems quite good already, what I'm interested in is this:

    I'm working on a kind of turn based story based game (with retro graphics, dos like) but I would like to have npcs move around as I like according to the events of the story, moving around obstacles ether by me directly creating the path or with a simple pathfinding gist so the npc finds its own way once through obstacles, multi pathfinding would not be essential for this example I'd assume?

    ideas I would like to try at a later date:

    - turnbased trading and/or sim game

    - strategy game like master of orion, yes that sounds scary, just throwing it out

    - the story thing above would probibly just be story, no puzzles and what not

    I'm slightly new to constuct but have been learning/dabbling/experimenting for a couple months now, haven't hit the forums as of yet, till now : )

    I am making a TBS game and for events the grid movement behavior alone is better for that.

    I say this because in story events you don't want the NPCs in the scene to move in a zigzag type of movement. It is more appealing to have the NPCs move in strait lines.

    That way Game makers don't use pathfinding in their games events.

    here is a Video game to show that I am talking about.

    The pathfinder can move around obstacles at the moment, even though there are some technical problems I am trying to work out.

  • well I'd be happy to fiddle with your .cap file once you've gotten it done or have gotten tired of it, what I kind of meant about story events is ones that are in some form dynamic, so they never happen in an exact place but rather more fluid like interactive fiction/narrative , according to semi simulation based things that happen within the game,

    you seem a bit hesitant about your work, maybe its just me though, or I just don't understand, one of those

    anyhow, I am really interested

  • Hi, could you post .cap please .

  • I notice that the .exe I posted the pathfinding was a little off.

    I fix it and added a NPC sprite that is using the grid movement behavior to move along the path.

    The controls are the same.

    So here it is.

    http://download938.mediafire.com/fygmnl ... vement.exe

    and a pic.

    <img src="http://i25.photobucket.com/albums/c87/TheLastTora/gridpathfindingmovement.jpg">

    And if any one is interested in knowing how it works.

    I will post cap.

    So leave a comment and let me know what you guys think of it.

  • I notice that the .exe I posted the pathfinding was a little off.

    I fix it and added a NPC sprite that is using the grid movement behavior to move along the path.

    The controls are the same.

    So here it is.

    http://download938.mediafire.com/fygmnl ... vement.exe

    and a pic.

    <img src="http://i25.photobucket.com/albums/c87/TheLastTora/gridpathfindingmovement.jpg">

    And if any one is interested in knowing how it works.

    I will post cap.

    So leave a comment and let me know what you guys think of it.

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)