diff options
author | Jeff Ames | 2008-08-15 10:24:04 +0000 |
---|---|---|
committer | Jeff Ames | 2008-08-15 10:24:04 +0000 |
commit | dde21314e75acdaeff27af70077f283493401961 (patch) | |
tree | 490ab065895adb41ee4771fce623f99faa60b507 /OpenSim/Region/Environment/Scenes/ScenePresence.cs | |
parent | Fixes a case where, when inventory is not currently accessible due (diff) | |
download | opensim-SC_OLD-dde21314e75acdaeff27af70077f283493401961.zip opensim-SC_OLD-dde21314e75acdaeff27af70077f283493401961.tar.gz opensim-SC_OLD-dde21314e75acdaeff27af70077f283493401961.tar.bz2 opensim-SC_OLD-dde21314e75acdaeff27af70077f283493401961.tar.xz |
Update svn properties, formatting cleanup, fix a couple compiler warnings.
Diffstat (limited to 'OpenSim/Region/Environment/Scenes/ScenePresence.cs')
-rw-r--r-- | OpenSim/Region/Environment/Scenes/ScenePresence.cs | 22 |
1 files changed, 13 insertions, 9 deletions
diff --git a/OpenSim/Region/Environment/Scenes/ScenePresence.cs b/OpenSim/Region/Environment/Scenes/ScenePresence.cs index 636d08c..d8d534e 100644 --- a/OpenSim/Region/Environment/Scenes/ScenePresence.cs +++ b/OpenSim/Region/Environment/Scenes/ScenePresence.cs | |||
@@ -1102,12 +1102,13 @@ namespace OpenSim.Region.Environment.Scenes | |||
1102 | 1102 | ||
1103 | // Get our own copy of the part array, and sort into the order we want to test | 1103 | // Get our own copy of the part array, and sort into the order we want to test |
1104 | SceneObjectPart[] partArray = targetPart.ParentGroup.GetParts(); | 1104 | SceneObjectPart[] partArray = targetPart.ParentGroup.GetParts(); |
1105 | Array.Sort(partArray, delegate(SceneObjectPart p1, SceneObjectPart p2) { | 1105 | Array.Sort(partArray, delegate(SceneObjectPart p1, SceneObjectPart p2) |
1106 | // we want the originally selected part first, then the rest in link order -- so make the selected part link num (-1) | 1106 | { |
1107 | int linkNum1 = p1==targetPart ? -1 : p1.LinkNum; | 1107 | // we want the originally selected part first, then the rest in link order -- so make the selected part link num (-1) |
1108 | int linkNum2 = p2==targetPart ? -1 : p2.LinkNum; | 1108 | int linkNum1 = p1==targetPart ? -1 : p1.LinkNum; |
1109 | return linkNum1 - linkNum2; | 1109 | int linkNum2 = p2==targetPart ? -1 : p2.LinkNum; |
1110 | } | 1110 | return linkNum1 - linkNum2; |
1111 | } | ||
1111 | ); | 1112 | ); |
1112 | 1113 | ||
1113 | //look for prims with explicit sit targets that are available | 1114 | //look for prims with explicit sit targets that are available |
@@ -1772,7 +1773,8 @@ namespace OpenSim.Region.Environment.Scenes | |||
1772 | // Because appearance setting is in a module, we actually need | 1773 | // Because appearance setting is in a module, we actually need |
1773 | // to give it access to our appearance directly, otherwise we | 1774 | // to give it access to our appearance directly, otherwise we |
1774 | // get a synchronization issue. | 1775 | // get a synchronization issue. |
1775 | public AvatarAppearance Appearance { | 1776 | public AvatarAppearance Appearance |
1777 | { | ||
1776 | get { return m_appearance; } | 1778 | get { return m_appearance; } |
1777 | set { m_appearance = value; } | 1779 | set { m_appearance = value; } |
1778 | } | 1780 | } |
@@ -2789,7 +2791,8 @@ namespace OpenSim.Region.Environment.Scenes | |||
2789 | } | 2791 | } |
2790 | 2792 | ||
2791 | // optimization; we have to check per script, but if nothing is pressed and nothing changed, we can skip that | 2793 | // optimization; we have to check per script, but if nothing is pressed and nothing changed, we can skip that |
2792 | if(allflags != ScriptControlled.CONTROL_ZERO || allflags != LastCommands) { | 2794 | if (allflags != ScriptControlled.CONTROL_ZERO || allflags != LastCommands) |
2795 | { | ||
2793 | lock (scriptedcontrols) | 2796 | lock (scriptedcontrols) |
2794 | { | 2797 | { |
2795 | foreach (LLUUID scriptUUID in scriptedcontrols.Keys) | 2798 | foreach (LLUUID scriptUUID in scriptedcontrols.Keys) |
@@ -2798,7 +2801,8 @@ namespace OpenSim.Region.Environment.Scenes | |||
2798 | ScriptControlled localHeld = allflags & scriptControlData.eventControls; // the flags interesting for us | 2801 | ScriptControlled localHeld = allflags & scriptControlData.eventControls; // the flags interesting for us |
2799 | ScriptControlled localLast = LastCommands & scriptControlData.eventControls; // the activated controls in the last cycle | 2802 | ScriptControlled localLast = LastCommands & scriptControlData.eventControls; // the activated controls in the last cycle |
2800 | ScriptControlled localChange = localHeld ^ localLast; // the changed bits | 2803 | ScriptControlled localChange = localHeld ^ localLast; // the changed bits |
2801 | if(localHeld != ScriptControlled.CONTROL_ZERO || localChange != ScriptControlled.CONTROL_ZERO) { | 2804 | if (localHeld != ScriptControlled.CONTROL_ZERO || localChange != ScriptControlled.CONTROL_ZERO) |
2805 | { | ||
2802 | // only send if still pressed or just changed | 2806 | // only send if still pressed or just changed |
2803 | m_scene.EventManager.TriggerControlEvent(scriptControlData.objID, scriptUUID, UUID, (uint)localHeld, (uint)localChange); | 2807 | m_scene.EventManager.TriggerControlEvent(scriptControlData.objID, scriptUUID, UUID, (uint)localHeld, (uint)localChange); |
2804 | } | 2808 | } |