I’m trying to make my npc move using pathfinding service, but the waypoint.action is not requiring jump even when its needed:
heres my pathfinding function:
I’m trying to make my npc move using pathfinding service, but the waypoint.action is not requiring jump even when its needed:
heres my pathfinding function:
Well you have to say if the action is jump, then you jump. It cannot do it automatically lol.
my point is look at the output, its always “Walk” never showed any “Jump” in print(Waypoint.Action), i already have a function that jumps the npc when the action says jump, but the waypoint never asks for it
I enabled navigation mesh and ive noticed that roblox pathfinding doesnt consider jumping unless the part is atleast 2.5 stud high, is there anyway to adjust this limit to allow pathfinding to consider jumping lower than 1 stud high?
So small thing, AgentJumpHeight doesn’t exist.
Anyway, from my understanding of pathfinding, the next waypoint is the one that calls jumping. I’m not too sure, documentation is confusing (it barely covers jumping), but judging by how the visual waypoints are BLUE after a jump and otherwise YELLOW, I’d say you need to check the next waypoint.
thats unfortunate, agentjumpheight would help alot, also another thing is that pathfinding doesnt care about the difference between 1 studs height, thats probably why the waypoint.action isnt Jump, which means pathfinding doesnt work for small npcs.
i made a few adjustments like raycasting -2 from the waypoint position just to have a precise waypoint position and changed the waypoint.action to enum.pathwaypointaction.jump when the Y distance between last waypoint and nextwaypoint is more >= 1 stud, just so i can let it know when it should jump
But even after all of these, the roblox pathfinding api is still unsatisfying currently
does this manual triggered jump work?
Did you try changing your AgentHeight to something slightly higher (2)? And made the waypoint spacing smaller? This could help the NPC to figure out it can get over it.
Idk alot bout pathfinding but, you could compare the y position between your npc and the next point, if its higher than a certain number then make the npc jump
i did, slowly even until i gone to 0.1, the pathfinding api still doesnt consider jumping on a 1 stud high, the navigation mesh requires atleast 2-2.5 stud high before it considers it something to jump to, worse is that the pathfinding also wants me to jump on a 3+ stud high which is not possible for my small npc, so i just disabled agentcanjump because it ruins the pathfinding, i hope roblox improves this api someday and add more customizing
i did that, but instead of the npc position, i did the last waypoint position, if the new waypoint is higher than the old waypoint, then change the action to jump, this is my improvising and it only worked because i cast ray from every waypoint position down by 2 stud, so i can position the waypoint more precise because the normal waypoint position is floating on air and its causing my npc to consider jumping even when it shouldnt just because its higher than last one, its ridiculous