Equivalent; scheduling issues.
| 7908 | |
| 7909 | // Equivalent; scheduling issues. |
| 7910 | static void zEntPlayer_UpdateVelocityBlur() |
| 7911 | { |
| 7912 | F32 start_vel2; |
| 7913 | F32 peak_vel2; |
| 7914 | F32 vel; // not in DWARF |
| 7915 | |
| 7916 | static F32 start_vel = 10.0f; |
| 7917 | static F32 peak_vel = 50.0f; |
| 7918 | static F32 max_blur = 0.5f; |
| 7919 | |
| 7920 | if (start_vel >= peak_vel) |
| 7921 | { |
| 7922 | return; |
| 7923 | } |
| 7924 | |
| 7925 | start_vel2 = start_vel * start_vel; |
| 7926 | peak_vel2 = peak_vel * peak_vel; |
| 7927 | vel = globals.player.ent.frame->vel.length2(); |
| 7928 | if (vel < start_vel2) |
| 7929 | { |
| 7930 | iCameraSetBlurriness(0); |
| 7931 | } |
| 7932 | else |
| 7933 | { |
| 7934 | start_vel2 = (vel / (peak_vel2 - start_vel2)); |
| 7935 | if (start_vel2 > 1.0f) |
| 7936 | { |
| 7937 | start_vel2 = 1.0f; |
| 7938 | } |
| 7939 | iCameraSetBlurriness(start_vel2 * max_blur); |
| 7940 | } |
| 7941 | } |
| 7942 | |
| 7943 | static void dampen_velocity(xVec3& v1, const xVec3& v2, F32 f) |
| 7944 | { |
nothing calls this directly
no test coverage detected