aboutsummaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
authorUbitUmarov2017-06-03 04:28:43 +0100
committerUbitUmarov2017-06-03 04:28:43 +0100
commit67e540e05c34667b771fb5d95e4d7bdc0dfce24d (patch)
treefc22340e9872221198d4e6bdcdf021e0e59b4889
parentfix MouseDown in case it gets any use (diff)
downloadopensim-SC_OLD-67e540e05c34667b771fb5d95e4d7bdc0dfce24d.zip
opensim-SC_OLD-67e540e05c34667b771fb5d95e4d7bdc0dfce24d.tar.gz
opensim-SC_OLD-67e540e05c34667b771fb5d95e4d7bdc0dfce24d.tar.bz2
opensim-SC_OLD-67e540e05c34667b771fb5d95e4d7bdc0dfce24d.tar.xz
cross mouse buttons state
-rw-r--r--OpenSim/Framework/ChildAgentDataUpdate.cs9
-rw-r--r--OpenSim/Region/Framework/Scenes/ScenePresence.cs14
2 files changed, 23 insertions, 0 deletions
diff --git a/OpenSim/Framework/ChildAgentDataUpdate.cs b/OpenSim/Framework/ChildAgentDataUpdate.cs
index d6d8dde..ee5007a 100644
--- a/OpenSim/Framework/ChildAgentDataUpdate.cs
+++ b/OpenSim/Framework/ChildAgentDataUpdate.cs
@@ -375,6 +375,7 @@ namespace OpenSim.Framework
375 public string ActiveGroupTitle = null; 375 public string ActiveGroupTitle = null;
376 public UUID agentCOF; 376 public UUID agentCOF;
377 public byte CrossingFlags; 377 public byte CrossingFlags;
378 public byte CrossExtraFlags;
378 379
379 public Dictionary<ulong, string> ChildrenCapSeeds = null; 380 public Dictionary<ulong, string> ChildrenCapSeeds = null;
380 public Animation[] Anims; 381 public Animation[] Anims;
@@ -454,6 +455,8 @@ namespace OpenSim.Framework
454 455
455 args["agent_cof"] = OSD.FromUUID(agentCOF); 456 args["agent_cof"] = OSD.FromUUID(agentCOF);
456 args["crossingflags"] = OSD.FromInteger(CrossingFlags); 457 args["crossingflags"] = OSD.FromInteger(CrossingFlags);
458 if(CrossingFlags != 0)
459 args["crossExtraFlags"] = OSD.FromInteger(CrossExtraFlags);
457 460
458 args["active_group_id"] = OSD.FromUUID(ActiveGroupID); 461 args["active_group_id"] = OSD.FromUUID(ActiveGroupID);
459 args["active_group_name"] = OSD.FromString(ActiveGroupName); 462 args["active_group_name"] = OSD.FromString(ActiveGroupName);
@@ -646,6 +649,12 @@ namespace OpenSim.Framework
646 if (args.ContainsKey("crossingflags") && args["crossingflags"] != null) 649 if (args.ContainsKey("crossingflags") && args["crossingflags"] != null)
647 CrossingFlags = (byte)args["crossingflags"].AsInteger(); 650 CrossingFlags = (byte)args["crossingflags"].AsInteger();
648 651
652 if(CrossingFlags != 0)
653 {
654 if (args.ContainsKey("crossExtraFlags") && args["crossExtraFlags"] != null)
655 CrossExtraFlags = (byte)args["crossExtraFlags"].AsInteger();
656 }
657
649 if (args.ContainsKey("active_group_id") && args["active_group_id"] != null) 658 if (args.ContainsKey("active_group_id") && args["active_group_id"] != null)
650 ActiveGroupID = args["active_group_id"].AsUUID(); 659 ActiveGroupID = args["active_group_id"].AsUUID();
651 660
diff --git a/OpenSim/Region/Framework/Scenes/ScenePresence.cs b/OpenSim/Region/Framework/Scenes/ScenePresence.cs
index 7a14f2a..cec21d8 100644
--- a/OpenSim/Region/Framework/Scenes/ScenePresence.cs
+++ b/OpenSim/Region/Framework/Scenes/ScenePresence.cs
@@ -4668,6 +4668,11 @@ namespace OpenSim.Region.Framework.Scenes
4668 { 4668 {
4669 cAgent.CrossingFlags = crossingFlags; 4669 cAgent.CrossingFlags = crossingFlags;
4670 cAgent.CrossingFlags |= 1; 4670 cAgent.CrossingFlags |= 1;
4671 cAgent.CrossExtraFlags = 0;
4672 if((LastCommands & ScriptControlled.CONTROL_LBUTTON) != 0)
4673 cAgent.CrossExtraFlags |= 1;
4674 if((LastCommands & ScriptControlled.CONTROL_ML_LBUTTON) != 0)
4675 cAgent.CrossExtraFlags |= 2;
4671 } 4676 }
4672 else 4677 else
4673 cAgent.CrossingFlags = 0; 4678 cAgent.CrossingFlags = 0;
@@ -4782,6 +4787,15 @@ namespace OpenSim.Region.Framework.Scenes
4782 4787
4783 crossingFlags = cAgent.CrossingFlags; 4788 crossingFlags = cAgent.CrossingFlags;
4784 gotCrossUpdate = (crossingFlags != 0); 4789 gotCrossUpdate = (crossingFlags != 0);
4790 if(gotCrossUpdate)
4791 {
4792 LastCommands &= ~(ScriptControlled.CONTROL_LBUTTON | ScriptControlled.CONTROL_ML_LBUTTON);
4793 if((cAgent.CrossExtraFlags & 1) != 0)
4794 LastCommands |= ScriptControlled.CONTROL_LBUTTON;
4795 if((cAgent.CrossExtraFlags & 2) != 0)
4796 LastCommands |= ScriptControlled.CONTROL_ML_LBUTTON;
4797 MouseDown = (cAgent.CrossExtraFlags & 3) != 0;
4798 }
4785 4799
4786 haveGroupInformation = false; 4800 haveGroupInformation = false;
4787 // using this as protocol detection don't want to mess with the numbers for now 4801 // using this as protocol detection don't want to mess with the numbers for now