Support Forum

AIPath + RVO simulation FPS jerky movement on low fps

It seems that on low fps (20-30ish), my character’s movement seems to stutter and bounce all over the place. I can quickly achieve such low FPS by turning on the gizmos since it’s a 400x400 map and takes a lot just to render the gizmos.

Here’s an example of what it looks like:

In the beginning, it works fine (the game is constantly on maximum speed).

As soon as gizmos are turned on, dropping the FPS, the stuttering begins.

I use AIPath with RVO Controller. The RVO Desired simulation FPS was set to 40. While stuttering, I tried to put the desired FPS to 1, which exaggerated the stuttering problem. Then, I set the desired FPS to 300, and it seemed completely fine.

So clearly, the problem is in the simulation speed.

What’s a good way to deal with this? I could have the simFPS on 60 on 1x speed, 120 on 2x speed, and 300 on 5x speed, but that seems like it’d be hard-coding and there’s no guarantee some bad stuff like this might happen on different FPS variations and scenarios.

Hi

I can unfortunately not watch the video. Neither Chrome nor Firefox seem to be able to play it.
The A* gizmos shouldn’t be that slow. Make sure you use the A* Inspector → Settings → Graph Coloring Mode = Solid Color since that’s the fastest one.

The rvo simulation will never run faster than your game’s fps in any case. So if your game is getting laggy, then the rvo simulation may behave badly regardless of your settings.

Hey. Sorry for being unable to watch the video. I’ve reuploaded it and I guarantee its availability here:

https://vimeo.com/manage/videos/592737682

The gizmos indeed are that slow. I have a 400x400 map, and even with the solid color one, it wrecks my FPS. It doesn’t matter too much since release builds aren’t suffering from that issue, but still.

Considering RVO simulation never runs faster than the game’s FPS, would it be feasible to set the desired simulation speed to something like 300? If my game is running at 300 FPS, then it might make sense for the simulation to be more precise as well. If my game drops to 30 FPS, then the simulation will follow, and still, produce good enough results.

Is this a good approach, or should I consider other factors when considering RVO simulation FPS?

Sure. Settin the desired simulation fps to 300 essentially just says “run it as fast as you can, every frame”. Which is completely reasonable.