aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/ScriptEngine/Shared/Api
diff options
context:
space:
mode:
Diffstat (limited to 'OpenSim/Region/ScriptEngine/Shared/Api')
-rw-r--r--OpenSim/Region/ScriptEngine/Shared/Api/Implementation/OSSL_Api.cs24
1 files changed, 18 insertions, 6 deletions
diff --git a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/OSSL_Api.cs b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/OSSL_Api.cs
index 066f6a4..e769c6d 100644
--- a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/OSSL_Api.cs
+++ b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/OSSL_Api.cs
@@ -310,7 +310,7 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api
310 foreach (string id in ids) 310 foreach (string id in ids)
311 { 311 {
312 string current = id.Trim(); 312 string current = id.Trim();
313 if (current.ToUpper() == "PARCEL_GROUP_MEMBER" || current.ToUpper() == "PARCEL_OWNER" || current.ToUpper() == "ESTATE_MANAGER" || current.ToUpper() == "ESTATE_OWNER" || current.ToUpper() == "GOD" || current.ToUpper() == "GRID_GOD") 313 if (current.ToUpper() == "PARCEL_GROUP_MEMBER" || current.ToUpper() == "PARCEL_OWNER" || current.ToUpper() == "ESTATE_MANAGER" || current.ToUpper() == "ESTATE_OWNER" || current.ToUpper() == "ACTIVE_GOD" || current.ToUpper() == "GRID_GOD" || current.ToUpper() == "GOD")
314 { 314 {
315 if (!perms.AllowedOwnerClasses.Contains(current)) 315 if (!perms.AllowedOwnerClasses.Contains(current))
316 perms.AllowedOwnerClasses.Add(current.ToUpper()); 316 perms.AllowedOwnerClasses.Add(current.ToUpper());
@@ -415,24 +415,36 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api
415 } 415 }
416 } 416 }
417 417
418 //Only gods may use the function 418
419 //Only grid gods may use the function
420 if (m_FunctionPerms[function].AllowedOwnerClasses.Contains("GRID_GOD"))
421 {
422 if (World.Permissions.IsGridGod(ownerID))
423 {
424 return String.Empty;
425 }
426 }
427
428 //Any god may use the function
419 if (m_FunctionPerms[function].AllowedOwnerClasses.Contains("GOD")) 429 if (m_FunctionPerms[function].AllowedOwnerClasses.Contains("GOD"))
420 { 430 {
421 if (World.Permissions.IsGod(ownerID)) 431 if (World.Permissions.IsAdministrator(ownerID))
422 { 432 {
423 return String.Empty; 433 return String.Empty;
424 } 434 }
425 } 435 }
426 436
427 //Only grid gods may use the function 437 //Only active gods may use the function
428 if (m_FunctionPerms[function].AllowedOwnerClasses.Contains("GRID_GOD")) 438 if (m_FunctionPerms[function].AllowedOwnerClasses.Contains("ACTIVE_GOD"))
429 { 439 {
430 if (World.Permissions.IsGridGod(ownerID)) 440 ScenePresence sp = World.GetScenePresence(ownerID);
441 if (sp != null && !sp.IsDeleted && sp.IsGod)
431 { 442 {
432 return String.Empty; 443 return String.Empty;
433 } 444 }
434 } 445 }
435 446
447
436 if (!m_FunctionPerms[function].AllowedCreators.Contains(m_item.CreatorID)) 448 if (!m_FunctionPerms[function].AllowedCreators.Contains(m_item.CreatorID))
437 return( 449 return(
438 String.Format("{0} permission denied. Script creator is not in the list of users allowed to execute this function and prim owner also has no permission.", 450 String.Format("{0} permission denied. Script creator is not in the list of users allowed to execute this function and prim owner also has no permission.",