aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/Framework/Scenes/ScenePresence.cs
diff options
context:
space:
mode:
authorUbitUmarov2016-07-27 03:50:47 +0100
committerUbitUmarov2016-07-27 03:50:47 +0100
commit2e4c8798abf539bddd9770b162acb6d3f3a105ac (patch)
tree75cbd326185912282de414bad7432a362b2f46b2 /OpenSim/Region/Framework/Scenes/ScenePresence.cs
parentwaste another thread job on another thing that should be part of a more (diff)
downloadopensim-SC_OLD-2e4c8798abf539bddd9770b162acb6d3f3a105ac.zip
opensim-SC_OLD-2e4c8798abf539bddd9770b162acb6d3f3a105ac.tar.gz
opensim-SC_OLD-2e4c8798abf539bddd9770b162acb6d3f3a105ac.tar.bz2
opensim-SC_OLD-2e4c8798abf539bddd9770b162acb6d3f3a105ac.tar.xz
a few more changes on avatar crossing
Diffstat (limited to 'OpenSim/Region/Framework/Scenes/ScenePresence.cs')
-rw-r--r--OpenSim/Region/Framework/Scenes/ScenePresence.cs20
1 files changed, 11 insertions, 9 deletions
diff --git a/OpenSim/Region/Framework/Scenes/ScenePresence.cs b/OpenSim/Region/Framework/Scenes/ScenePresence.cs
index eac7cbc..c375450 100644
--- a/OpenSim/Region/Framework/Scenes/ScenePresence.cs
+++ b/OpenSim/Region/Framework/Scenes/ScenePresence.cs
@@ -4206,19 +4206,21 @@ namespace OpenSim.Region.Framework.Scenes
4206 { 4206 {
4207 // we don't have entity transfer module 4207 // we don't have entity transfer module
4208 Vector3 pos = AbsolutePosition; 4208 Vector3 pos = AbsolutePosition;
4209 vel = Velocity;
4209 float px = pos.X; 4210 float px = pos.X;
4210 if (px < 0) 4211 if (px < 0)
4211 pos.X += Velocity.X * 2; 4212 pos.X += vel.X * 2;
4212 else if (px > m_scene.RegionInfo.RegionSizeX) 4213 else if (px > m_scene.RegionInfo.RegionSizeX)
4213 pos.X -= Velocity.X * 2; 4214 pos.X -= vel.X * 2;
4214 4215
4215 float py = pos.Y; 4216 float py = pos.Y;
4216 if (py < 0) 4217 if (py < 0)
4217 pos.Y += Velocity.Y * 2; 4218 pos.Y += vel.Y * 2;
4218 else if (py > m_scene.RegionInfo.RegionSizeY) 4219 else if (py > m_scene.RegionInfo.RegionSizeY)
4219 pos.Y -= Velocity.Y * 2; 4220 pos.Y -= vel.Y * 2;
4220 4221
4221 Velocity = Vector3.Zero; 4222 Velocity = Vector3.Zero;
4223 m_AngularVelocity = Vector3.Zero;
4222 AbsolutePosition = pos; 4224 AbsolutePosition = pos;
4223 } 4225 }
4224 } 4226 }
@@ -4231,21 +4233,21 @@ namespace OpenSim.Region.Framework.Scenes
4231 RemoveFromPhysicalScene(); 4233 RemoveFromPhysicalScene();
4232 4234
4233 Vector3 pos = AbsolutePosition; 4235 Vector3 pos = AbsolutePosition;
4236 Vector3 vel = Velocity;
4234 float px = pos.X; 4237 float px = pos.X;
4235 if (px < 0) 4238 if (px < 0)
4236 pos.X += Velocity.X * 2; 4239 pos.X += vel.X * 2;
4237 else if (px > m_scene.RegionInfo.RegionSizeX) 4240 else if (px > m_scene.RegionInfo.RegionSizeX)
4238 pos.X -= Velocity.X * 2; 4241 pos.X -= vel.X * 2;
4239 4242
4240 float py = pos.Y; 4243 float py = pos.Y;
4241 if (py < 0) 4244 if (py < 0)
4242 pos.Y += Velocity.Y * 2; 4245 pos.Y += vel.Y * 2;
4243 else if (py > m_scene.RegionInfo.RegionSizeY) 4246 else if (py > m_scene.RegionInfo.RegionSizeY)
4244 pos.Y -= Velocity.Y * 2; 4247 pos.Y -= vel.Y * 2;
4245 4248
4246 Velocity = Vector3.Zero; 4249 Velocity = Vector3.Zero;
4247 m_AngularVelocity = Vector3.Zero; 4250 m_AngularVelocity = Vector3.Zero;
4248
4249 AbsolutePosition = pos; 4251 AbsolutePosition = pos;
4250 4252
4251 AddToPhysicalScene(isFlying); 4253 AddToPhysicalScene(isFlying);