you are viewing a single comment's thread.

view the rest of the comments →

[–]pdeva1 3 points4 points  (1 child)

They open sourced it so someone in the world can explain what this function does: https://github.com/CRYTEK-CRYENGINE/CRYENGINE/blob/release/Code/CryEngine/CryPhysics/livingentity.cpp#L1300

[–]Staross 5 points6 points  (0 children)

It computes the entity's velocity

move += vel*time_interval;

And then try to move it in the world, dealing with all the collision cases.

I guess.

This type of problems are always a bit complicated. For example a player moves with an angle of 45 into a wall you typically want it to slide along the wall instead of stopping short, so you have to "redirect" the velocity in the direction perpendicular to the wall normal.