- used maptoworld in Quake code.

This commit is contained in:
Christoph Oelckers 2022-09-29 13:43:52 +02:00
parent 2afea7c477
commit b30c6137d5

View file

@ -414,9 +414,9 @@ void viewUpdateShake(PLAYER* pPlayer, DVector3& cPos, DAngle& cA, DAngle& cH, do
int nValue = ClipHigh(effectType * 8, 2000);
cH += maphoriz(QRandom2F(nValue * (1. / 256.)));
cA += DAngle::fromDeg(QRandom2F(nValue * (360. / 524288.)));
cPos.X += QRandom2F(nValue * inttoworld) * inttoworld;
cPos.Y += QRandom2F(nValue * inttoworld) * inttoworld;
cPos.Z += QRandom2F(nValue) * zinttoworld;
cPos.X += QRandom2F(nValue * maptoworld) * maptoworld;
cPos.Y += QRandom2F(nValue * maptoworld) * maptoworld;
cPos.Z += QRandom2F(nValue) * zmaptoworld;
pshakeX += QRandom2F(nValue) * (1. / 256.);
pshakeY += QRandom2F(nValue) * (1. / 256.);
}