aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/ThirdParty/3Di
diff options
context:
space:
mode:
authorTeravus Ovares2008-09-06 07:52:41 +0000
committerTeravus Ovares2008-09-06 07:52:41 +0000
commit7d89e122930be39e84a6d174548fa2d12ac0484a (patch)
treee5aa5752f988a9aba2a969f49e5e208985eda80c /ThirdParty/3Di
parent* minor: speculatively try a change to bamboo.build to see if this generates ... (diff)
downloadopensim-SC-7d89e122930be39e84a6d174548fa2d12ac0484a.zip
opensim-SC-7d89e122930be39e84a6d174548fa2d12ac0484a.tar.gz
opensim-SC-7d89e122930be39e84a6d174548fa2d12ac0484a.tar.bz2
opensim-SC-7d89e122930be39e84a6d174548fa2d12ac0484a.tar.xz
* This is the fabled LibOMV update with all of the libOMV types from JHurliman
* This is a HUGE OMG update and will definitely have unknown side effects.. so this is really only for the strong hearted at this point. Regular people should let the dust settle. * This has been tested to work with most basic functions. However.. make sure you back up 'everything' before using this. It's that big! * Essentially we're back at square 1 in the testing phase.. so lets identify things that broke.
Diffstat (limited to 'ThirdParty/3Di')
-rw-r--r--ThirdParty/3Di/LoadBalancer/LoadBalancerPlugin.cs38
1 files changed, 19 insertions, 19 deletions
diff --git a/ThirdParty/3Di/LoadBalancer/LoadBalancerPlugin.cs b/ThirdParty/3Di/LoadBalancer/LoadBalancerPlugin.cs
index a724a23..396ad59 100644
--- a/ThirdParty/3Di/LoadBalancer/LoadBalancerPlugin.cs
+++ b/ThirdParty/3Di/LoadBalancer/LoadBalancerPlugin.cs
@@ -32,8 +32,8 @@ using System.IO;
32using System.Net; 32using System.Net;
33using System.Reflection; 33using System.Reflection;
34using System.Threading; 34using System.Threading;
35using libsecondlife; 35using OpenMetaverse;
36using libsecondlife.Packets; 36using OpenMetaverse.Packets;
37using log4net; 37using log4net;
38using Mono.Addins; 38using Mono.Addins;
39using Nwc.XmlRpc; 39using Nwc.XmlRpc;
@@ -600,7 +600,7 @@ namespace OpenSim.ApplicationPlugins.LoadBalancer
600 { 600 {
601 if (createID_flag) 601 if (createID_flag)
602 { 602 {
603 dst_region.RegionID = LLUUID.Random(); 603 dst_region.RegionID = UUID.Random();
604 } 604 }
605 605
606 // change RegionInfo (memory only) 606 // change RegionInfo (memory only)
@@ -611,7 +611,7 @@ namespace OpenSim.ApplicationPlugins.LoadBalancer
611 simMain.CreateRegion(dst_region, false); 611 simMain.CreateRegion(dst_region, false);
612 } 612 }
613 613
614 private void RemoveRegion(LLUUID regionID, int port) 614 private void RemoveRegion(UUID regionID, int port)
615 { 615 {
616 Scene killScene; 616 Scene killScene;
617 if (sceneManager.TryGetScene(regionID, out killScene)) 617 if (sceneManager.TryGetScene(regionID, out killScene))
@@ -834,9 +834,9 @@ namespace OpenSim.ApplicationPlugins.LoadBalancer
834 // this callback receives physic scene updates from the other sub-scenes (in split mode) 834 // this callback receives physic scene updates from the other sub-scenes (in split mode)
835 835
836 int regionPort = (int) request.Params[0]; 836 int regionPort = (int) request.Params[0];
837 LLUUID scenePresenceID = new LLUUID((byte[]) request.Params[1], 0); 837 UUID scenePresenceID = new UUID((byte[]) request.Params[1], 0);
838 LLVector3 position = new LLVector3((byte[]) request.Params[2], 0); 838 Vector3 position = new Vector3((byte[]) request.Params[2], 0);
839 LLVector3 velocity = new LLVector3((byte[]) request.Params[3], 0); 839 Vector3 velocity = new Vector3((byte[]) request.Params[3], 0);
840 bool flying = (bool) request.Params[4]; 840 bool flying = (bool) request.Params[4];
841 841
842 LocalUpdatePhysics(regionPort, scenePresenceID, position, velocity, flying); 842 LocalUpdatePhysics(regionPort, scenePresenceID, position, velocity, flying);
@@ -844,7 +844,7 @@ namespace OpenSim.ApplicationPlugins.LoadBalancer
844 return new XmlRpcResponse(); 844 return new XmlRpcResponse();
845 } 845 }
846 846
847 private void LocalUpdatePhysics(int regionPort, LLUUID scenePresenceID, LLVector3 position, LLVector3 velocity, bool flying) 847 private void LocalUpdatePhysics(int regionPort, UUID scenePresenceID, Vector3 position, Vector3 velocity, bool flying)
848 { 848 {
849 //m_log.Info("[SPLITSCENE] "+String.Format("UpdatePhysics called {0}", regionID)); 849 //m_log.Info("[SPLITSCENE] "+String.Format("UpdatePhysics called {0}", regionID));
850 850
@@ -867,7 +867,7 @@ namespace OpenSim.ApplicationPlugins.LoadBalancer
867 } 867 }
868 868
869// m_log.Info("[SPLITSCENE] "+"LocalUpdatePhysics [region:{0}, client:{1}]", 869// m_log.Info("[SPLITSCENE] "+"LocalUpdatePhysics [region:{0}, client:{1}]",
870// regionID.ToString(), pre.UUID.ToString()); 870// regionID.ToString(), pre.ToString());
871 871
872 pre.AbsolutePosition = position; // will set PhysicsActor.Position 872 pre.AbsolutePosition = position; // will set PhysicsActor.Position
873 pre.Velocity = velocity; // will set PhysicsActor.Velocity 873 pre.Velocity = velocity; // will set PhysicsActor.Velocity
@@ -908,13 +908,13 @@ namespace OpenSim.ApplicationPlugins.LoadBalancer
908 if (isLocalNeighbour[i]) 908 if (isLocalNeighbour[i])
909 { 909 {
910 //m_log.Info("[SPLITSCENE] "+"Synchronize ScenePresence (Local) [region:{0}=>{1}, client:{2}]", 910 //m_log.Info("[SPLITSCENE] "+"Synchronize ScenePresence (Local) [region:{0}=>{1}, client:{2}]",
911 // scene.RegionInfo.RegionID, regionPortList[i], pre.UUID.ToString()); 911 // scene.RegionInfo.RegionID, regionPortList[i], pre.ToString());
912 LocalUpdatePhysics(regionPortList[i], pre.UUID, pre.AbsolutePosition, pre.Velocity, pre.PhysicsActor.Flying); 912 LocalUpdatePhysics(regionPortList[i], pre.UUID, pre.AbsolutePosition, pre.Velocity, pre.PhysicsActor.Flying);
913 } 913 }
914 else 914 else
915 { 915 {
916 //m_log.Info("[SPLITSCENE] "+"Synchronize ScenePresence (Remote) [region port:{0}, client:{1}, position:{2}, velocity:{3}, flying:{4}]", 916 //m_log.Info("[SPLITSCENE] "+"Synchronize ScenePresence (Remote) [region port:{0}, client:{1}, position:{2}, velocity:{3}, flying:{4}]",
917 // regionPortList[i], pre.UUID.ToString(), pre.AbsolutePosition.ToString(), 917 // regionPortList[i], pre.ToString(), pre.AbsolutePosition.ToString(),
918 // pre.Velocity.ToString(), pre.PhysicsActor.Flying); 918 // pre.Velocity.ToString(), pre.PhysicsActor.Flying);
919 919
920 920
@@ -936,7 +936,7 @@ namespace OpenSim.ApplicationPlugins.LoadBalancer
936 header.type = 1; 936 header.type = 1;
937 header.throttlePacketType = 0; 937 header.throttlePacketType = 0;
938 header.numbytes = buff.Length; 938 header.numbytes = buff.Length;
939 header.agent_id = pre.UUID.UUID; 939 header.agent_id = pre.UUID.Guid;
940 header.region_port = regionPortList[i]; 940 header.region_port = regionPortList[i];
941 941
942 //Send 942 //Send
@@ -950,7 +950,7 @@ namespace OpenSim.ApplicationPlugins.LoadBalancer
950 } 950 }
951 } 951 }
952 952
953 public bool SynchronizePackets(IScene scene, Packet packet, LLUUID agentID, ThrottleOutPacketType throttlePacketType) 953 public bool SynchronizePackets(IScene scene, Packet packet, UUID agentID, ThrottleOutPacketType throttlePacketType)
954 { 954 {
955 if (!isSplit) 955 if (!isSplit)
956 { 956 {
@@ -985,7 +985,7 @@ namespace OpenSim.ApplicationPlugins.LoadBalancer
985 header.type = 0; 985 header.type = 0;
986 header.throttlePacketType = (int) throttlePacketType; 986 header.throttlePacketType = (int) throttlePacketType;
987 header.numbytes = buff.Length; 987 header.numbytes = buff.Length;
988 header.agent_id = agentID.UUID; 988 header.agent_id = agentID.Guid;
989 header.region_port = regionPortList[i]; 989 header.region_port = regionPortList[i];
990 990
991 //Send 991 //Send
@@ -998,7 +998,7 @@ namespace OpenSim.ApplicationPlugins.LoadBalancer
998 return true; 998 return true;
999 } 999 }
1000 1000
1001 private void LocalUpdatePacket(int regionPort, LLUUID agentID, Packet packet, ThrottleOutPacketType throttlePacketType) 1001 private void LocalUpdatePacket(int regionPort, UUID agentID, Packet packet, ThrottleOutPacketType throttlePacketType)
1002 { 1002 {
1003 Scene scene; 1003 Scene scene;
1004 1004
@@ -1060,7 +1060,7 @@ namespace OpenSim.ApplicationPlugins.LoadBalancer
1060 1060
1061 Packet packet = PacketPool.Instance.GetPacket(buff, ref packetEnd, zero); 1061 Packet packet = PacketPool.Instance.GetPacket(buff, ref packetEnd, zero);
1062 1062
1063 LocalUpdatePacket(header.region_port, new LLUUID(header.agent_id), 1063 LocalUpdatePacket(header.region_port, new UUID(header.agent_id),
1064 packet, (ThrottleOutPacketType) header.throttlePacketType); 1064 packet, (ThrottleOutPacketType) header.throttlePacketType);
1065 } 1065 }
1066 catch (Exception e) 1066 catch (Exception e)
@@ -1074,9 +1074,9 @@ namespace OpenSim.ApplicationPlugins.LoadBalancer
1074 case 1: 1074 case 1:
1075 1075
1076 int regionPort = header.region_port; 1076 int regionPort = header.region_port;
1077 LLUUID scenePresenceID = new LLUUID(header.agent_id); 1077 UUID scenePresenceID = new UUID(header.agent_id);
1078 LLVector3 position = new LLVector3(buff, 0); 1078 Vector3 position = new Vector3(buff, 0);
1079 LLVector3 velocity = new LLVector3(buff, 12); 1079 Vector3 velocity = new Vector3(buff, 12);
1080 bool flying = ((buff[24] == 1) ? true : false); 1080 bool flying = ((buff[24] == 1) ? true : false);
1081 1081
1082 LocalUpdatePhysics(regionPort, scenePresenceID, position, velocity, flying); 1082 LocalUpdatePhysics(regionPort, scenePresenceID, position, velocity, flying);