NPC gets stuck in one spot on stairs

I have this problem where the npc pathfinds correctly in almost every place but in one particular spot in a stair case it continually jumps in place and is unable to move forward. I have worked around the issue by checking if its stuck and then moving to the next available waypoint if it is indeed stuck. However, I would still like to fix the issue/know the root cause of it.

Anyone know the problem?

I should also mention that I am using skinned rigs. Hip height is set to autmatic scaling and the parts are set to cancollide false.

4 Likes

Have you tried using PathfindingModifiers yet?
image

Maybe the NPC can’t find any paths on the staircase. You could try doing this:

The red parts are supposed to be transparent uncollidable parts with PathfindingModifiers in them which have PassTrough enabled. These PathfindingModifiers force your NPC to create paths trough them.

2 Likes

I thought pass through meant that objects within the part are ignored?

1 Like

I have used pathfinding modifiers but not in this case. I have thought of using a modifier to cover the entire top portion of the stairs and then putting a ramp underneath, but i was wondering if there was a simpler way as I would have to remake the stairs so that all the steps are seperate from the base of the satirs.

1 Like

Can you make the npc jump? roblox may just be gate keeping it cause it thinks it needs to jump, its a humanoid setting btw

1 Like

Try adding invisible wedges to help pathfinding


Or

1 Like

this creates the weird sensation that the npcs can walk on air.

1 Like

What do you mean by this? The npc is jumping when it;s not supposed to. If iturn off jumping for pathfinding it cant go up the stairs at all.

1 Like

how big are these stairs make the steps smaller.

1 Like

the steps are smaller than the ones you provided in the images, that’s why im confused why it needs to jump.

1 Like

It shouldn’t normally jump if they’re that small. It might be a problem with your pathfinding script, can we have it?

1 Like

Ohh ok mb sorry (char limit sucks)

1 Like

I put a large pathfinding modifier to even out the stair case into a ramp. (npc now sees a ramp instead of a staircase and goes up exactly as it should) Works perfectly now. Thanks.

1 Like

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.