Steering actuator. How to create smooth path following?

Is there any button for nice and curve rotation while following the path? Or I should write code for this by myself, something like this: https://gamedevelopment.tutsplus.com/tutorials/understanding-steering-behaviors-path-following--gamedev-8769

Steering calculates the shortest path. Naturally this is a combination of straight paths with sharp turns.

Calculation with limited turns and curved paths would increase calculation time dramatically.

As this is for entertainment you can do following:

  • hide the follower
  • let another (visible) object follow it via forward motion and tracktto.

Be aware this follower follower can leave the walkable terrain especially on sharp turns.

yea…I’m actually doing this.
Hm, wait a second! Thanks, I thought this method is incorrect, but I was wrong. Instead of motion I used steering actuator with facing checkbox disabled.

Also I have found that obstacle simulations are actually smoothing movements, but they are work little bit strange in terms of start-end movements


Probably obstacle simulations are performance heavy because they need to calculate many things while TrackTo is simple following operation. What do you think? Should I use TrackTo with deleting hidden object after it reaches the end, or should I use obstacle simulations?

It depends if it fits your needs.

At the moment I think trackTo is enough. Just make sure there are some obstacles to collide with to prevent the follower falling down a hole or so.

An idea is to have an invisible object following the path, then having the visible object following it using a combination of trackTo with some time and Motion.
Make sure the visible object is very close to the invisible one so it doesn’t go through walls.

Steering = cont.actuators['Steering'] 
NavMesh = Steering.navmesh

if "path" not in own:
    own['path'] = NavMesh.findPath(own .worldPosition, targets.worldPosition)

Once you can get a path using python, you are free to control how often your actor discards and renews his path, and for what reasons, you can control facing, and movements, and even obstacle simulations.