How do I go about creating path finding and AI tasks in C2?

  • I cant find any simple to understand examples. Basically Im asking how to bake nav meshes into Construct 2, and how do most people approach this problem. So NPCs and such know how to navigate around solid objects or object types (not solid, just types) and know where to move. Some engines this is easier than others. And I just dont know how. Like not even the commands.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • There are path finding behaviours. But the AI is normally programmed in Events.

  • There are path finding behaviours. But the AI is normally programmed in Events.

    Hmm, I wonder if anyone knows the common way to go about this in Construct 2

  • go to 11:40 youtube.com/watch

    <3

  • System every X seconds > 'Your Sprite Object' Find path to 'Your Sprite Object 2'

    is the basic way to get things moving to a target. Set the Variable 'Moving' to 'Your Sprite Object'

    On path found if 'Moving is 'False' > Move along path

    Is moving along path > set 'Moving' to 'True'

    Use the compare distance tool to select how far you want to stop from an object

    if 'Your Sprite Object 2.X' is less than 'Your Sprite Object.X' > 'Your Sprite Object' Stop

    'Your Sprite Object' set 'Moving' to 'False'

    if 'Your Sprite Object 2.Y' is less than 'Your Sprite Object.Y' > 'Your Sprite Object' Stop

    'Your Sprite Object' set 'Moving' to 'False'

    You can use 'is moving along path' to trigger other events when the sprite is moving along its path

    Hope it helps.

  • wow thx, I hope theere are more ways out ther ebut this is a start!!!1

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