mirror of
https://github.com/TorqueGameEngines/Torque3D.git
synced 2026-01-25 15:14:46 +00:00
camerashake first person weapon recoil fix
This commit is contained in:
parent
8f94614a6e
commit
da34c84df9
|
|
@ -3397,8 +3397,9 @@ void ShapeBase::shakeCamera( U32 imageSlot )
|
|||
{
|
||||
VectorF diff;
|
||||
getMuzzlePoint(imageSlot, &diff);
|
||||
diff = obj->getPosition() - diff;
|
||||
diff = obj->getPosition() - getPosition(); //andrewmac's mystery camerashake fix
|
||||
F32 dist = diff.len();
|
||||
if ( dist == 0.0f ) dist = 1.0f; //andrewmac's mystery camerashake fix
|
||||
if (dist < imageData->camShakeRadius)
|
||||
{
|
||||
CameraShake *camShake = new CameraShake;
|
||||
|
|
|
|||
Loading…
Reference in a new issue