Fix a nullref issue in SitAltitudeCallback
parent
fc76b5f589
commit
f77f9ecd8f
|
@ -2357,11 +2357,14 @@ namespace OpenSim.Region.Framework.Scenes
|
||||||
// { // single or child prim
|
// { // single or child prim
|
||||||
partIRot = Quaternion.Inverse(part.GetWorldRotation());
|
partIRot = Quaternion.Inverse(part.GetWorldRotation());
|
||||||
// }
|
// }
|
||||||
|
if (m_initialSitTarget != null)
|
||||||
|
{
|
||||||
float offZ = collisionPoint.Z - m_initialSitTarget.Z;
|
float offZ = collisionPoint.Z - m_initialSitTarget.Z;
|
||||||
Vector3 offset = new Vector3(0.0f, 0.0f, offZ) * partIRot; // Altitude correction
|
Vector3 offset = new Vector3(0.0f, 0.0f, offZ) * partIRot; // Altitude correction
|
||||||
//Console.WriteLine("sitPoint={0}, offset={1}", sitPoint, offset);
|
//Console.WriteLine("sitPoint={0}, offset={1}", sitPoint, offset);
|
||||||
m_pos += offset;
|
m_pos += offset;
|
||||||
// ControllingClient.SendClearFollowCamProperties(part.UUID);
|
// ControllingClient.SendClearFollowCamProperties(part.UUID);
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
} // End SitAltitudeCallback KF.
|
} // End SitAltitudeCallback KF.
|
||||||
|
|
Loading…
Reference in New Issue