Good morning!

I try to put simple NPC patrols to give a little life to a city but strangely it doesn't seem to work whereas I seem to have succeeded in the past for a 3d action game test.

I try to use the waypoint path component by putting different point based on x and z (j uses world data) but the journey time remains at 0 in the module and I cannot visualize the path although I 've put a flashy blue color on it.

Is this how it should be done?

The goal is just to make the NPCs make their rounds in different places.
  • Is this for a 3D or 2D game?
    Please consider rating/reviewing my products on the Asset Store (hopefully positively), as that helps tremendously with getting found.
    If you're enjoying my products, updates and support, please consider supporting me on patreon.com!
  • this is for a 3d game
  • Did a quick test and seems to be working fine here.

    Can you give me details on your setup?
    Also, do you get any errors?
    Please consider rating/reviewing my products on the Asset Store (hopefully positively), as that helps tremendously with getting found.
    If you're enjoying my products, updates and support, please consider supporting me on patreon.com!
  • I'm on unity 2020.3.30f and running on windows 10 64 bit.

    What I did was to put the waypoint component on the prefab which must move, it is a humanoids configured as a mecanim, the first time I did the test it was with the little tutorial of 3 rpg action ( the old one for ork2) and the other characters were in legacy (those provided for the tutorial).

    I have no error message, in fact you could say that nothing is happening as if I had misconfigured it (and it may be the case)
  • The Waypoint Path component goes on a separate game object and defines the path.

    Game objects that should move on the path need to use a schematic (e.g. via an Auto Machine) with a Follow Path node to start following a path.
    Please consider rating/reviewing my products on the Asset Store (hopefully positively), as that helps tremendously with getting found.
    If you're enjoying my products, updates and support, please consider supporting me on patreon.com!
  • edited August 27
    Oh yeah ,I suceed =) ty ;)

    I just have question about it ,it work but on the object the lenght is still at 0(and the gameobject walk about 2 sec) and the path is not visible(it seem it should be because of the color path). What is the


    Post edited by omeegaa on
  • edited August 27
    I'll look into the length - also 0 on my end, seems to have an issue.

    Make sure your path color isn't fully transparent (A value of the color).
    Post edited by gamingislove on
    Please consider rating/reviewing my products on the Asset Store (hopefully positively), as that helps tremendously with getting found.
    If you're enjoying my products, updates and support, please consider supporting me on patreon.com!
  • edited August 27
    My alpha color is on 255 but if the lenght is 0 maybe its explain why the path doesnt show .
    In play mode I can see the lenght path correctly but still no path visible on screen (game or scene) ^^

    While I think about it I wanted to ask if in the next updates a node "check quest finished "would be possible?

    Few other questions :
    How make the prefab look in the direction it goes?
    How to make the prefab changing animation(mecanim) when is is waiting between 2 waypoint?
    what is the "edit curve" button for?
    Post edited by omeegaa on
  • The length is just an information and has no impact on anything.
    However, the Path Width should be above 0 (e.g. the default 3), this is how thick the path is painted in the scene view.

    Rotation is handled by the Rotation Settings, e.g. the Move Direction will make something moving on the path rotate into the direction it moves. There's currently a bug, though.

    There's no animation when reaching one of the points. If you want to do something like that, I'd recommend to instead use combatants and move AI for this.
    E.g. you can add a combatant to any game object using a Add Combatant component. The combatant can define waypoints to follow with it's move AI and use it's idle behaviour schematics for animating at waypoints.

    The Edit Curve button allows you to change the curvature of the path. While editing this, you can click-drag from the path point to change it.
    Please consider rating/reviewing my products on the Asset Store (hopefully positively), as that helps tremendously with getting found.
    If you're enjoying my products, updates and support, please consider supporting me on patreon.com!
Sign In or Register to comment.