diff options
Diffstat (limited to 'OpenSim/Region/ScriptEngine/Shared/Api')
-rw-r--r-- | OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs | 18 | ||||
-rw-r--r-- | OpenSim/Region/ScriptEngine/Shared/Api/Implementation/OSSL_Api.cs | 2 |
2 files changed, 11 insertions, 9 deletions
diff --git a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs index 5ea14c7..3f0af6d 100644 --- a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs +++ b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs | |||
@@ -3109,8 +3109,9 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
3109 | return; | 3109 | return; |
3110 | } | 3110 | } |
3111 | 3111 | ||
3112 | string reason; | ||
3112 | money.ObjectGiveMoney( | 3113 | money.ObjectGiveMoney( |
3113 | m_host.ParentGroup.RootPart.UUID, m_host.ParentGroup.RootPart.OwnerID, toID, amount,UUID.Zero); | 3114 | m_host.ParentGroup.RootPart.UUID, m_host.ParentGroup.RootPart.OwnerID, toID, amount,UUID.Zero, out reason); |
3114 | }); | 3115 | }); |
3115 | 3116 | ||
3116 | return 0; | 3117 | return 0; |
@@ -7105,7 +7106,7 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
7105 | UUID key; | 7106 | UUID key; |
7106 | ILandObject land = World.LandChannel.GetLandObject(m_host.AbsolutePosition); | 7107 | ILandObject land = World.LandChannel.GetLandObject(m_host.AbsolutePosition); |
7107 | 7108 | ||
7108 | if (World.Permissions.CanEditParcelProperties(m_host.OwnerID, land, GroupPowers.LandManageBanned)) | 7109 | if (World.Permissions.CanEditParcelProperties(m_host.OwnerID, land, GroupPowers.LandManageBanned, false)) |
7109 | { | 7110 | { |
7110 | int expires = 0; | 7111 | int expires = 0; |
7111 | if (hours != 0) | 7112 | if (hours != 0) |
@@ -10430,7 +10431,7 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
10430 | // according to the docs, this command only works if script owner and land owner are the same | 10431 | // according to the docs, this command only works if script owner and land owner are the same |
10431 | // lets add estate owners and gods, too, and use the generic permission check. | 10432 | // lets add estate owners and gods, too, and use the generic permission check. |
10432 | ILandObject landObject = World.LandChannel.GetLandObject(m_host.AbsolutePosition); | 10433 | ILandObject landObject = World.LandChannel.GetLandObject(m_host.AbsolutePosition); |
10433 | if (!World.Permissions.CanEditParcelProperties(m_host.OwnerID, landObject, GroupPowers.ChangeMedia)) return; | 10434 | if (!World.Permissions.CanEditParcelProperties(m_host.OwnerID, landObject, GroupPowers.ChangeMedia, false)) return; |
10434 | 10435 | ||
10435 | bool update = false; // send a ParcelMediaUpdate (and possibly change the land's media URL)? | 10436 | bool update = false; // send a ParcelMediaUpdate (and possibly change the land's media URL)? |
10436 | byte loop = 0; | 10437 | byte loop = 0; |
@@ -10873,7 +10874,7 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
10873 | m_host.AddScriptLPS(1); | 10874 | m_host.AddScriptLPS(1); |
10874 | UUID key; | 10875 | UUID key; |
10875 | ILandObject land = World.LandChannel.GetLandObject(m_host.AbsolutePosition); | 10876 | ILandObject land = World.LandChannel.GetLandObject(m_host.AbsolutePosition); |
10876 | if (World.Permissions.CanEditParcelProperties(m_host.OwnerID, land, GroupPowers.LandManageBanned)) | 10877 | if (World.Permissions.CanEditParcelProperties(m_host.OwnerID, land, GroupPowers.LandManageBanned, false)) |
10877 | { | 10878 | { |
10878 | int expires = 0; | 10879 | int expires = 0; |
10879 | if (hours != 0) | 10880 | if (hours != 0) |
@@ -10914,7 +10915,7 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
10914 | m_host.AddScriptLPS(1); | 10915 | m_host.AddScriptLPS(1); |
10915 | UUID key; | 10916 | UUID key; |
10916 | ILandObject land = World.LandChannel.GetLandObject(m_host.AbsolutePosition); | 10917 | ILandObject land = World.LandChannel.GetLandObject(m_host.AbsolutePosition); |
10917 | if (World.Permissions.CanEditParcelProperties(m_host.OwnerID, land, GroupPowers.LandManageAllowed)) | 10918 | if (World.Permissions.CanEditParcelProperties(m_host.OwnerID, land, GroupPowers.LandManageAllowed, false)) |
10918 | { | 10919 | { |
10919 | if (UUID.TryParse(avatar, out key)) | 10920 | if (UUID.TryParse(avatar, out key)) |
10920 | { | 10921 | { |
@@ -10941,7 +10942,7 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
10941 | m_host.AddScriptLPS(1); | 10942 | m_host.AddScriptLPS(1); |
10942 | UUID key; | 10943 | UUID key; |
10943 | ILandObject land = World.LandChannel.GetLandObject(m_host.AbsolutePosition); | 10944 | ILandObject land = World.LandChannel.GetLandObject(m_host.AbsolutePosition); |
10944 | if (World.Permissions.CanEditParcelProperties(m_host.OwnerID, land, GroupPowers.LandManageBanned)) | 10945 | if (World.Permissions.CanEditParcelProperties(m_host.OwnerID, land, GroupPowers.LandManageBanned, false)) |
10945 | { | 10946 | { |
10946 | if (UUID.TryParse(avatar, out key)) | 10947 | if (UUID.TryParse(avatar, out key)) |
10947 | { | 10948 | { |
@@ -12784,8 +12785,9 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
12784 | return; | 12785 | return; |
12785 | } | 12786 | } |
12786 | 12787 | ||
12788 | string reason; | ||
12787 | bool result = money.ObjectGiveMoney( | 12789 | bool result = money.ObjectGiveMoney( |
12788 | m_host.ParentGroup.RootPart.UUID, m_host.ParentGroup.RootPart.OwnerID, toID, amount, txn); | 12790 | m_host.ParentGroup.RootPart.UUID, m_host.ParentGroup.RootPart.OwnerID, toID, amount, txn, out reason); |
12789 | 12791 | ||
12790 | if (result) | 12792 | if (result) |
12791 | { | 12793 | { |
@@ -12793,7 +12795,7 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
12793 | return; | 12795 | return; |
12794 | } | 12796 | } |
12795 | 12797 | ||
12796 | replydata = "LINDENDOLLAR_INSUFFICIENTFUNDS"; | 12798 | replydata = reason; |
12797 | } | 12799 | } |
12798 | finally | 12800 | finally |
12799 | { | 12801 | { |
diff --git a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/OSSL_Api.cs b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/OSSL_Api.cs index f4e4f44..9c148d1 100644 --- a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/OSSL_Api.cs +++ b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/OSSL_Api.cs | |||
@@ -1434,7 +1434,7 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
1434 | return; | 1434 | return; |
1435 | } | 1435 | } |
1436 | 1436 | ||
1437 | if (!World.Permissions.CanEditParcelProperties(m_host.OwnerID, startLandObject, GroupPowers.LandOptions)) | 1437 | if (!World.Permissions.CanEditParcelProperties(m_host.OwnerID, startLandObject, GroupPowers.LandOptions, false)) |
1438 | { | 1438 | { |
1439 | OSSLShoutError("You do not have permission to modify the parcel"); | 1439 | OSSLShoutError("You do not have permission to modify the parcel"); |
1440 | return; | 1440 | return; |