diff options
author | Melanie Thielker | 2008-10-26 19:32:41 +0000 |
---|---|---|
committer | Melanie Thielker | 2008-10-26 19:32:41 +0000 |
commit | f7e44250bf6058a7f232b5555d709787f1a2eb6b (patch) | |
tree | f9197d06761c96d1b47f0b4dd56cef8aca6bf4b5 | |
parent | Thank you kindly, Idb for a patch that solves: (diff) | |
download | opensim-SC-f7e44250bf6058a7f232b5555d709787f1a2eb6b.zip opensim-SC-f7e44250bf6058a7f232b5555d709787f1a2eb6b.tar.gz opensim-SC-f7e44250bf6058a7f232b5555d709787f1a2eb6b.tar.bz2 opensim-SC-f7e44250bf6058a7f232b5555d709787f1a2eb6b.tar.xz |
Committing a small fix for EventData along with more plumbing work
8 files changed, 34 insertions, 11 deletions
diff --git a/OpenSim/Framework/EventData.cs b/OpenSim/Framework/EventData.cs index bbca240..70554d0 100644 --- a/OpenSim/Framework/EventData.cs +++ b/OpenSim/Framework/EventData.cs | |||
@@ -42,7 +42,7 @@ namespace OpenSim.Framework | |||
42 | public string name; | 42 | public string name; |
43 | public string category; | 43 | public string category; |
44 | public string description; | 44 | public string description; |
45 | public DateTime date; | 45 | public string date; |
46 | public uint dateUTC; | 46 | public uint dateUTC; |
47 | public uint duration; | 47 | public uint duration; |
48 | public uint cover; | 48 | public uint cover; |
diff --git a/OpenSim/Framework/IClientAPI.cs b/OpenSim/Framework/IClientAPI.cs index 471def5..46615cc 100644 --- a/OpenSim/Framework/IClientAPI.cs +++ b/OpenSim/Framework/IClientAPI.cs | |||
@@ -683,7 +683,7 @@ namespace OpenSim.Framework | |||
683 | void SendMoneyBalance(UUID transaction, bool success, byte[] description, int balance); | 683 | void SendMoneyBalance(UUID transaction, bool success, byte[] description, int balance); |
684 | void SendPayPrice(UUID objectID, int[] payPrice); | 684 | void SendPayPrice(UUID objectID, int[] payPrice); |
685 | 685 | ||
686 | void SendAvatarData(ulong regionHandle, string firstName, string lastName, UUID avatarID, uint avatarLocalID, | 686 | void SendAvatarData(ulong regionHandle, string firstName, string lastName, string grouptitle, UUID avatarID, uint avatarLocalID, |
687 | Vector3 Pos, byte[] textureEntry, uint parentID, Quaternion rotation); | 687 | Vector3 Pos, byte[] textureEntry, uint parentID, Quaternion rotation); |
688 | 688 | ||
689 | void SendAvatarTerseUpdate(ulong regionHandle, ushort timeDilation, uint localID, Vector3 position, | 689 | void SendAvatarTerseUpdate(ulong regionHandle, ushort timeDilation, uint localID, Vector3 position, |
diff --git a/OpenSim/Region/ClientStack/LindenUDP/LLClientView.cs b/OpenSim/Region/ClientStack/LindenUDP/LLClientView.cs index d24b54d..3c9034b 100644 --- a/OpenSim/Region/ClientStack/LindenUDP/LLClientView.cs +++ b/OpenSim/Region/ClientStack/LindenUDP/LLClientView.cs | |||
@@ -2308,7 +2308,7 @@ namespace OpenSim.Region.ClientStack.LindenUDP | |||
2308 | /// <param name="avatarID"></param> | 2308 | /// <param name="avatarID"></param> |
2309 | /// <param name="avatarLocalID"></param> | 2309 | /// <param name="avatarLocalID"></param> |
2310 | /// <param name="Pos"></param> | 2310 | /// <param name="Pos"></param> |
2311 | public void SendAvatarData(ulong regionHandle, string firstName, string lastName, UUID avatarID, | 2311 | public void SendAvatarData(ulong regionHandle, string firstName, string lastName, string grouptitle, UUID avatarID, |
2312 | uint avatarLocalID, Vector3 Pos, byte[] textureEntry, uint parentID, Quaternion rotation) | 2312 | uint avatarLocalID, Vector3 Pos, byte[] textureEntry, uint parentID, Quaternion rotation) |
2313 | { | 2313 | { |
2314 | ObjectUpdatePacket objupdate = (ObjectUpdatePacket)PacketPool.Instance.GetPacket(PacketType.ObjectUpdate); | 2314 | ObjectUpdatePacket objupdate = (ObjectUpdatePacket)PacketPool.Instance.GetPacket(PacketType.ObjectUpdate); |
@@ -2323,7 +2323,7 @@ namespace OpenSim.Region.ClientStack.LindenUDP | |||
2323 | objupdate.ObjectData[0].FullID = avatarID; | 2323 | objupdate.ObjectData[0].FullID = avatarID; |
2324 | objupdate.ObjectData[0].ParentID = parentID; | 2324 | objupdate.ObjectData[0].ParentID = parentID; |
2325 | objupdate.ObjectData[0].NameValue = | 2325 | objupdate.ObjectData[0].NameValue = |
2326 | Utils.StringToBytes("FirstName STRING RW SV " + firstName + "\nLastName STRING RW SV " + lastName); | 2326 | Utils.StringToBytes("FirstName STRING RW SV " + firstName + "\nLastName STRING RW SV " + lastName + "\nTitle STRING RW SV " + grouptitle); |
2327 | 2327 | ||
2328 | Vector3 pos2 = new Vector3((float)Pos.X, (float)Pos.Y, (float)Pos.Z); | 2328 | Vector3 pos2 = new Vector3((float)Pos.X, (float)Pos.Y, (float)Pos.Z); |
2329 | byte[] pb = pos2.GetBytes(); | 2329 | byte[] pb = pos2.GetBytes(); |
diff --git a/OpenSim/Region/Environment/Modules/Avatar/InstantMessage/InstantMessageModule.cs b/OpenSim/Region/Environment/Modules/Avatar/InstantMessage/InstantMessageModule.cs index 3e45f7f..2553266 100644 --- a/OpenSim/Region/Environment/Modules/Avatar/InstantMessage/InstantMessageModule.cs +++ b/OpenSim/Region/Environment/Modules/Avatar/InstantMessage/InstantMessageModule.cs | |||
@@ -118,13 +118,17 @@ namespace OpenSim.Region.Environment.Modules.Avatar.InstantMessage | |||
118 | || dialog == (byte) InstantMessageDialog.InventoryOffered | 118 | || dialog == (byte) InstantMessageDialog.InventoryOffered |
119 | || dialog == (byte) InstantMessageDialog.InventoryAccepted | 119 | || dialog == (byte) InstantMessageDialog.InventoryAccepted |
120 | || dialog == (byte) InstantMessageDialog.InventoryDeclined | 120 | || dialog == (byte) InstantMessageDialog.InventoryDeclined |
121 | || dialog == (byte) InstantMessageDialog.GroupNoticeInventoryAccepted | ||
122 | || dialog == (byte) InstantMessageDialog.GroupNoticeInventoryDeclined | ||
123 | || dialog == (byte) InstantMessageDialog.GroupInvitationAccept | ||
124 | || dialog == (byte) InstantMessageDialog.GroupInvitationDecline | ||
121 | || dialog == (byte) InstantMessageDialog.GroupNotice); | 125 | || dialog == (byte) InstantMessageDialog.GroupNotice); |
122 | 126 | ||
123 | // IM dialogs need to be pre-processed and have their sessionID filled by the server | 127 | // IM dialogs need to be pre-processed and have their sessionID filled by the server |
124 | // so the sim can match the transaction on the return packet. | 128 | // so the sim can match the transaction on the return packet. |
125 | 129 | ||
126 | // Don't send a Friend Dialog IM with a UUID.Zero session. | 130 | // Don't send a Friend Dialog IM with a UUID.Zero session. |
127 | if (!(dialogHandledElsewhere && imSessionID == UUID.Zero)) | 131 | if (!dialogHandledElsewhere) |
128 | { | 132 | { |
129 | // Try root avatar only first | 133 | // Try root avatar only first |
130 | foreach (Scene scene in m_scenes) | 134 | foreach (Scene scene in m_scenes) |
@@ -137,7 +141,7 @@ namespace OpenSim.Region.Environment.Modules.Avatar.InstantMessage | |||
137 | { | 141 | { |
138 | user.ControllingClient.SendInstantMessage(fromAgentID, fromAgentSession, message, | 142 | user.ControllingClient.SendInstantMessage(fromAgentID, fromAgentSession, message, |
139 | toAgentID, imSessionID, fromAgentName, dialog, | 143 | toAgentID, imSessionID, fromAgentName, dialog, |
140 | timestamp); | 144 | timestamp, fromGroup, binaryBucket); |
141 | // Message sent | 145 | // Message sent |
142 | return; | 146 | return; |
143 | } | 147 | } |
@@ -154,7 +158,7 @@ namespace OpenSim.Region.Environment.Modules.Avatar.InstantMessage | |||
154 | 158 | ||
155 | user.ControllingClient.SendInstantMessage(fromAgentID, fromAgentSession, message, | 159 | user.ControllingClient.SendInstantMessage(fromAgentID, fromAgentSession, message, |
156 | toAgentID, imSessionID, fromAgentName, dialog, | 160 | toAgentID, imSessionID, fromAgentName, dialog, |
157 | timestamp); | 161 | timestamp, fromGroup, binaryBucket); |
158 | // Message sent | 162 | // Message sent |
159 | return; | 163 | return; |
160 | } | 164 | } |
diff --git a/OpenSim/Region/Environment/Modules/World/NPC/NPCAvatar.cs b/OpenSim/Region/Environment/Modules/World/NPC/NPCAvatar.cs index 5c22bb1..3e78396 100644 --- a/OpenSim/Region/Environment/Modules/World/NPC/NPCAvatar.cs +++ b/OpenSim/Region/Environment/Modules/World/NPC/NPCAvatar.cs | |||
@@ -547,7 +547,7 @@ namespace OpenSim.Region.Environment.Modules.World.NPC | |||
547 | { | 547 | { |
548 | } | 548 | } |
549 | 549 | ||
550 | public virtual void SendAvatarData(ulong regionHandle, string firstName, string lastName, UUID avatarID, | 550 | public virtual void SendAvatarData(ulong regionHandle, string firstName, string lastName, string grouptitle, UUID avatarID, |
551 | uint avatarLocalID, Vector3 Pos, byte[] textureEntry, uint parentID, Quaternion rotation) | 551 | uint avatarLocalID, Vector3 Pos, byte[] textureEntry, uint parentID, Quaternion rotation) |
552 | { | 552 | { |
553 | } | 553 | } |
diff --git a/OpenSim/Region/Environment/Scenes/ScenePresence.cs b/OpenSim/Region/Environment/Scenes/ScenePresence.cs index a8476fd..38427cf 100644 --- a/OpenSim/Region/Environment/Scenes/ScenePresence.cs +++ b/OpenSim/Region/Environment/Scenes/ScenePresence.cs | |||
@@ -284,6 +284,14 @@ namespace OpenSim.Region.Environment.Scenes | |||
284 | get { return m_lastname; } | 284 | get { return m_lastname; } |
285 | } | 285 | } |
286 | 286 | ||
287 | private string m_grouptitle; | ||
288 | |||
289 | public string Grouptitle | ||
290 | { | ||
291 | get { return m_grouptitle; } | ||
292 | set { m_grouptitle = value; } | ||
293 | } | ||
294 | |||
287 | public float DrawDistance | 295 | public float DrawDistance |
288 | { | 296 | { |
289 | get { return m_DrawDistance; } | 297 | get { return m_DrawDistance; } |
@@ -484,6 +492,10 @@ namespace OpenSim.Region.Environment.Scenes | |||
484 | m_regionInfo = reginfo; | 492 | m_regionInfo = reginfo; |
485 | m_localId = m_scene.NextLocalId; | 493 | m_localId = m_scene.NextLocalId; |
486 | 494 | ||
495 | IGroupsModule gm = m_scene.RequestModuleInterface<IGroupsModule>(); | ||
496 | if (gm != null) | ||
497 | m_grouptitle = gm.GetGroupTitle(m_uuid); | ||
498 | |||
487 | AbsolutePosition = m_controllingClient.StartPos; | 499 | AbsolutePosition = m_controllingClient.StartPos; |
488 | 500 | ||
489 | TrySetMovementAnimation("STAND"); // TODO: I think, this won't send anything, as we are still a child here... | 501 | TrySetMovementAnimation("STAND"); // TODO: I think, this won't send anything, as we are still a child here... |
@@ -691,6 +703,10 @@ namespace OpenSim.Region.Environment.Scenes | |||
691 | /// </summary> | 703 | /// </summary> |
692 | public void MakeRootAgent(Vector3 pos, bool isFlying) | 704 | public void MakeRootAgent(Vector3 pos, bool isFlying) |
693 | { | 705 | { |
706 | IGroupsModule gm = m_scene.RequestModuleInterface<IGroupsModule>(); | ||
707 | if (gm != null) | ||
708 | m_grouptitle = gm.GetGroupTitle(m_uuid); | ||
709 | |||
694 | m_scene.SetRootAgentScene(m_uuid); | 710 | m_scene.SetRootAgentScene(m_uuid); |
695 | 711 | ||
696 | IAvatarFactory ava = m_scene.RequestModuleInterface<IAvatarFactory>(); | 712 | IAvatarFactory ava = m_scene.RequestModuleInterface<IAvatarFactory>(); |
@@ -1755,7 +1771,7 @@ namespace OpenSim.Region.Environment.Scenes | |||
1755 | // Note: because Quaternion is a struct, it can't be null | 1771 | // Note: because Quaternion is a struct, it can't be null |
1756 | Quaternion rot = m_bodyRot; | 1772 | Quaternion rot = m_bodyRot; |
1757 | 1773 | ||
1758 | remoteAvatar.m_controllingClient.SendAvatarData(m_regionInfo.RegionHandle, m_firstname, m_lastname, m_uuid, | 1774 | remoteAvatar.m_controllingClient.SendAvatarData(m_regionInfo.RegionHandle, m_firstname, m_lastname, m_grouptitle, m_uuid, |
1759 | LocalId, m_pos, m_appearance.Texture.ToBytes(), | 1775 | LocalId, m_pos, m_appearance.Texture.ToBytes(), |
1760 | m_parentID, rot); | 1776 | m_parentID, rot); |
1761 | m_scene.AddAgentUpdates(1); | 1777 | m_scene.AddAgentUpdates(1); |
@@ -1804,6 +1820,8 @@ namespace OpenSim.Region.Environment.Scenes | |||
1804 | } | 1820 | } |
1805 | m_scene.AddAgentUpdates(avatars.Count); | 1821 | m_scene.AddAgentUpdates(avatars.Count); |
1806 | m_scene.AddAgentTime(System.Environment.TickCount - m_perfMonMS); | 1822 | m_scene.AddAgentTime(System.Environment.TickCount - m_perfMonMS); |
1823 | |||
1824 | SendAnimPack(); | ||
1807 | } | 1825 | } |
1808 | 1826 | ||
1809 | /// <summary> | 1827 | /// <summary> |
@@ -1818,7 +1836,7 @@ namespace OpenSim.Region.Environment.Scenes | |||
1818 | // Note: because Quaternion is a struct, it can't be null | 1836 | // Note: because Quaternion is a struct, it can't be null |
1819 | Quaternion rot = m_bodyRot; | 1837 | Quaternion rot = m_bodyRot; |
1820 | 1838 | ||
1821 | m_controllingClient.SendAvatarData(m_regionInfo.RegionHandle, m_firstname, m_lastname, m_uuid, LocalId, | 1839 | m_controllingClient.SendAvatarData(m_regionInfo.RegionHandle, m_firstname, m_lastname, m_grouptitle, m_uuid, LocalId, |
1822 | m_pos, m_appearance.Texture.ToBytes(), m_parentID, rot); | 1840 | m_pos, m_appearance.Texture.ToBytes(), m_parentID, rot); |
1823 | 1841 | ||
1824 | if (!m_isChildAgent) | 1842 | if (!m_isChildAgent) |
diff --git a/OpenSim/Region/Examples/SimpleModule/MyNpcCharacter.cs b/OpenSim/Region/Examples/SimpleModule/MyNpcCharacter.cs index ad2fcdf..600cc1b 100644 --- a/OpenSim/Region/Examples/SimpleModule/MyNpcCharacter.cs +++ b/OpenSim/Region/Examples/SimpleModule/MyNpcCharacter.cs | |||
@@ -459,7 +459,7 @@ namespace OpenSim.Region.Examples.SimpleModule | |||
459 | { | 459 | { |
460 | } | 460 | } |
461 | 461 | ||
462 | public virtual void SendAvatarData(ulong regionHandle, string firstName, string lastName, UUID avatarID, | 462 | public virtual void SendAvatarData(ulong regionHandle, string firstName, string lastName, string grouptitle, UUID avatarID, |
463 | uint avatarLocalID, Vector3 Pos, byte[] textureEntry, uint parentID, Quaternion rotation) | 463 | uint avatarLocalID, Vector3 Pos, byte[] textureEntry, uint parentID, Quaternion rotation) |
464 | { | 464 | { |
465 | } | 465 | } |
diff --git a/OpenSim/Region/Interfaces/IGroupsModule.cs b/OpenSim/Region/Interfaces/IGroupsModule.cs index f5193c3..d428297 100644 --- a/OpenSim/Region/Interfaces/IGroupsModule.cs +++ b/OpenSim/Region/Interfaces/IGroupsModule.cs | |||
@@ -50,6 +50,7 @@ namespace OpenSim.Region.Interfaces | |||
50 | UUID CreateGroup(IClientAPI remoteClient, string name, string charter, bool showInList, UUID insigniaID, int membershipFee, bool openEnrollment, bool allowPublish, bool maturePublish); | 50 | UUID CreateGroup(IClientAPI remoteClient, string name, string charter, bool showInList, UUID insigniaID, int membershipFee, bool openEnrollment, bool allowPublish, bool maturePublish); |
51 | 51 | ||
52 | GroupNoticeData[] GroupNoticesListRequest(IClientAPI remoteClient, UUID GroupID); | 52 | GroupNoticeData[] GroupNoticesListRequest(IClientAPI remoteClient, UUID GroupID); |
53 | string GetGroupTitle(UUID avatarID); | ||
53 | void GroupNoticeRequest(IClientAPI remoteClient, UUID groupNoticeID); | 54 | void GroupNoticeRequest(IClientAPI remoteClient, UUID groupNoticeID); |
54 | void SendAgentGroupDataUpdate(IClientAPI remoteClient); | 55 | void SendAgentGroupDataUpdate(IClientAPI remoteClient); |
55 | } | 56 | } |