diff -Nur aurora-/Aurora/AuroraDotNetEngine/APIs/LSL_Api.cs aurora/Aurora/AuroraDotNetEngine/APIs/LSL_Api.cs --- aurora-/Aurora/AuroraDotNetEngine/APIs/LSL_Api.cs 2012-11-09 23:17:43.000000000 +0900 +++ aurora/Aurora/AuroraDotNetEngine/APIs/LSL_Api.cs 2012-11-12 10:43:48.000000000 +0900 @@ -12540,7 +12540,7 @@ data = llList2CSV(new LSL_Types.list("GROUP_OWNED")); else if (moneyMod != null) { - success = moneyMod.Transfer(UUID.Parse(destination), m_host.OwnerID, amt, ""); + success = moneyMod.ObjectGiveMoney(m_host.ParentEntity.UUID, m_host.OwnerID, UUID.Parse(destination), amt); data = llList2CSV(success ? new LSL_List(destination, amt) : new LSL_Types.list("LINDENDOLLAR_INSUFFICIENTFUNDS")); } else diff -Nur aurora-/Aurora/AuroraDotNetEngine/EventManager.cs aurora/Aurora/AuroraDotNetEngine/EventManager.cs --- aurora-/Aurora/AuroraDotNetEngine/EventManager.cs 2012-10-15 12:21:16.000000000 +0900 +++ aurora/Aurora/AuroraDotNetEngine/EventManager.cs 2012-11-11 14:38:30.000000000 +0900 @@ -111,43 +111,22 @@ if (money != null) { money.OnObjectPaid += HandleObjectPaid; - money.OnPostObjectPaid += HandlePostObjectPaid; } } - //private void HandleObjectPaid(UUID objectID, UUID agentID, int amount) - private bool HandleObjectPaid(UUID objectID, UUID agentID, int amount) + private void HandleObjectPaid(UUID objectID, UUID agentID, int amount) { - //bool ret = false; - //ISceneChildEntity part = m_scriptEngine.findPrim(objectID); - - //if (part == null) - // return; - - //MainConsole.Instance.Debug("Paid: " + objectID + " from " + agentID + ", amount " + amount); - //if (part.ParentGroup != null) - // part = part.ParentGroup.RootPart; - - //if (part != null) - //{ - // money(part.LocalId, agentID, amount); - //} - //if (part != null) - //{ - // MainConsole.Instance.Debug("Paid: " + objectID + " from " + agentID + ", amount " + amount); - // if (part.ParentEntity != null) part = part.ParentEntity.RootChild; - // if (part != null) - // { - // ret = money(part.LocalId, agentID, amount); - // } - //} - //return ret; - return true; - } + ISceneChildEntity part = m_scriptEngine.findPrim(objectID); - private bool HandlePostObjectPaid(uint localID, ulong regionHandle, UUID agentID, int amount) - { - return money(localID, agentID, amount); + if (part == null) return; + + if (part.ParentEntity != null) part = part.ParentEntity.RootChild; + if (part != null) + { + MainConsole.Instance.Debug("Paid: " + objectID + " from " + agentID + ", amount " + amount); + money(part.LocalId, agentID, amount); + } + return; } public void changed(ISceneChildEntity part, uint change) @@ -334,19 +313,18 @@ CoalescedTouchEvents[part.LocalId] = det; } - //public void money(uint localID, UUID agentID, int amount) - public bool money(uint localID, UUID agentID, int amount) + public void money(uint localID, UUID agentID, int amount) { - bool ret = false; ISceneChildEntity part = m_scriptEngine.findPrim(localID); - if (part == null) return ret; + if (part == null) return; ScriptData[] datas = ScriptEngine.ScriptProtection.GetScripts(part.UUID); if (datas == null || datas.Length == 0) { - datas = ScriptEngine.ScriptProtection.GetScripts(part.ParentEntity.UUID); - if (datas == null || datas.Length == 0) return ret; + //datas = ScriptEngine.ScriptProtection.GetScripts(part.ParentEntity.UUID); + //if (datas == null || datas.Length == 0) return ret; + return; } string functionName = "money"; object[] param = new object[] @@ -361,7 +339,6 @@ if (CheckIfEventShouldFire(ID, functionName, param)) { m_scriptEngine.AddToScriptQueue(ID, functionName, new DetectParams[0], EventPriority.FirstStart, param); - ret = true; } } #else @@ -369,10 +346,9 @@ { m_scriptEngine.AddToScriptQueue(ID, functionName, new DetectParams[0], EventPriority.FirstStart, param); - ret = true; } #endif - return ret; + return; } public void collision_start(ISceneChildEntity part, ColliderArgs col) @@ -1266,4 +1242,4 @@ } } } -} \ No newline at end of file +} diff -Nur aurora-/Aurora/Framework/Modules/IMoneyModule.cs aurora/Aurora/Framework/Modules/IMoneyModule.cs --- aurora-/Aurora/Framework/Modules/IMoneyModule.cs 2012-10-15 12:21:16.000000000 +0900 +++ aurora/Aurora/Framework/Modules/IMoneyModule.cs 2012-11-12 11:13:15.000000000 +0900 @@ -31,32 +31,41 @@ namespace Aurora.Framework { - //public delegate void ObjectPaid(UUID objectID, UUID agentID, int amount); - // For legacy money module. Fumi.Iseki - public delegate bool ObjectPaid(UUID objectID, UUID agentID, int amount); - - // For DTL money module. - public delegate bool PostObjectPaid(uint localID, ulong regionHandle, UUID agentID, int amount); + public delegate void ObjectPaid(UUID objectID, UUID agentID, int amount); public enum TransactionType { - SystemGenerated = 0, - GroupCreate = 1002, - UploadFee = 1101, - AuctionFee = 1102, - ClassifiedFee = 1103, - DirectoryFee = 2003, - ClassifiedRenewFee = 2005, - Inventory = 3000, - ObjectBuy = 5000, - Gift = 5001, - LandSale = 5002, - LandPassFee = 5006, - PayIntoObject = 5008, - ObjectPaysAvatar = 5009, - GroupLiability = 6003, - GroupDividend = 6004, - StipendPayment = 10000 + //SystemGenerated = 0, + // One-Time Charges + GroupCreate = 1002, + GroupJoin = 1004, + UploadCharge = 1101, + LandAuction = 1102, + ClassifiedCharge= 1103, + // Recurrent Charges + ParcelDirFee = 2003, + ClassifiedRenew = 2005, + ScheduledFee = 2900, + // Inventory Transactions + GiveInventory = 3000, + // Transfers Between Users + ObjectSale = 5000, + Gift = 5001, + LandSale = 5002, + ReferBonus = 5003, + InvntorySale = 5004, + RefundPurchase = 5005, + LandPassSale = 5006, + DwellBonus = 5007, + PayObject = 5008, + ObjectPays = 5009, + BuyMoney = 5010, + MoveMoney = 5011, + // Group Transactions + GroupLiability = 6003, + GroupDividend = 6004, + // Stipend Credits + StipendPayment = 10000 } public class GroupBalance : IDataTransferable @@ -98,25 +107,30 @@ public interface IMoneyModule { - int UploadCharge { get; } - int GroupCreationCharge { get; } - int ClientPort { get; } - - bool ObjectGiveMoney(UUID objectID, UUID fromID, UUID toID, - int amount); - - int Balance(UUID agentID); - bool Charge(IClientAPI client, int amount); - bool Charge(UUID agentID, int amount, string text); - event ObjectPaid OnObjectPaid; - event PostObjectPaid OnPostObjectPaid; - bool Transfer(UUID toID, UUID fromID, int amount, string description); - bool Transfer(UUID toID, UUID fromID, int amount, string description, TransactionType type); + bool ObjectGiveMoney(UUID objectID, UUID fromID, UUID toID, int amount); + + int GetBalance(UUID agentID); + + bool UploadCovered(UUID agentID, int amount); + bool AmountCovered(UUID agentID, int amount); + + void ApplyUploadCharge(UUID agentID, int amount, string text); + void ApplyCharge(UUID agentID, int amount, TransactionType type, string text); + + int UploadCharge { get; } + int GroupCreationCharge { get; } + +// bool Transfer(UUID toID, UUID fromID, int amount, string description); +// bool Transfer(UUID toID, UUID fromID, int amount, string description, TransactionType type); +// bool Transfer(UUID toID, UUID fromID, UUID toObjectID, UUID fromObjectID, int amount, string description, TransactionType type); - bool Transfer(UUID toID, UUID fromID, UUID toObjectID, UUID fromObjectID, int amount, string description, - TransactionType type); + bool Transfer(UUID fromID, UUID toID, int parcelID, int amount, TransactionType type, string text); + bool Transfer(UUID fromID, UUID toID, UUID objectID, int amount, TransactionType type, string text); + + // + int ClientPort { get; } /// /// Get a list of transactions that have occured over the given interval (0 is this period of interval days, positive #s go back previous sets) @@ -130,6 +144,27 @@ GroupBalance GetGroupBalance(UUID groupID); } + // + public class MoneyTransferArgs : EventArgs + { + public UUID sender; + public UUID receiver; + public bool authenticated = false; + public int amount; + public int transactiontype; + public string description; + + public MoneyTransferArgs(UUID asender, UUID areceiver, int aamount, int atransactiontype, string adescription) + { + sender = asender; + receiver = areceiver; + amount = aamount; + transactiontype = atransactiontype; + description = adescription; + } + } + + public delegate void UserDidNotPay(UUID agentID, string paymentTextThatFailed); public delegate bool CheckWhetherUserShouldPay(UUID agentID, string paymentTextThatFailed); @@ -139,4 +174,4 @@ event CheckWhetherUserShouldPay OnCheckWhetherUserShouldPay; bool Charge(UUID agentID, int amount, string text, int daysUntilNextCharge); } -} \ No newline at end of file +} diff -Nur aurora-/Aurora/Modules/Agent/AssetTransaction/AssetTransactionModule.cs aurora/Aurora/Modules/Agent/AssetTransaction/AssetTransactionModule.cs --- aurora-/Aurora/Modules/Agent/AssetTransaction/AssetTransactionModule.cs 2012-10-15 12:21:16.000000000 +0900 +++ aurora/Aurora/Modules/Agent/AssetTransaction/AssetTransactionModule.cs 2012-11-11 15:08:49.000000000 +0900 @@ -303,11 +303,14 @@ if (mm != null) { - if (!mm.Charge(remoteClient, mm.UploadCharge)) + if (!mm.UploadCovered(remoteClient.AgentId, mm.UploadCharge)) { remoteClient.SendAgentAlertMessage("Unable to upload asset. Insufficient funds.", false); return; } + else { + mm.ApplyUploadCharge(remoteClient.AgentId, mm.UploadCharge, "Upload Asset"); + } } } @@ -356,4 +359,4 @@ #endregion } -} \ No newline at end of file +} diff -Nur aurora-/Aurora/Modules/Avatar/AuroraProfile/AvatarProfileModule.cs aurora/Aurora/Modules/Avatar/AuroraProfile/AvatarProfileModule.cs --- aurora-/Aurora/Modules/Avatar/AuroraProfile/AvatarProfileModule.cs 2012-10-15 12:21:16.000000000 +0900 +++ aurora/Aurora/Modules/Avatar/AuroraProfile/AvatarProfileModule.cs 2012-11-11 14:44:51.000000000 +0900 @@ -239,7 +239,7 @@ Classified classcheck = ProfileFrontend.GetClassified(queryclassifiedID); if (classcheck == null) { - if (!money.Charge(remoteClient.AgentId, queryclassifiedPrice, "Add Classified")) + if (!money.AmountCovered(remoteClient.AgentId, queryclassifiedPrice)) { remoteClient.SendAlertMessage("You do not have enough money to create this classified."); return; @@ -694,4 +694,4 @@ #endregion } -} \ No newline at end of file +} diff -Nur aurora-/Aurora/Modules/Avatar/Currency/ScheduledCurrencyTransferModule.cs aurora/Aurora/Modules/Avatar/Currency/ScheduledCurrencyTransferModule.cs --- aurora-/Aurora/Modules/Avatar/Currency/ScheduledCurrencyTransferModule.cs 2012-10-15 12:21:16.000000000 +0900 +++ aurora/Aurora/Modules/Avatar/Currency/ScheduledCurrencyTransferModule.cs 2012-11-12 11:16:26.000000000 +0900 @@ -52,9 +52,10 @@ IMoneyModule moneyModule = m_registry.RequestModuleInterface(); if (moneyModule != null) { - bool success = moneyModule.Charge(agentID, amount, text); - if (!success) - return false; + bool success = moneyModule.AmountCovered(agentID, amount); + if (!success) return false; + moneyModule.ApplyCharge(agentID, amount, TransactionType.ScheduledFee, text); + IScheduleService scheduler = m_registry.RequestModuleInterface(); if (scheduler != null) { @@ -84,8 +85,12 @@ int amount = itemInfo["Amount"]; if (CheckWhetherUserShouldPay(agentID, text)) { - bool success = moneyModule.Charge(agentID, amount, text); - if (!success) + bool success = moneyModule.AmountCovered(agentID, amount); + if (success) + { + moneyModule.ApplyCharge(agentID, amount, TransactionType.ScheduledFee, text); + } + else { if (OnUserDidNotPay != null) OnUserDidNotPay(agentID, text); diff -Nur aurora-/Aurora/Modules/Avatar/Groups/GroupMoneyModule.cs aurora/Aurora/Modules/Avatar/Groups/GroupMoneyModule.cs --- aurora-/Aurora/Modules/Avatar/Groups/GroupMoneyModule.cs 2012-10-15 12:21:16.000000000 +0900 +++ aurora/Aurora/Modules/Avatar/Groups/GroupMoneyModule.cs 2012-11-12 10:47:04.000000000 +0900 @@ -80,7 +80,7 @@ IMoneyModule moneyModule = client.Scene.RequestModuleInterface(); if (moneyModule != null) { - int amt = moneyModule.Balance(groupID); + int amt = moneyModule.GetBalance(groupID); List history = moneyModule.GetTransactions(groupID, agentID, currentInterval, intervalDays); history = (from h in history where h.Stipend select h).ToList();//We don't want payments, we only want stipends which we sent to users GroupBalance balance = moneyModule.GetGroupBalance(groupID); @@ -131,7 +131,7 @@ IMoneyModule moneyModule = client.Scene.RequestModuleInterface(); if (moneyModule != null) { - int amt = moneyModule.Balance(groupID); + int amt = moneyModule.GetBalance(groupID); GroupBalance balance = moneyModule.GetGroupBalance(groupID); client.SendGroupAccountingSummary(client, groupID, requestID, amt, balance.TotalTierDebit, balance.TotalTierCredits, Util.BuildYMDDateString(balance.StartingDate.AddDays(-currentInterval * intervalDays)), currentInterval, intervalDays, Util.BuildYMDDateString(balance.StartingDate.AddDays(intervalDays)), diff -Nur aurora-/Aurora/Modules/Avatar/Groups/GroupsModule.cs aurora/Aurora/Modules/Avatar/Groups/GroupsModule.cs --- aurora-/Aurora/Modules/Avatar/Groups/GroupsModule.cs 2012-11-09 23:17:43.000000000 +0900 +++ aurora/Aurora/Modules/Avatar/Groups/GroupsModule.cs 2012-11-11 15:14:42.000000000 +0900 @@ -237,7 +237,7 @@ try { // do the transaction, that is if the agent has got sufficient funds - if (!money.Charge(GetRequestingAgentID(remoteClient), money.GroupCreationCharge, "Group Creation")) + if (!money.AmountCovered(remoteClient.AgentId, money.GroupCreationCharge)) { remoteClient.SendCreateGroupReply(UUID.Zero, false, "You have got insuficient funds to create a group."); @@ -250,6 +250,7 @@ "A money related exception occured, please contact your grid administrator."); return UUID.Zero; } + money.ApplyCharge(remoteClient.AgentId, money.GroupCreationCharge, TransactionType.GroupCreate, "Group Creation"); } UUID groupID = m_groupData.CreateGroup(GetRequestingAgentID(remoteClient), name, charter, showInList, insigniaID, membershipFee, openEnrollment, allowPublish, @@ -2005,4 +2006,4 @@ #endregion } -} \ No newline at end of file +} diff -Nur aurora-/Aurora/Modules/World/Entities/BuySell/BuySellModule.cs aurora/Aurora/Modules/World/Entities/BuySell/BuySellModule.cs --- aurora-/Aurora/Modules/World/Entities/BuySell/BuySellModule.cs 2012-10-15 12:21:16.000000000 +0900 +++ aurora/Aurora/Modules/World/Entities/BuySell/BuySellModule.cs 2012-11-10 23:25:40.000000000 +0900 @@ -329,9 +329,7 @@ IMoneyModule moneyMod = remoteClient.Scene.RequestModuleInterface(); if (moneyMod != null) { - if ( - !moneyMod.Transfer(part.OwnerID, remoteClient.AgentId, part.ParentUUID, UUID.Zero, part.SalePrice, - "Object Purchase", TransactionType.ObjectBuy)) + if (!moneyMod.Transfer(remoteClient.AgentId, part.OwnerID, part.ParentUUID, part.SalePrice, TransactionType.PayObject, "Object Purchase")) { remoteClient.SendAgentAlertMessage("You do not have enough money to buy this object.", false); return; @@ -341,4 +339,4 @@ BuyObject(remoteClient, categoryID, localID, saleType, salePrice); } } -} \ No newline at end of file +} diff -Nur aurora-/Aurora/Modules/World/Land/ParcelManagementModule.cs aurora/Aurora/Modules/World/Land/ParcelManagementModule.cs --- aurora-/Aurora/Modules/World/Land/ParcelManagementModule.cs 2012-10-15 12:21:16.000000000 +0900 +++ aurora/Aurora/Modules/World/Land/ParcelManagementModule.cs 2012-11-10 23:23:13.000000000 +0900 @@ -1005,9 +1005,8 @@ IMoneyModule module = m_scene.RequestModuleInterface(); if (module != null) - if ( - !module.Transfer(landObject.LandData.OwnerID, client.AgentId, landObject.LandData.PassPrice, - "Parcel Pass")) + if (!module.Transfer(client.AgentId, landObject.LandData.OwnerID, ParcelLocalID, + landObject.LandData.PassPrice, TransactionType.LandPassSale, "Parcel Pass")) { client.SendAlertMessage("You do not have enough funds to complete this transaction."); return; @@ -1617,6 +1616,23 @@ { land.UpdateLandSold(args.agentId, args.groupId, args.groupOwned, (uint) args.transactionID, args.parcelPrice, args.parcelArea); + if (args.parcelOwnerID!=UUID.Zero) + { + bool ret = false; + if (args.transactionID==0) args.transactionID = (int)TransactionType.LandSale; + + IMoneyModule module = m_scene.RequestModuleInterface(); + if (module != null) + { + ret = module.Transfer(args.agentId, args.parcelOwnerID, args.parcelLocalID, + args.parcelPrice, (TransactionType)args.transactionID, "Parcel Sale"); + } + + if (ret || module==null || args.parcelPrice==0) + { + land.UpdateLandSold(args.agentId, args.groupId, args.groupOwned, (uint)args.transactionID, args.parcelPrice, args.parcelArea); + } + } } } } @@ -2447,4 +2463,4 @@ #endregion } -} \ No newline at end of file +} diff -Nur aurora-/Aurora/Modules/World/SampleCurrencyModule/SampleCurrencyModule.cs aurora/Aurora/Modules/World/SampleCurrencyModule/SampleCurrencyModule.cs --- aurora-/Aurora/Modules/World/SampleCurrencyModule/SampleCurrencyModule.cs 2012-10-15 12:21:16.000000000 +0900 +++ aurora/Aurora/Modules/World/SampleCurrencyModule/SampleCurrencyModule.cs 2012-11-11 15:44:22.000000000 +0900 @@ -71,30 +71,53 @@ #pragma warning disable 67 public event ObjectPaid OnObjectPaid; - public event PostObjectPaid OnPostObjectPaid; - public bool Transfer(UUID toID, UUID fromID, int amount, string description) + public bool Transfer(UUID fromID, UUID toID, int id, int amount, TransactionType type, string text) { return true; } - public bool Transfer(UUID toID, UUID fromID, int amount, string description, TransactionType type) + public bool Transfer(UUID fromID, UUID toID, UUID objectID, int amount, TransactionType type, string text) { return true; } - public bool Transfer(UUID toID, UUID fromID, UUID toObjectID, UUID fromObjectID, int amount, string description, - TransactionType type) + public int GetBalance(UUID agentID) + { + return 0; + } + + public bool UploadCovered(UUID agentID, int amount) + { + return true; + } + + public bool AmountCovered(UUID agnetID, int amount) { - if ((type == TransactionType.PayIntoObject) && (OnObjectPaid != null)) - OnObjectPaid((fromObjectID == UUID.Zero) ? toObjectID : fromObjectID, fromID, amount); return true; } - public void Transfer(UUID objectID, UUID agentID, int amount) + public void ApplyUploadCharge(UUID agentID, int amount, string text) + { + } + + public void ApplyCharge(UUID agentID, int amount, TransactionType type, string text) { } + public bool ObjectGiveMoney(UUID objectID, UUID fromID, UUID toID, int amount) + { + return true; + } + + public void ProcessMoneyTransferRequest(UUID source, UUID destination, int amount, + int transactiontype, string description) + { + } + + #endregion + + #pragma warning restore 67 #region IRegionModuleBase Members @@ -162,27 +185,6 @@ #endregion - public int Balance(UUID agentID) - { - return 0; - } - - public bool Charge(UUID agentID, int amount, string text) - { - return true; - } - - public bool ObjectGiveMoney(UUID objectID, UUID fromID, UUID toID, int amount) - { - return true; - } - - public void ProcessMoneyTransferRequest(UUID source, UUID destination, int amount, - int transactiontype, string description) - { - } - - #endregion /// /// New Client Event Handler @@ -334,11 +336,6 @@ 0, 0); } - public bool Charge(IClientAPI client, int amount) - { - return true; - } - #endregion public List GetTransactions(UUID groupID, UUID agentID, int currentInterval, int intervalDays) @@ -351,4 +348,4 @@ return new GroupBalance() { StartingDate = DateTime.Now.AddDays(-4) }; } } -} \ No newline at end of file +} diff -Nur aurora-/OpenSim/Services/CapsService/CAPModules/InventoryCAPS.cs aurora/OpenSim/Services/CapsService/CAPModules/InventoryCAPS.cs --- aurora-/OpenSim/Services/CapsService/CAPModules/InventoryCAPS.cs 2012-10-15 12:21:16.000000000 +0900 +++ aurora/OpenSim/Services/CapsService/CAPModules/InventoryCAPS.cs 2012-11-11 15:34:46.000000000 +0900 @@ -26,6 +26,7 @@ */ using System; +using System.Collections; using System.Collections.Generic; using System.IO; using System.Linq; @@ -291,6 +292,7 @@ if (!ChargeUser(asset_type, map)) { map = new OSDMap(); + map["description"] = "No Money"; map["uploader"] = ""; map["state"] = "error"; return OSDParser.SerializeLLSDXmlBytes(map); @@ -308,6 +310,7 @@ if (!ChargeUser(asset_type, map, out charge, out resourceCost)) { map = new OSDMap(); + map["description"] = "No Money"; map["uploader"] = ""; map["state"] = "error"; return OSDParser.SerializeLLSDXmlBytes(map); @@ -352,9 +355,14 @@ mesh_list * mm.UploadCharge; resourceCost = mesh_list * mm.UploadCharge; } - if (charge > 0 && - !mm.Charge(m_service.AgentID, mm.UploadCharge, "Upload Charge")) - return false; + //if (charge > 0 && + // !mm.Charge(m_service.AgentID, mm.UploadCharge, "Upload Charge")) + // return false; + + if (charge>0) + { + if (!RequestUploadCovered(m_service)) return false; + } } return true; } @@ -422,6 +430,7 @@ if (!ChargeUser(asset_type, map)) { map = new OSDMap(); + map["description"] = "No Money"; map["uploader"] = ""; map["state"] = "error"; return OSDParser.SerializeLLSDXmlString(map); @@ -687,9 +696,51 @@ m_inventoryService.AddItem(item); + RequestUploadCharge(m_service); + return assetID; } + + // + private bool RequestUploadCovered(IRegionClientCapsService service) + { + Hashtable paramTable = new Hashtable(); + ArrayList arrayParams = new ArrayList(); + OpenSim.Services.Interfaces.GridRegion region = service.Region; + AgentCircuitData circuitData = service.CircuitData; + + paramTable["clientUUID"] = service.AgentID.ToString(); + paramTable["clinetSessionID"] = circuitData.SessionID.ToString(); + paramTable["clientSecureSessionID"] = circuitData.SecureSessionID.ToString(); + arrayParams.Add(paramTable); + + Nwc.XmlRpc.XmlRpcRequest moneyModuleReq = new Nwc.XmlRpc.XmlRpcRequest("UploadCovered", arrayParams); + Nwc.XmlRpc.XmlRpcResponse moneyServResp = moneyModuleReq.Send(region.ServerURI, 6000); + + if (moneyServResp.IsFault) return false; + return true; + } + + + private void RequestUploadCharge(IRegionClientCapsService service) + { + + Hashtable paramTable = new Hashtable(); + ArrayList arrayParams = new ArrayList(); + OpenSim.Services.Interfaces.GridRegion region = service.Region; + AgentCircuitData circuitData = service.CircuitData; + + paramTable["clientUUID"] = service.AgentID.ToString(); + paramTable["clientSessionID"] = circuitData.SessionID.ToString(); + paramTable["clientSecureSessionID"] = circuitData.SecureSessionID.ToString(); + arrayParams.Add(paramTable); + + Nwc.XmlRpc.XmlRpcRequest moneyModuleReq = new Nwc.XmlRpc.XmlRpcRequest("UploadCharge", arrayParams); + moneyModuleReq.Send(region.ServerURI, 6000); + } + + public class AssetUploader { private readonly IRegionClientCapsService clientCaps; @@ -760,4 +811,4 @@ #endregion } -} \ No newline at end of file +}