diff options
author | Justin Clark-Casey (justincc) | 2013-01-24 00:03:44 +0000 |
---|---|---|
committer | Justin Clark-Casey (justincc) | 2013-01-24 00:03:44 +0000 |
commit | 55c6753b13d4c8cd69cc986db5f6e321b8e65bb7 (patch) | |
tree | 70ae7a976ba9be4e7e8d1cb98d3a6e61e4dfb7d4 /OpenSim/Region/Framework/Scenes/SceneObjectPart.cs | |
parent | Add information on ScriptStopStrategy to [XEngine] in OpenSimDefaults.ini and... (diff) | |
parent | Merge branch 'master' of ssh://opensimulator.org/var/git/opensim (diff) | |
download | opensim-SC-55c6753b13d4c8cd69cc986db5f6e321b8e65bb7.zip opensim-SC-55c6753b13d4c8cd69cc986db5f6e321b8e65bb7.tar.gz opensim-SC-55c6753b13d4c8cd69cc986db5f6e321b8e65bb7.tar.bz2 opensim-SC-55c6753b13d4c8cd69cc986db5f6e321b8e65bb7.tar.xz |
Merge branch 'master' into cooptermination
Diffstat (limited to 'OpenSim/Region/Framework/Scenes/SceneObjectPart.cs')
-rw-r--r-- | OpenSim/Region/Framework/Scenes/SceneObjectPart.cs | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/OpenSim/Region/Framework/Scenes/SceneObjectPart.cs b/OpenSim/Region/Framework/Scenes/SceneObjectPart.cs index 44e8fdf..e0ea344 100644 --- a/OpenSim/Region/Framework/Scenes/SceneObjectPart.cs +++ b/OpenSim/Region/Framework/Scenes/SceneObjectPart.cs | |||
@@ -1952,6 +1952,16 @@ namespace OpenSim.Region.Framework.Scenes | |||
1952 | PhysicsActor pa = PhysActor; | 1952 | PhysicsActor pa = PhysActor; |
1953 | 1953 | ||
1954 | if (pa != null) | 1954 | if (pa != null) |
1955 | return new Vector3(pa.GeometricCenter.X, pa.GeometricCenter.Y, pa.GeometricCenter.Z); | ||
1956 | else | ||
1957 | return new Vector3(0, 0, 0); | ||
1958 | } | ||
1959 | |||
1960 | public Vector3 GetCenterOfMass() | ||
1961 | { | ||
1962 | PhysicsActor pa = PhysActor; | ||
1963 | |||
1964 | if (pa != null) | ||
1955 | return new Vector3(pa.CenterOfMass.X, pa.CenterOfMass.Y, pa.CenterOfMass.Z); | 1965 | return new Vector3(pa.CenterOfMass.X, pa.CenterOfMass.Y, pa.CenterOfMass.Z); |
1956 | else | 1966 | else |
1957 | return new Vector3(0, 0, 0); | 1967 | return new Vector3(0, 0, 0); |