diff options
author | Justin Clark-Casey (justincc) | 2014-11-29 00:12:11 +0000 |
---|---|---|
committer | Justin Clark-Casey (justincc) | 2014-11-29 00:12:11 +0000 |
commit | 265fe349e00b3ece59ec02e56f83bb7623e9d962 (patch) | |
tree | 42afe816271f54a017fe5f731d905e923ef5d67b /OpenSim/Region/Physics/OdePlugin/OdeScene.cs | |
parent | Avoid repeated lag-generating continuous attempts to retrieve HG service Urls... (diff) | |
download | opensim-SC-265fe349e00b3ece59ec02e56f83bb7623e9d962.zip opensim-SC-265fe349e00b3ece59ec02e56f83bb7623e9d962.tar.gz opensim-SC-265fe349e00b3ece59ec02e56f83bb7623e9d962.tar.bz2 opensim-SC-265fe349e00b3ece59ec02e56f83bb7623e9d962.tar.xz |
Somewhat improve avatar region crossings by properly preserving velocity when avatar enters the new region.
This commit addresses the following issues were causing velocity to be set to 0 on the new region, disrupting flight in particular
* Full avatar updates contained no velocity information, which does appear to have some effect in testing.
* BulletSim was always setting the velocity to 0 for the new BSCharacter. Now, physics engines take a velocity parameter when setting up characters so we can avoid this.
This patch applies to both Bullet and ODE.
Diffstat (limited to '')
-rw-r--r-- | OpenSim/Region/Physics/OdePlugin/OdeScene.cs | 11 |
1 files changed, 3 insertions, 8 deletions
diff --git a/OpenSim/Region/Physics/OdePlugin/OdeScene.cs b/OpenSim/Region/Physics/OdePlugin/OdeScene.cs index 6d7f079..5953557 100644 --- a/OpenSim/Region/Physics/OdePlugin/OdeScene.cs +++ b/OpenSim/Region/Physics/OdePlugin/OdeScene.cs | |||
@@ -1969,16 +1969,11 @@ namespace OpenSim.Region.Physics.OdePlugin | |||
1969 | 1969 | ||
1970 | #region Add/Remove Entities | 1970 | #region Add/Remove Entities |
1971 | 1971 | ||
1972 | public override PhysicsActor AddAvatar(string avName, Vector3 position, Vector3 size, bool isFlying) | 1972 | public override PhysicsActor AddAvatar(string avName, Vector3 position, Vector3 velocity, Vector3 size, bool isFlying) |
1973 | { | 1973 | { |
1974 | Vector3 pos; | ||
1975 | pos.X = position.X; | ||
1976 | pos.Y = position.Y; | ||
1977 | pos.Z = position.Z; | ||
1978 | |||
1979 | OdeCharacter newAv | 1974 | OdeCharacter newAv |
1980 | = new OdeCharacter( | 1975 | = new OdeCharacter( |
1981 | avName, this, pos, size, avPIDD, avPIDP, | 1976 | avName, this, position, velocity, size, avPIDD, avPIDP, |
1982 | avCapRadius, avStandupTensor, avDensity, | 1977 | avCapRadius, avStandupTensor, avDensity, |
1983 | avMovementDivisorWalk, avMovementDivisorRun); | 1978 | avMovementDivisorWalk, avMovementDivisorRun); |
1984 | 1979 | ||