diff options
author | Teravus Ovares | 2008-03-25 03:36:31 +0000 |
---|---|---|
committer | Teravus Ovares | 2008-03-25 03:36:31 +0000 |
commit | a21112cceedfc93840b935feae4ad8725c4afb48 (patch) | |
tree | 43efce03cfc00168c04579e1cf3611eebde8ebde /OpenSim/Region/Environment/Scenes/SceneObjectGroup.cs | |
parent | Added monodevelop support to runprebuild.sh (diff) | |
download | opensim-SC-a21112cceedfc93840b935feae4ad8725c4afb48.zip opensim-SC-a21112cceedfc93840b935feae4ad8725c4afb48.tar.gz opensim-SC-a21112cceedfc93840b935feae4ad8725c4afb48.tar.bz2 opensim-SC-a21112cceedfc93840b935feae4ad8725c4afb48.tar.xz |
* Adds llMoveToTarget and llStopMoveToTarget support to the ODEPlugin.
* It doesn't generate at_target events, because they don't exist yet in the script engine.
* The Tau is different, however, compatible with scripts I tested.
* Not perfect... but pretty good.
Diffstat (limited to 'OpenSim/Region/Environment/Scenes/SceneObjectGroup.cs')
-rw-r--r-- | OpenSim/Region/Environment/Scenes/SceneObjectGroup.cs | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/OpenSim/Region/Environment/Scenes/SceneObjectGroup.cs b/OpenSim/Region/Environment/Scenes/SceneObjectGroup.cs index 2875874..2f2a1be 100644 --- a/OpenSim/Region/Environment/Scenes/SceneObjectGroup.cs +++ b/OpenSim/Region/Environment/Scenes/SceneObjectGroup.cs | |||
@@ -694,6 +694,25 @@ namespace OpenSim.Region.Environment.Scenes | |||
694 | } | 694 | } |
695 | } | 695 | } |
696 | 696 | ||
697 | public void moveToTarget(LLVector3 target, float tau) | ||
698 | { | ||
699 | SceneObjectPart rootpart = m_rootPart; | ||
700 | if (rootpart != null) | ||
701 | { | ||
702 | rootpart.PhysActor.PIDTarget = new PhysicsVector(target.X, target.Y, target.Z); | ||
703 | rootpart.PhysActor.PIDTau = tau; | ||
704 | rootpart.PhysActor.PIDActive = true; | ||
705 | } | ||
706 | } | ||
707 | public void stopMoveToTarget() | ||
708 | { | ||
709 | SceneObjectPart rootpart = m_rootPart; | ||
710 | if (rootpart != null) | ||
711 | { | ||
712 | rootpart.PhysActor.PIDActive = false; | ||
713 | } | ||
714 | } | ||
715 | |||
697 | public void SetRootPartOwner(SceneObjectPart part, LLUUID cAgentID, LLUUID cGroupID) | 716 | public void SetRootPartOwner(SceneObjectPart part, LLUUID cAgentID, LLUUID cGroupID) |
698 | { | 717 | { |
699 | part.LastOwnerID = part.OwnerID; | 718 | part.LastOwnerID = part.OwnerID; |
@@ -2019,5 +2038,7 @@ namespace OpenSim.Region.Environment.Scenes | |||
2019 | } | 2038 | } |
2020 | } | 2039 | } |
2021 | } | 2040 | } |
2041 | |||
2042 | |||
2022 | } | 2043 | } |
2023 | } | 2044 | } |