diff options
Diffstat (limited to '')
11 files changed, 132 insertions, 12 deletions
diff --git a/OpenSim/Region/ClientStack/LindenUDP/LLClientView.cs b/OpenSim/Region/ClientStack/LindenUDP/LLClientView.cs index 3888a0b..51cc763 100644 --- a/OpenSim/Region/ClientStack/LindenUDP/LLClientView.cs +++ b/OpenSim/Region/ClientStack/LindenUDP/LLClientView.cs | |||
@@ -831,6 +831,21 @@ namespace OpenSim.Region.ClientStack.LindenUDP | |||
831 | } | 831 | } |
832 | } | 832 | } |
833 | 833 | ||
834 | public void SendGenericMessage(string method, List<string> message) | ||
835 | { | ||
836 | GenericMessagePacket gmp = new GenericMessagePacket(); | ||
837 | gmp.MethodData.Method = Util.StringToBytes256(method); | ||
838 | gmp.ParamList = new GenericMessagePacket.ParamListBlock[message.Count]; | ||
839 | int i = 0; | ||
840 | foreach (string val in message) | ||
841 | { | ||
842 | gmp.ParamList[i] = new GenericMessagePacket.ParamListBlock(); | ||
843 | gmp.ParamList[i++].Parameter = Util.StringToBytes256(val); | ||
844 | } | ||
845 | |||
846 | OutPacket(gmp, ThrottleOutPacketType.Task); | ||
847 | } | ||
848 | |||
834 | public void SendGenericMessage(string method, List<byte[]> message) | 849 | public void SendGenericMessage(string method, List<byte[]> message) |
835 | { | 850 | { |
836 | GenericMessagePacket gmp = new GenericMessagePacket(); | 851 | GenericMessagePacket gmp = new GenericMessagePacket(); |
@@ -4907,14 +4922,15 @@ namespace OpenSim.Region.ClientStack.LindenUDP | |||
4907 | arg.SessionID = x.SessionID; | 4922 | arg.SessionID = x.SessionID; |
4908 | arg.State = x.State; | 4923 | arg.State = x.State; |
4909 | UpdateAgent handlerAgentUpdate = OnAgentUpdate; | 4924 | UpdateAgent handlerAgentUpdate = OnAgentUpdate; |
4925 | UpdateAgent handlerPreAgentUpdate = OnPreAgentUpdate; | ||
4910 | lastarg = arg; // save this set of arguments for nexttime | 4926 | lastarg = arg; // save this set of arguments for nexttime |
4911 | if (handlerAgentUpdate != null) | 4927 | if (handlerPreAgentUpdate != null) |
4912 | { | ||
4913 | OnPreAgentUpdate(this, arg); | 4928 | OnPreAgentUpdate(this, arg); |
4929 | if (handlerAgentUpdate != null) | ||
4914 | OnAgentUpdate(this, arg); | 4930 | OnAgentUpdate(this, arg); |
4915 | } | ||
4916 | 4931 | ||
4917 | handlerAgentUpdate = null; | 4932 | handlerAgentUpdate = null; |
4933 | handlerPreAgentUpdate = null; | ||
4918 | } | 4934 | } |
4919 | } | 4935 | } |
4920 | 4936 | ||
diff --git a/OpenSim/Region/CoreModules/Framework/InventoryAccess/InventoryAccessModule.cs b/OpenSim/Region/CoreModules/Framework/InventoryAccess/InventoryAccessModule.cs index 2352ced..901dcba 100644 --- a/OpenSim/Region/CoreModules/Framework/InventoryAccess/InventoryAccessModule.cs +++ b/OpenSim/Region/CoreModules/Framework/InventoryAccess/InventoryAccessModule.cs | |||
@@ -502,8 +502,9 @@ namespace OpenSim.Region.CoreModules.Framework.InventoryAccess | |||
502 | group.RootPart.IsAttachment = true; | 502 | group.RootPart.IsAttachment = true; |
503 | } | 503 | } |
504 | 504 | ||
505 | // For attachments, we must make sure that only a single object update occurs after we've finished | 505 | // If we're rezzing an attachment then don't ask AddNewSceneObject() to update the client since |
506 | // all the necessary operations. | 506 | // we'll be doing that later on. Scheduling more than one full update during the attachment |
507 | // process causes some clients to fail to display the attachment properly. | ||
507 | m_Scene.AddNewSceneObject(group, true, false); | 508 | m_Scene.AddNewSceneObject(group, true, false); |
508 | 509 | ||
509 | // m_log.InfoFormat("ray end point for inventory rezz is {0} {1} {2} ", RayEnd.X, RayEnd.Y, RayEnd.Z); | 510 | // m_log.InfoFormat("ray end point for inventory rezz is {0} {1} {2} ", RayEnd.X, RayEnd.Y, RayEnd.Z); |
diff --git a/OpenSim/Region/Examples/SimpleModule/MyNpcCharacter.cs b/OpenSim/Region/Examples/SimpleModule/MyNpcCharacter.cs index 4bbe9df..a84a3c8 100644 --- a/OpenSim/Region/Examples/SimpleModule/MyNpcCharacter.cs +++ b/OpenSim/Region/Examples/SimpleModule/MyNpcCharacter.cs | |||
@@ -461,6 +461,10 @@ namespace OpenSim.Region.Examples.SimpleModule | |||
461 | 461 | ||
462 | } | 462 | } |
463 | 463 | ||
464 | public void SendGenericMessage(string method, List<string> message) | ||
465 | { | ||
466 | } | ||
467 | |||
464 | public void SendGenericMessage(string method, List<byte[]> message) | 468 | public void SendGenericMessage(string method, List<byte[]> message) |
465 | { | 469 | { |
466 | 470 | ||
diff --git a/OpenSim/Region/Framework/Scenes/SceneObjectPart.cs b/OpenSim/Region/Framework/Scenes/SceneObjectPart.cs index d174d04..683df93 100644 --- a/OpenSim/Region/Framework/Scenes/SceneObjectPart.cs +++ b/OpenSim/Region/Framework/Scenes/SceneObjectPart.cs | |||
@@ -3466,7 +3466,7 @@ namespace OpenSim.Region.Framework.Scenes | |||
3466 | /// <param name="alpha"></param> | 3466 | /// <param name="alpha"></param> |
3467 | public void SetText(string text, Vector3 color, double alpha) | 3467 | public void SetText(string text, Vector3 color, double alpha) |
3468 | { | 3468 | { |
3469 | Color = Color.FromArgb(0xff - (int) (alpha*0xff), | 3469 | Color = Color.FromArgb((int) (alpha*0xff), |
3470 | (int) (color.X*0xff), | 3470 | (int) (color.X*0xff), |
3471 | (int) (color.Y*0xff), | 3471 | (int) (color.Y*0xff), |
3472 | (int) (color.Z*0xff)); | 3472 | (int) (color.Z*0xff)); |
diff --git a/OpenSim/Region/Framework/Scenes/ScenePresence.cs b/OpenSim/Region/Framework/Scenes/ScenePresence.cs index c45fc0f..d7660fd 100644 --- a/OpenSim/Region/Framework/Scenes/ScenePresence.cs +++ b/OpenSim/Region/Framework/Scenes/ScenePresence.cs | |||
@@ -140,6 +140,7 @@ namespace OpenSim.Region.Framework.Scenes | |||
140 | private Vector3? m_forceToApply; | 140 | private Vector3? m_forceToApply; |
141 | private uint m_requestedSitTargetID; | 141 | private uint m_requestedSitTargetID; |
142 | private UUID m_requestedSitTargetUUID; | 142 | private UUID m_requestedSitTargetUUID; |
143 | public bool SitGround = false; | ||
143 | 144 | ||
144 | private SendCourseLocationsMethod m_sendCourseLocationsMethod; | 145 | private SendCourseLocationsMethod m_sendCourseLocationsMethod; |
145 | 146 | ||
@@ -1393,6 +1394,12 @@ namespace OpenSim.Region.Framework.Scenes | |||
1393 | { | 1394 | { |
1394 | m_updateCount = 0; // Kill animation update burst so that the SIT_G.. will stick. | 1395 | m_updateCount = 0; // Kill animation update burst so that the SIT_G.. will stick. |
1395 | Animator.TrySetMovementAnimation("SIT_GROUND_CONSTRAINED"); | 1396 | Animator.TrySetMovementAnimation("SIT_GROUND_CONSTRAINED"); |
1397 | |||
1398 | // TODO: This doesn't prevent the user from walking yet. | ||
1399 | // Setting parent ID would fix this, if we knew what value | ||
1400 | // to use. Or we could add a m_isSitting variable. | ||
1401 | //Animator.TrySetMovementAnimation("SIT_GROUND_CONSTRAINED"); | ||
1402 | SitGround = true; | ||
1396 | } | 1403 | } |
1397 | 1404 | ||
1398 | // In the future, these values might need to go global. | 1405 | // In the future, these values might need to go global. |
@@ -1409,7 +1416,7 @@ namespace OpenSim.Region.Framework.Scenes | |||
1409 | 1416 | ||
1410 | bool update_movementflag = false; | 1417 | bool update_movementflag = false; |
1411 | 1418 | ||
1412 | if (m_allowMovement) | 1419 | if (m_allowMovement && !SitGround) |
1413 | { | 1420 | { |
1414 | if (agentData.UseClientAgentPosition) | 1421 | if (agentData.UseClientAgentPosition) |
1415 | { | 1422 | { |
@@ -1637,7 +1644,7 @@ namespace OpenSim.Region.Framework.Scenes | |||
1637 | } | 1644 | } |
1638 | } | 1645 | } |
1639 | 1646 | ||
1640 | if (update_movementflag) | 1647 | if (update_movementflag && !SitGround) |
1641 | Animator.UpdateMovementAnimations(); | 1648 | Animator.UpdateMovementAnimations(); |
1642 | 1649 | ||
1643 | m_scene.EventManager.TriggerOnClientMovement(this); | 1650 | m_scene.EventManager.TriggerOnClientMovement(this); |
@@ -1748,6 +1755,8 @@ namespace OpenSim.Region.Framework.Scenes | |||
1748 | /// </summary> | 1755 | /// </summary> |
1749 | public void StandUp() | 1756 | public void StandUp() |
1750 | { | 1757 | { |
1758 | SitGround = false; | ||
1759 | |||
1751 | if (m_parentID != 0) | 1760 | if (m_parentID != 0) |
1752 | { | 1761 | { |
1753 | SceneObjectPart part = m_scene.GetSceneObjectPart(m_parentID); | 1762 | SceneObjectPart part = m_scene.GetSceneObjectPart(m_parentID); |
diff --git a/OpenSim/Region/Framework/Scenes/SceneViewer.cs b/OpenSim/Region/Framework/Scenes/SceneViewer.cs index 4ba4fab..2fc98e5 100644 --- a/OpenSim/Region/Framework/Scenes/SceneViewer.cs +++ b/OpenSim/Region/Framework/Scenes/SceneViewer.cs | |||
@@ -84,6 +84,9 @@ namespace OpenSim.Region.Framework.Scenes | |||
84 | while (m_pendingObjects != null && m_pendingObjects.Count > 0) | 84 | while (m_pendingObjects != null && m_pendingObjects.Count > 0) |
85 | { | 85 | { |
86 | SceneObjectGroup g = m_pendingObjects.Dequeue(); | 86 | SceneObjectGroup g = m_pendingObjects.Dequeue(); |
87 | // Yes, this can really happen | ||
88 | if (g == null) | ||
89 | continue; | ||
87 | 90 | ||
88 | // This is where we should check for draw distance | 91 | // This is where we should check for draw distance |
89 | // do culling and stuff. Problem with that is that until | 92 | // do culling and stuff. Problem with that is that until |
diff --git a/OpenSim/Region/OptionalModules/Agent/InternetRelayClientView/Server/IRCClientView.cs b/OpenSim/Region/OptionalModules/Agent/InternetRelayClientView/Server/IRCClientView.cs index bb82fd4..2ed8fbf 100644 --- a/OpenSim/Region/OptionalModules/Agent/InternetRelayClientView/Server/IRCClientView.cs +++ b/OpenSim/Region/OptionalModules/Agent/InternetRelayClientView/Server/IRCClientView.cs | |||
@@ -974,6 +974,11 @@ namespace OpenSim.Region.OptionalModules.Agent.InternetRelayClientView.Server | |||
974 | // TODO | 974 | // TODO |
975 | } | 975 | } |
976 | 976 | ||
977 | public void SendGenericMessage(string method, List<string> message) | ||
978 | { | ||
979 | |||
980 | } | ||
981 | |||
977 | public void SendGenericMessage(string method, List<byte[]> message) | 982 | public void SendGenericMessage(string method, List<byte[]> message) |
978 | { | 983 | { |
979 | 984 | ||
diff --git a/OpenSim/Region/OptionalModules/Scripting/Minimodule/Interfaces/IObject.cs b/OpenSim/Region/OptionalModules/Scripting/Minimodule/Interfaces/IObject.cs index 30580e7..e189489 100644 --- a/OpenSim/Region/OptionalModules/Scripting/Minimodule/Interfaces/IObject.cs +++ b/OpenSim/Region/OptionalModules/Scripting/Minimodule/Interfaces/IObject.cs | |||
@@ -98,6 +98,16 @@ namespace OpenSim.Region.OptionalModules.Scripting.Minimodule | |||
98 | String Description { get; set; } | 98 | String Description { get; set; } |
99 | 99 | ||
100 | /// <summary> | 100 | /// <summary> |
101 | /// Returns the UUID of the Owner of the Object. | ||
102 | /// </summary> | ||
103 | UUID OwnerId { get; } | ||
104 | |||
105 | /// <summary> | ||
106 | /// Returns the UUID of the Creator of the Object. | ||
107 | /// </summary> | ||
108 | UUID CreatorId { get; } | ||
109 | |||
110 | /// <summary> | ||
101 | /// Returns the root object of a linkset. If this object is the root, it will return itself. | 111 | /// Returns the root object of a linkset. If this object is the root, it will return itself. |
102 | /// </summary> | 112 | /// </summary> |
103 | IObject Root { get; } | 113 | IObject Root { get; } |
@@ -179,9 +189,25 @@ namespace OpenSim.Region.OptionalModules.Scripting.Minimodule | |||
179 | /// </summary> | 189 | /// </summary> |
180 | /// <param name="msg">The message to send to the user</param> | 190 | /// <param name="msg">The message to send to the user</param> |
181 | void Say(string msg); | 191 | void Say(string msg); |
182 | 192 | ||
193 | /// <summary> | ||
194 | /// Causes the object to speak to on a specific channel, | ||
195 | /// equivilent to LSL/OSSL llSay | ||
196 | /// </summary> | ||
197 | /// <param name="msg">The message to send to the user</param> | ||
198 | /// <param name="channel">The channel on which to send the message</param> | ||
183 | void Say(string msg,int channel); | 199 | void Say(string msg,int channel); |
184 | 200 | ||
201 | /// <summary> | ||
202 | /// Opens a Dialog Panel in the Users Viewer, | ||
203 | /// equivilent to LSL/OSSL llDialog | ||
204 | /// </summary> | ||
205 | /// <param name="avatar">The UUID of the Avatar to which the Dialog should be send</param> | ||
206 | /// <param name="message">The Message to display at the top of the Dialog</param> | ||
207 | /// <param name="buttons">The Strings that act as label/value of the Bottons in the Dialog</param> | ||
208 | /// <param name="chat_channel">The channel on which to send the response</param> | ||
209 | void Dialog(UUID avatar, string message, string[] buttons, int chat_channel); | ||
210 | |||
185 | //// <value> | 211 | //// <value> |
186 | /// Grants access to the objects inventory | 212 | /// Grants access to the objects inventory |
187 | /// </value> | 213 | /// </value> |
diff --git a/OpenSim/Region/OptionalModules/Scripting/Minimodule/SOPObject.cs b/OpenSim/Region/OptionalModules/Scripting/Minimodule/SOPObject.cs index 5bfe4be..96cccb7 100644 --- a/OpenSim/Region/OptionalModules/Scripting/Minimodule/SOPObject.cs +++ b/OpenSim/Region/OptionalModules/Scripting/Minimodule/SOPObject.cs | |||
@@ -31,6 +31,7 @@ using System.Security; | |||
31 | using OpenMetaverse; | 31 | using OpenMetaverse; |
32 | using OpenMetaverse.Packets; | 32 | using OpenMetaverse.Packets; |
33 | using OpenSim.Framework; | 33 | using OpenSim.Framework; |
34 | using OpenSim.Region.Framework.Interfaces; | ||
34 | using OpenSim.Region.Framework.Scenes; | 35 | using OpenSim.Region.Framework.Scenes; |
35 | using OpenSim.Region.OptionalModules.Scripting.Minimodule.Object; | 36 | using OpenSim.Region.OptionalModules.Scripting.Minimodule.Object; |
36 | using OpenSim.Region.Physics.Manager; | 37 | using OpenSim.Region.Physics.Manager; |
@@ -169,6 +170,16 @@ namespace OpenSim.Region.OptionalModules.Scripting.Minimodule | |||
169 | } | 170 | } |
170 | } | 171 | } |
171 | 172 | ||
173 | public UUID OwnerId | ||
174 | { | ||
175 | get { return GetSOP().OwnerID;} | ||
176 | } | ||
177 | |||
178 | public UUID CreatorId | ||
179 | { | ||
180 | get { return GetSOP().CreatorID;} | ||
181 | } | ||
182 | |||
172 | public IObject[] Children | 183 | public IObject[] Children |
173 | { | 184 | { |
174 | get | 185 | get |
@@ -392,7 +403,48 @@ namespace OpenSim.Region.OptionalModules.Scripting.Minimodule | |||
392 | SceneObjectPart sop = GetSOP(); | 403 | SceneObjectPart sop = GetSOP(); |
393 | m_rootScene.SimChat(Utils.StringToBytes(msg), ChatTypeEnum.Say,channel, sop.AbsolutePosition, sop.Name, sop.UUID, false); | 404 | m_rootScene.SimChat(Utils.StringToBytes(msg), ChatTypeEnum.Say,channel, sop.AbsolutePosition, sop.Name, sop.UUID, false); |
394 | } | 405 | } |
395 | 406 | ||
407 | public void Dialog(UUID avatar, string message, string[] buttons, int chat_channel) | ||
408 | { | ||
409 | if (!CanEdit()) | ||
410 | return; | ||
411 | |||
412 | IDialogModule dm = m_rootScene.RequestModuleInterface<IDialogModule>(); | ||
413 | |||
414 | if (dm == null) | ||
415 | return; | ||
416 | |||
417 | if (buttons.Length < 1) | ||
418 | { | ||
419 | Say("ERROR: No less than 1 button can be shown",2147483647); | ||
420 | return; | ||
421 | } | ||
422 | if (buttons.Length > 12) | ||
423 | { | ||
424 | Say("ERROR: No more than 12 buttons can be shown",2147483647); | ||
425 | return; | ||
426 | } | ||
427 | |||
428 | foreach(string button in buttons) | ||
429 | { | ||
430 | if (button == String.Empty) | ||
431 | { | ||
432 | Say("ERROR: button label cannot be blank",2147483647); | ||
433 | return; | ||
434 | } | ||
435 | if (button.Length > 24) | ||
436 | { | ||
437 | Say("ERROR: button label cannot be longer than 24 characters",2147483647); | ||
438 | return; | ||
439 | } | ||
440 | } | ||
441 | |||
442 | dm.SendDialogToUser( | ||
443 | avatar, GetSOP().Name, GetSOP().UUID, GetSOP().OwnerID, | ||
444 | message, new UUID("00000000-0000-2222-3333-100000001000"), chat_channel, buttons); | ||
445 | |||
446 | } | ||
447 | |||
396 | #endregion | 448 | #endregion |
397 | 449 | ||
398 | 450 | ||
diff --git a/OpenSim/Region/OptionalModules/World/NPC/NPCAvatar.cs b/OpenSim/Region/OptionalModules/World/NPC/NPCAvatar.cs index 9f6a33a..e43ef78 100644 --- a/OpenSim/Region/OptionalModules/World/NPC/NPCAvatar.cs +++ b/OpenSim/Region/OptionalModules/World/NPC/NPCAvatar.cs | |||
@@ -551,6 +551,11 @@ namespace OpenSim.Region.OptionalModules.World.NPC | |||
551 | 551 | ||
552 | } | 552 | } |
553 | 553 | ||
554 | public void SendGenericMessage(string method, List<string> message) | ||
555 | { | ||
556 | |||
557 | } | ||
558 | |||
554 | public void SendGenericMessage(string method, List<byte[]> message) | 559 | public void SendGenericMessage(string method, List<byte[]> message) |
555 | { | 560 | { |
556 | 561 | ||
diff --git a/OpenSim/Region/Physics/Meshing/SculptMesh.cs b/OpenSim/Region/Physics/Meshing/SculptMesh.cs index 6aa8fe4..e58eb89 100644 --- a/OpenSim/Region/Physics/Meshing/SculptMesh.cs +++ b/OpenSim/Region/Physics/Meshing/SculptMesh.cs | |||
@@ -310,8 +310,7 @@ namespace PrimMesher | |||
310 | sculptType = (SculptType)(((int)sculptType) & 0x07); | 310 | sculptType = (SculptType)(((int)sculptType) & 0x07); |
311 | 311 | ||
312 | if (mirror) | 312 | if (mirror) |
313 | if (sculptType == SculptType.plane) | 313 | invert = !invert; |
314 | invert = !invert; | ||
315 | 314 | ||
316 | viewerFaces = new List<ViewerFace>(); | 315 | viewerFaces = new List<ViewerFace>(); |
317 | 316 | ||