Remove a hardcoded flow/dependency on the money module from LLCLientView
parent
561f241564
commit
37e81c7d54
|
@ -1589,5 +1589,8 @@ namespace OpenSim.Client.MXP.ClientStack
|
||||||
|
|
||||||
#endregion
|
#endregion
|
||||||
|
|
||||||
|
public void SendCreateGroupReply(UUID groupID, bool success, string message)
|
||||||
|
{
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -1057,6 +1057,8 @@ namespace OpenSim.Framework
|
||||||
|
|
||||||
void SendLeaveGroupReply(UUID groupID, bool success);
|
void SendLeaveGroupReply(UUID groupID, bool success);
|
||||||
|
|
||||||
|
void SendCreateGroupReply(UUID groupID, bool success, string message);
|
||||||
|
|
||||||
void SendLandStatReply(uint reportType, uint requestFlags, uint resultCount, LandStatReportItem[] lsrpia);
|
void SendLandStatReply(uint reportType, uint requestFlags, uint resultCount, LandStatReportItem[] lsrpia);
|
||||||
|
|
||||||
void SendScriptRunningReply(UUID objectID, UUID itemID, bool running);
|
void SendScriptRunningReply(UUID objectID, UUID itemID, bool running);
|
||||||
|
|
|
@ -7194,25 +7194,6 @@ namespace OpenSim.Region.ClientStack.LindenUDP
|
||||||
|
|
||||||
if (m_GroupsModule != null)
|
if (m_GroupsModule != null)
|
||||||
{
|
{
|
||||||
CreateGroupReplyPacket createGroupReply = (CreateGroupReplyPacket)PacketPool.Instance.GetPacket(PacketType.CreateGroupReply);
|
|
||||||
|
|
||||||
createGroupReply.AgentData =
|
|
||||||
new CreateGroupReplyPacket.AgentDataBlock();
|
|
||||||
createGroupReply.ReplyData =
|
|
||||||
new CreateGroupReplyPacket.ReplyDataBlock();
|
|
||||||
|
|
||||||
createGroupReply.AgentData.AgentID = AgentId;
|
|
||||||
createGroupReply.ReplyData.GroupID = UUID.Zero;
|
|
||||||
|
|
||||||
IMoneyModule money = m_scene.RequestModuleInterface<IMoneyModule>();
|
|
||||||
if (money != null && !money.GroupCreationCovered(this))
|
|
||||||
{
|
|
||||||
createGroupReply.ReplyData.Success = false;
|
|
||||||
createGroupReply.ReplyData.Message = Utils.StringToBytes("You do not have sufficient funds to create a group");
|
|
||||||
OutPacket(createGroupReply, ThrottleOutPacketType.Task);
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
|
|
||||||
UUID groupID = m_GroupsModule.CreateGroup(this,
|
UUID groupID = m_GroupsModule.CreateGroup(this,
|
||||||
Utils.BytesToString(createGroupRequest.GroupData.Name),
|
Utils.BytesToString(createGroupRequest.GroupData.Name),
|
||||||
Utils.BytesToString(createGroupRequest.GroupData.Charter),
|
Utils.BytesToString(createGroupRequest.GroupData.Charter),
|
||||||
|
@ -7222,26 +7203,6 @@ namespace OpenSim.Region.ClientStack.LindenUDP
|
||||||
createGroupRequest.GroupData.OpenEnrollment,
|
createGroupRequest.GroupData.OpenEnrollment,
|
||||||
createGroupRequest.GroupData.AllowPublish,
|
createGroupRequest.GroupData.AllowPublish,
|
||||||
createGroupRequest.GroupData.MaturePublish);
|
createGroupRequest.GroupData.MaturePublish);
|
||||||
if (groupID == UUID.Zero)
|
|
||||||
{
|
|
||||||
createGroupReply.ReplyData.Success = false;
|
|
||||||
createGroupReply.ReplyData.Message = Utils.StringToBytes("We're sorry, but we could not create the requested group. Please try another name");
|
|
||||||
OutPacket(createGroupReply, ThrottleOutPacketType.Task);
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (money != null)
|
|
||||||
money.ApplyGroupCreationCharge(AgentId);
|
|
||||||
|
|
||||||
createGroupReply.ReplyData.Success = true;
|
|
||||||
createGroupReply.ReplyData.GroupID = groupID;
|
|
||||||
createGroupReply.ReplyData.Message = Utils.StringToBytes("Group created");
|
|
||||||
OutPacket(createGroupReply, ThrottleOutPacketType.Task);
|
|
||||||
|
|
||||||
// Sync with event queue
|
|
||||||
Thread.Sleep(1000);
|
|
||||||
|
|
||||||
m_GroupsModule.SendAgentGroupDataUpdate(this);
|
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
|
||||||
|
@ -8638,6 +8599,23 @@ namespace OpenSim.Region.ClientStack.LindenUDP
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public void SendCreateGroupReply(UUID groupID, bool success, string message)
|
||||||
|
{
|
||||||
|
CreateGroupReplyPacket createGroupReply = (CreateGroupReplyPacket)PacketPool.Instance.GetPacket(PacketType.CreateGroupReply);
|
||||||
|
|
||||||
|
createGroupReply.AgentData =
|
||||||
|
new CreateGroupReplyPacket.AgentDataBlock();
|
||||||
|
createGroupReply.ReplyData =
|
||||||
|
new CreateGroupReplyPacket.ReplyDataBlock();
|
||||||
|
|
||||||
|
createGroupReply.AgentData.AgentID = AgentId;
|
||||||
|
createGroupReply.ReplyData.GroupID = groupID;
|
||||||
|
|
||||||
|
createGroupReply.ReplyData.Success = success;
|
||||||
|
createGroupReply.ReplyData.Message = Utils.StringToBytes(message);
|
||||||
|
OutPacket(createGroupReply, ThrottleOutPacketType.Task);
|
||||||
|
}
|
||||||
|
|
||||||
public string Report()
|
public string Report()
|
||||||
{
|
{
|
||||||
LLPacketHandler handler = (LLPacketHandler) m_PacketHandler;
|
LLPacketHandler handler = (LLPacketHandler) m_PacketHandler;
|
||||||
|
|
|
@ -1053,6 +1053,10 @@ namespace OpenSim.Region.Examples.SimpleModule
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public void SendCreateGroupReply(UUID groupID, bool success, string message)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
#endregion
|
#endregion
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -1053,6 +1053,10 @@ namespace OpenSim.Region.OptionalModules.World.NPC
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public void SendCreateGroupReply(UUID groupID, bool success, string message)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
#endregion
|
#endregion
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -1094,5 +1094,9 @@ namespace OpenSim.Tests.Common.Mock
|
||||||
public void SendUserInfoReply(bool imViaEmail, bool visible, string email)
|
public void SendUserInfoReply(bool imViaEmail, bool visible, string email)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public void SendCreateGroupReply(UUID groupID, bool success, string message)
|
||||||
|
{
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue