Chaining Pathfind To Actions

Slate Forums Support Chaining Pathfind To Actions

Viewing 8 posts - 1 through 8 (of 8 total)
  • Author
    Posts
  • #987
    anlumo
    Participant

    Hi,

    To work around the stairs problem I reported in another thread, I tried setting up a Pathfind To action to go to the bottom of the stairs, and then add another action to the top of the stairs. However, it seems like this action can’t handle chaining pathfinds in the timeline’s preview, because the second action always searches from the current position of the character, not the one the character will be in when the action starts. While playing the animation, the second action shrinks in the timeline (since it will take a gradually shorter time to reach the destination) until it is run itself.

    These two issues make the Pathfind To action pretty much unusable when you have multiple heights in the scene :/

    #993
    Gavalakis
    Keymaster

    Hello,

    I think I understand what you mean and it makes sense.
    I am thinking of adding another variation of the Pathfinding Action Clip, that will be using an absolute path from A to B (not using current position of actor, but rather a preset start/end position. Of course in this case, at the start of the Pathfinding action clip, the actor will snap it’s position to the starting point A.

    If you think that is something that will work for you too, just let me know and I can make and post this new clip for you here 🙂

    Let me know.
    Thanks!

    Join us on Discord: https://discord.gg/97q2Rjh

    #1986
    yotingo
    Participant

    Hey,

    <span style=”color: #323232; font-family: ‘Open Sans’; font-size: 12px; background-color: #fbfbfb;”>If you think that is something that will work for you too, just let me know and I can make and post this new clip for you here </span>

    Is this still an option?

    It would be extremely useful for my current setup. Currently I’m stuck doing ‘Follow Path’ with hand placed paths which is very time consuming.

    Additionally, if there was any way to smooth the generated path (so the character doesn’t turn corners so abruptly) this would add a lot of polish to the end result.

    -Thanks

    #1987
    Gavalakis
    Keymaster

    Hey,

    Yes that is still an option 🙂
    I have just created and attached for you here this new clip “Pathfind From To” and which should work as expected.

    It is still not smooth, but that is something I will also take a look at (I agree it would be nice for rotation to be smooth).

    This clip will also exist in the next version, so nothing to worry about updating there 🙂

    Let me know if that works for you.

    Thanks!

    Join us on Discord: https://discord.gg/97q2Rjh

    Attachments:
    You must be logged in to view attached files.
    #1989
    yotingo
    Participant

    Thanks for the fast response!

    It’s working as expected. As far as ease-of-use goes, is there any way to easily set the Source of a ‘PathfindFromTo’ track as the Target of the previous Pathfind track?

    Also, anyway to ease/Slerp the rotation when jumping from the last ‘PathfindFromTo’ clip into the next ‘PathfindFromTo’ clip?

    Finally, is it possible to add a padding or offset amount onto the edge of the Navmesh? Essentially the character would stay X units away from the edge of the Navmesh. For some reference, I’ll explain my use case: I have two characters walking side-by-side having a conversation. When they round the first corner their paths merge and they overlap. Continuing on top of each other instead of separated. -maybe it would work best if the actors were aware of each other and able to avoid collision? I’m not sure.

    I hope to not be overwhelming -these are just the solutions I had considered. Thanks for the great support.

    #1993
    Gavalakis
    Keymaster

    Hello,

    Sorry for the late reply.

    As soon as I am back from a the small vacation that I am now, I will make an improvent to match the previous Target with the next Source as well as the take a look once again for making the rotation smoothly interpolate.

    The rotation at the start of the pathfinding clip, can be smoothed by increase the Blend In parameter of the clip. Is that what you mean?

    Regarding padding/offset, these are things that can be set on the Navigation tab and are part of the NavMesh baking (specifically the “Agent Radius” in the Unity Navigation tab). If you mean extra padding on a per Pathfinding clip basis, I am afraid that it will go far beyond what the clip’s scope is 😛 (and a great deal of work really). Could maybe a clip within which you are able to set multiple path points instead of only Start and Target, be a better solution to your case? This way you can for example create a path point at the timing where the two agents meet, so that they (manually) pathfind around one another.

    Let me know.

    Thank you!

    Join us on Discord: https://discord.gg/97q2Rjh

    #1996
    yotingo
    Participant

    Hey no worries, I hope your vacation is going well!

    Your first suggestion to match the previous Target with the next Source will be a great Quality of Life addition. Smooth interpolated rotation is still something I feel would add a lot of realism, so I appreciate it.

    I’ll admit, I didn’t try smoothing the rotation at the start of a clip by using the blend parameter. -The simplest solutions often escape me.

    The last suggestions is exactly what I was looking for. Setting multiple path points instead of only Start and Target will be easy to do once you implement the first suggestion (matching previous target with next source).

     

    I’m glad Slate continues to improve so much as it’s a lot more powerful than Unity’s Timeline.

    #2006
    Gavalakis
    Keymaster

    Hello again and sorry for the late reply!

    Thank you very much for your kind words.
    I am glad that multiple path points is indeed something that would work for you

    I have thus just noted down this improvement to the Follow Path clip (for the ability to have multiple path points) in the roadmap, which I will however start working on by the end of August.

    Thanks again and have a great summer time! 🙂

    Join us on Discord: https://discord.gg/97q2Rjh

Viewing 8 posts - 1 through 8 (of 8 total)
  • You must be logged in to reply to this topic.