Fix crooked camera when you die with active ViewShake #28

Merged
dkanus merged 1 commits from FixViewRotation into dev 2023-05-23 12:17:23 +03:00
Showing only changes of commit f331df23c5 - Show all commits

View File

@ -212,6 +212,20 @@ simulated function ClientPostLogin(){
// Change HUD parameters // Change HUD parameters
class'ScrnHUD'.default.EnemyHealthBarHeight = 4.0; class'ScrnHUD'.default.EnemyHealthBarHeight = 4.0;
} }
// fix crooked camera after you die with active `ViewShake`
function StopViewShaking() {
ShakeRotMax = vect(0, 0, 0);
ShakeRotRate = vect(0, 0, 0);
ShakeRotTime = vect(0, 0, 0);
ShakeOffsetMax = vect(0, 0, 0);
ShakeOffsetRate = vect(0, 0, 0);
ShakeOffsetTime = vect(0, 0, 0);
// add missing variables
ShakeOffset = vect(0, 0, 0);
ShakeRot = Rot(0, 0, 0);
}
function ShowLobbyMenu(){ function ShowLobbyMenu(){
Super.ShowLobbyMenu(); Super.ShowLobbyMenu();
} }