aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region
diff options
context:
space:
mode:
Diffstat (limited to 'OpenSim/Region')
-rw-r--r--OpenSim/Region/ClientStack/LindenUDP/LLClientView.cs100
1 files changed, 61 insertions, 39 deletions
diff --git a/OpenSim/Region/ClientStack/LindenUDP/LLClientView.cs b/OpenSim/Region/ClientStack/LindenUDP/LLClientView.cs
index 5eaaf12..195e9aa 100644
--- a/OpenSim/Region/ClientStack/LindenUDP/LLClientView.cs
+++ b/OpenSim/Region/ClientStack/LindenUDP/LLClientView.cs
@@ -824,40 +824,50 @@ namespace OpenSim.Region.ClientStack.LindenUDP
824 gmp.ParamList[i++].Parameter = Util.StringToBytes256(val); 824 gmp.ParamList[i++].Parameter = Util.StringToBytes256(val);
825 } 825 }
826 OutPacket(gmp, ThrottleOutPacketType.Task); 826 OutPacket(gmp, ThrottleOutPacketType.Task);
827 } 827 }
828 828 public struct GroupActiveProposals
829 public void SendGroupActiveProposals(IClientAPI sender,UUID agentID, UUID sessionID, UUID groupID, UUID transactionID, string[] VoteID, string[] VoteInitiator, string[] Majority, string[] Quorum, string[] TerseDateID, string[] StartDateTime, string[] EndDateTime, string[] ProposalText)
830 { 829 {
831 int i = 0; 830 public string VoteID;
832 foreach (string voteID in VoteID) 831 public string VoteInitiator;
832 public string Majority;
833 public string Quorum;
834 public string TerseDateID;
835 public string StartDateTime;
836 public string EndDateTime;
837 public string ProposalText;
838 }
839 public void SendGroupActiveProposals(UUID groupID, UUID transactionID, GroupActiveProposals[] Proposals)
840 {
841 int i = 0;
842 foreach (GroupActiveProposals Proposal in Proposals)
833 { 843 {
834 GroupActiveProposalItemReplyPacket GAPIRP = new GroupActiveProposalItemReplyPacket(); 844 GroupActiveProposalItemReplyPacket GAPIRP = new GroupActiveProposalItemReplyPacket();
835 845
836 GAPIRP.AgentData.AgentID = agentID; 846 GAPIRP.AgentData.AgentID = AgentId;
837 GAPIRP.AgentData.GroupID = groupID; 847 GAPIRP.AgentData.GroupID = groupID;
838 GAPIRP.TransactionData.TransactionID = transactionID; 848 GAPIRP.TransactionData.TransactionID = transactionID;
839 GAPIRP.TransactionData.TotalNumItems = ((uint)i+1); 849 GAPIRP.TransactionData.TotalNumItems = ((uint)i+1);
840 GroupActiveProposalItemReplyPacket.ProposalDataBlock ProposalData = new GroupActiveProposalItemReplyPacket.ProposalDataBlock(); 850 GroupActiveProposalItemReplyPacket.ProposalDataBlock ProposalData = new GroupActiveProposalItemReplyPacket.ProposalDataBlock();
841 GAPIRP.ProposalData = new GroupActiveProposalItemReplyPacket.ProposalDataBlock[1]; 851 GAPIRP.ProposalData = new GroupActiveProposalItemReplyPacket.ProposalDataBlock[1];
842 ProposalData.VoteCast = Utils.StringToBytes("false"); 852 ProposalData.VoteCast = Utils.StringToBytes("false");
843 ProposalData.VoteID = new UUID(VoteID[i]); 853 ProposalData.VoteID = new UUID(Proposal.VoteID);
844 ProposalData.VoteInitiator = new UUID(VoteInitiator[i]); 854 ProposalData.VoteInitiator = new UUID(Proposal.VoteInitiator);
845 ProposalData.Majority = (float)Convert.ToInt32(Majority[i]); 855 ProposalData.Majority = (float)Convert.ToInt32(Proposal.Majority);
846 ProposalData.Quorum = Convert.ToInt32(Quorum[i]); 856 ProposalData.Quorum = Convert.ToInt32(Proposal.Quorum);
847 ProposalData.TerseDateID = Utils.StringToBytes(TerseDateID[i]); 857 ProposalData.TerseDateID = Utils.StringToBytes(Proposal.TerseDateID);
848 ProposalData.StartDateTime = Utils.StringToBytes(StartDateTime[i]); 858 ProposalData.StartDateTime = Utils.StringToBytes(Proposal.StartDateTime);
849 ProposalData.EndDateTime = Utils.StringToBytes(EndDateTime[i]); 859 ProposalData.EndDateTime = Utils.StringToBytes(Proposal.EndDateTime);
850 ProposalData.ProposalText = Utils.StringToBytes(ProposalText[i]); 860 ProposalData.ProposalText = Utils.StringToBytes(Proposal.ProposalText);
851 ProposalData.AlreadyVoted = false; 861 ProposalData.AlreadyVoted = false;
852 GAPIRP.ProposalData[i] = ProposalData; 862 GAPIRP.ProposalData[i] = ProposalData;
853 OutPacket(GAPIRP, ThrottleOutPacketType.Task); 863 OutPacket(GAPIRP, ThrottleOutPacketType.Task);
854 i++; 864 i++;
855 } 865 }
856 if (VoteID.Length == 0) 866 if (Proposals.Length == 0)
857 { 867 {
858 GroupActiveProposalItemReplyPacket GAPIRP = new GroupActiveProposalItemReplyPacket(); 868 GroupActiveProposalItemReplyPacket GAPIRP = new GroupActiveProposalItemReplyPacket();
859 869
860 GAPIRP.AgentData.AgentID = agentID; 870 GAPIRP.AgentData.AgentID = AgentId;
861 GAPIRP.AgentData.GroupID = groupID; 871 GAPIRP.AgentData.GroupID = groupID;
862 GAPIRP.TransactionData.TransactionID = transactionID; 872 GAPIRP.TransactionData.TransactionID = transactionID;
863 GAPIRP.TransactionData.TotalNumItems = 1; 873 GAPIRP.TransactionData.TotalNumItems = 1;
@@ -876,29 +886,41 @@ namespace OpenSim.Region.ClientStack.LindenUDP
876 GAPIRP.ProposalData[0] = ProposalData; 886 GAPIRP.ProposalData[0] = ProposalData;
877 OutPacket(GAPIRP, ThrottleOutPacketType.Task); 887 OutPacket(GAPIRP, ThrottleOutPacketType.Task);
878 } 888 }
879 } 889 }
880 890 public struct GroupVoteHistory
881 public void SendGroupVoteHistory(IClientAPI sender,UUID agentID, UUID sessionID, UUID groupID, UUID transactionID, string[] VoteID, string[] VoteInitiator, string[] Majority, string[] Quorum, string[] TerseDateID, string[] StartDateTime, string[] EndDateTime, string[] VoteType, string[] VoteResult, string[] ProposalText)
882 { 891 {
883 int i = 0; 892 public string VoteID;
884 foreach (string voteID in VoteID) 893 public string VoteInitiator;
894 public string Majority;
895 public string Quorum;
896 public string TerseDateID;
897 public string StartDateTime;
898 public string EndDateTime;
899 public string VoteType;
900 public string VoteResult;
901 public string ProposalText;
902 }
903 public void SendGroupVoteHistory(UUID groupID, UUID transactionID, GroupVoteHistory[] Votes)
904 {
905 int i = 0;
906 foreach (GroupVoteHistory Vote in Votes)
885 { 907 {
886 GroupVoteHistoryItemReplyPacket GVHIRP = new GroupVoteHistoryItemReplyPacket(); 908 GroupVoteHistoryItemReplyPacket GVHIRP = new GroupVoteHistoryItemReplyPacket();
887 909
888 GVHIRP.AgentData.AgentID = agentID; 910 GVHIRP.AgentData.AgentID = AgentId;
889 GVHIRP.AgentData.GroupID = groupID; 911 GVHIRP.AgentData.GroupID = groupID;
890 GVHIRP.TransactionData.TransactionID = transactionID; 912 GVHIRP.TransactionData.TransactionID = transactionID;
891 GVHIRP.TransactionData.TotalNumItems = ((uint)i+1); 913 GVHIRP.TransactionData.TotalNumItems = ((uint)i+1);
892 GVHIRP.HistoryItemData.VoteID = new UUID(VoteID[i]); 914 GVHIRP.HistoryItemData.VoteID = new UUID(Vote.VoteID);
893 GVHIRP.HistoryItemData.VoteInitiator = new UUID(VoteInitiator[i]); 915 GVHIRP.HistoryItemData.VoteInitiator = new UUID(Vote.VoteInitiator);
894 GVHIRP.HistoryItemData.Majority = (float)Convert.ToInt32(Majority[i]); 916 GVHIRP.HistoryItemData.Majority = (float)Convert.ToInt32(Vote.Majority);
895 GVHIRP.HistoryItemData.Quorum = Convert.ToInt32(Quorum[i]); 917 GVHIRP.HistoryItemData.Quorum = Convert.ToInt32(Vote.Quorum);
896 GVHIRP.HistoryItemData.TerseDateID = Utils.StringToBytes(TerseDateID[i]); 918 GVHIRP.HistoryItemData.TerseDateID = Utils.StringToBytes(Vote.TerseDateID);
897 GVHIRP.HistoryItemData.StartDateTime = Utils.StringToBytes(StartDateTime[i]); 919 GVHIRP.HistoryItemData.StartDateTime = Utils.StringToBytes(Vote.StartDateTime);
898 GVHIRP.HistoryItemData.EndDateTime = Utils.StringToBytes(EndDateTime[i]); 920 GVHIRP.HistoryItemData.EndDateTime = Utils.StringToBytes(Vote.EndDateTime);
899 GVHIRP.HistoryItemData.VoteType = Utils.StringToBytes(VoteType[i]); 921 GVHIRP.HistoryItemData.VoteType = Utils.StringToBytes(Vote.VoteType);
900 GVHIRP.HistoryItemData.VoteResult = Utils.StringToBytes(VoteResult[i]); 922 GVHIRP.HistoryItemData.VoteResult = Utils.StringToBytes(Vote.VoteResult);
901 GVHIRP.HistoryItemData.ProposalText = Utils.StringToBytes(ProposalText[i]); 923 GVHIRP.HistoryItemData.ProposalText = Utils.StringToBytes(Vote.ProposalText);
902 GroupVoteHistoryItemReplyPacket.VoteItemBlock VoteItem = new GroupVoteHistoryItemReplyPacket.VoteItemBlock(); 924 GroupVoteHistoryItemReplyPacket.VoteItemBlock VoteItem = new GroupVoteHistoryItemReplyPacket.VoteItemBlock();
903 GVHIRP.VoteItem = new GroupVoteHistoryItemReplyPacket.VoteItemBlock[1]; 925 GVHIRP.VoteItem = new GroupVoteHistoryItemReplyPacket.VoteItemBlock[1];
904 VoteItem.CandidateID = UUID.Zero; 926 VoteItem.CandidateID = UUID.Zero;
@@ -908,11 +930,11 @@ namespace OpenSim.Region.ClientStack.LindenUDP
908 OutPacket(GVHIRP, ThrottleOutPacketType.Task); 930 OutPacket(GVHIRP, ThrottleOutPacketType.Task);
909 i++; 931 i++;
910 } 932 }
911 if (VoteID.Length == 0) 933 if (Votes.Length == 0)
912 { 934 {
913 GroupVoteHistoryItemReplyPacket GVHIRP = new GroupVoteHistoryItemReplyPacket(); 935 GroupVoteHistoryItemReplyPacket GVHIRP = new GroupVoteHistoryItemReplyPacket();
914 936
915 GVHIRP.AgentData.AgentID = agentID; 937 GVHIRP.AgentData.AgentID = AgentId;
916 GVHIRP.AgentData.GroupID = groupID; 938 GVHIRP.AgentData.GroupID = groupID;
917 GVHIRP.TransactionData.TransactionID = transactionID; 939 GVHIRP.TransactionData.TransactionID = transactionID;
918 GVHIRP.TransactionData.TotalNumItems = 0; 940 GVHIRP.TransactionData.TotalNumItems = 0;