diff options
Diffstat (limited to 'OpenSim/Region/ScriptEngine/Shared/Api/Implementation/OSSL_Api.cs')
-rw-r--r-- | OpenSim/Region/ScriptEngine/Shared/Api/Implementation/OSSL_Api.cs | 15 |
1 files changed, 9 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..07549f8 100644 --- a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/OSSL_Api.cs +++ b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/OSSL_Api.cs | |||
@@ -415,24 +415,27 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
415 | } | 415 | } |
416 | } | 416 | } |
417 | 417 | ||
418 | //Only gods may use the function | 418 | |
419 | if (m_FunctionPerms[function].AllowedOwnerClasses.Contains("GOD")) | 419 | //Only grid gods may use the function |
420 | if (m_FunctionPerms[function].AllowedOwnerClasses.Contains("GRID_GOD")) | ||
420 | { | 421 | { |
421 | if (World.Permissions.IsGod(ownerID)) | 422 | if (World.Permissions.IsGridGod(ownerID)) |
422 | { | 423 | { |
423 | return String.Empty; | 424 | return String.Empty; |
424 | } | 425 | } |
425 | } | 426 | } |
426 | 427 | ||
427 | //Only grid gods may use the function | 428 | //Only active gods may use the function |
428 | if (m_FunctionPerms[function].AllowedOwnerClasses.Contains("GRID_GOD")) | 429 | if (m_FunctionPerms[function].AllowedOwnerClasses.Contains("GOD")) |
429 | { | 430 | { |
430 | if (World.Permissions.IsGridGod(ownerID)) | 431 | ScenePresence sp = World.GetScenePresence(ownerID); |
432 | if (sp != null && !sp.IsDeleted && sp.IsGod) | ||
431 | { | 433 | { |
432 | return String.Empty; | 434 | return String.Empty; |
433 | } | 435 | } |
434 | } | 436 | } |
435 | 437 | ||
438 | |||
436 | if (!m_FunctionPerms[function].AllowedCreators.Contains(m_item.CreatorID)) | 439 | if (!m_FunctionPerms[function].AllowedCreators.Contains(m_item.CreatorID)) |
437 | return( | 440 | 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.", | 441 | 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.", |