Lazy camera follow?

Does anybody know kind of a concise verbiage way to have a camera target sort of lazily follow a player character? Just like the simplest possible way to have camera position interpolatively sashay into position? Some guy mentions,
x += (target-x) * .1;

& https://www.youtube.com/watch?v=tu-Qe66AvtY

like someone know a simple onMatrixChangedObservable or something to nudge the active camera towards it’s anchor nice and smooth?

like camera equals towards a bit wherever the player actual is? give or take

like drag it along at best, if not eh

There is the FollowCamera that has a similar behavior to what you are describing:
https://doc.babylonjs.com/features/featuresDeepDive/cameras/camera_introduction#followcamera

I think I like that follow motion but without the target lock, so it follows but can look freely.
I can’t find such a parameter :thinking:

You can use the approach used in a chase camera:

I bet you’ll end up using something like this:

camera.position.x = Scalar.Lerp(camera.position.x, target.x, 0.01) // speed

1 Like

I like a lot of what you’re saying there.

Do you think an ArcRotateCamera with radius=0 or low works as a first person camera? I don’t see why not.

radius = 0 won’t work. But any other reasonable positive value will work for first person. Search the forum for firstperson, first person and you’ll find solutions.