aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim
diff options
context:
space:
mode:
authorUbitUmarov2019-05-02 03:11:16 +0100
committerUbitUmarov2019-05-02 03:11:16 +0100
commit3a055c578d9fb2e1f6c0c9ba47a7b8c9c5d8af48 (patch)
tree233a28a4846b7fc45eb7375d2565bdac4eff8efa /OpenSim
parentosLocalTeleportAgent: no region crossings :( ; check avatar access to target ... (diff)
downloadopensim-SC-3a055c578d9fb2e1f6c0c9ba47a7b8c9c5d8af48.zip
opensim-SC-3a055c578d9fb2e1f6c0c9ba47a7b8c9c5d8af48.tar.gz
opensim-SC-3a055c578d9fb2e1f6c0c9ba47a7b8c9c5d8af48.tar.bz2
opensim-SC-3a055c578d9fb2e1f6c0c9ba47a7b8c9c5d8af48.tar.xz
soem cleanup
Diffstat (limited to '')
-rw-r--r--OpenSim/Region/Framework/Scenes/ScenePresence.cs13
-rw-r--r--OpenSim/Region/ScriptEngine/Shared/Api/Implementation/OSSL_Api.cs2
-rw-r--r--OpenSim/Region/ScriptEngine/Shared/Api/Runtime/LSL_Constants.cs15
3 files changed, 18 insertions, 12 deletions
diff --git a/OpenSim/Region/Framework/Scenes/ScenePresence.cs b/OpenSim/Region/Framework/Scenes/ScenePresence.cs
index cd2b9b4..b12bb45 100644
--- a/OpenSim/Region/Framework/Scenes/ScenePresence.cs
+++ b/OpenSim/Region/Framework/Scenes/ScenePresence.cs
@@ -1769,19 +1769,12 @@ namespace OpenSim.Region.Framework.Scenes
1769 1769
1770 float localHalfAVHeight = 0.8f; 1770 float localHalfAVHeight = 0.8f;
1771 if (Appearance != null) 1771 if (Appearance != null)
1772 localHalfAVHeight = Appearance.AvatarHeight / 2; 1772 localHalfAVHeight = Appearance.AvatarHeight * 0.5f;
1773
1774 float posZLimit = 22;
1775
1776 // TODO: Check other Scene HeightField
1777 posZLimit = (float)Scene.Heightmap[(int)newpos.X, (int)newpos.Y];
1778 1773
1774 float posZLimit = (float)Scene.Heightmap[(int)newpos.X, (int)newpos.Y];
1779 posZLimit += localHalfAVHeight + 0.1f; 1775 posZLimit += localHalfAVHeight + 0.1f;
1780 1776 if (newpos.Z < posZLimit)
1781 if ((newpos.Z < posZLimit) && !(Single.IsInfinity(posZLimit) || Single.IsNaN(posZLimit)))
1782 {
1783 newpos.Z = posZLimit; 1777 newpos.Z = posZLimit;
1784 }
1785 1778
1786 if ((flags & 8) != 0) 1779 if ((flags & 8) != 0)
1787 Flying = true; 1780 Flying = true;
diff --git a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/OSSL_Api.cs b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/OSSL_Api.cs
index a0f784e..7d3c832 100644
--- a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/OSSL_Api.cs
+++ b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/OSSL_Api.cs
@@ -936,7 +936,7 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api
936 936
937 Vector3 pos = presence.AbsolutePosition; 937 Vector3 pos = presence.AbsolutePosition;
938 if (!checkAllowAgentTPbyLandOwner(agentId, pos)) 938 if (!checkAllowAgentTPbyLandOwner(agentId, pos))
939 return; 939 return;
940 940
941 World.RequestLocalTeleport(presence, position, velocity, lookat, flags); 941 World.RequestLocalTeleport(presence, position, velocity, lookat, flags);
942 } 942 }
diff --git a/OpenSim/Region/ScriptEngine/Shared/Api/Runtime/LSL_Constants.cs b/OpenSim/Region/ScriptEngine/Shared/Api/Runtime/LSL_Constants.cs
index 8b70128..86c6d7c 100644
--- a/OpenSim/Region/ScriptEngine/Shared/Api/Runtime/LSL_Constants.cs
+++ b/OpenSim/Region/ScriptEngine/Shared/Api/Runtime/LSL_Constants.cs
@@ -35,7 +35,7 @@ namespace OpenSim.Region.ScriptEngine.Shared.ScriptBase
35 public partial class ScriptBaseClass 35 public partial class ScriptBaseClass
36 { 36 {
37 // SCRIPTS CONSTANTS 37 // SCRIPTS CONSTANTS
38 public static readonly LSLInteger OS_APIVERSION = 3; 38 public static readonly LSLInteger OS_APIVERSION = 4;
39 39
40 public static readonly LSLInteger TRUE = 1; 40 public static readonly LSLInteger TRUE = 1;
41 public static readonly LSLInteger FALSE = 0; 41 public static readonly LSLInteger FALSE = 0;
@@ -898,6 +898,19 @@ namespace OpenSim.Region.ScriptEngine.Shared.ScriptBase
898 //ApiDesc osTeleportObject flag: the rotation is the final rotation, otherwise is a added rotation 898 //ApiDesc osTeleportObject flag: the rotation is the final rotation, otherwise is a added rotation
899 public const int OSTPOBJ_SETROT = 0x4; 899 public const int OSTPOBJ_SETROT = 0x4;
900 900
901 //ApiDesc osLocalTeleportAgent no flags
902 public const int OS_LTPAG_NONE = 0x0;
903 //ApiDesc osLocalTeleportAgent use velocity
904 public const int OS_LTPAG_USEVEL = 0x1;
905 //ApiDesc osLocalTeleportAgent use lookat
906 public const int OS_LTPAG_USELOOKAT = 0x2;
907 //ApiDesc osLocalTeleportAgent align lookat to velocity
908 public const int OS_LTPAG_ALGNLV = 0x4;
909 //ApiDesc osLocalTeleportAgent force fly
910 public const int OS_LTPAG_FORCEFLY = 0x8;
911 //ApiDesc osLocalTeleportAgent force no fly
912 public const int OS_LTPAG_FORCENOFLY = 0x16;
913
901 // Constants for Windlight 914 // Constants for Windlight
902 public const int WL_WATER_COLOR = 0; 915 public const int WL_WATER_COLOR = 0;
903 public const int WL_WATER_FOG_DENSITY_EXPONENT = 1; 916 public const int WL_WATER_FOG_DENSITY_EXPONENT = 1;