diff options
author | Melanie Thielker | 2008-08-15 13:13:39 +0000 |
---|---|---|
committer | Melanie Thielker | 2008-08-15 13:13:39 +0000 |
commit | dfc553d0a4c25d6c1f491b228e89402c0415acda (patch) | |
tree | 63653f47cc17365ec828f2e5507b7fd75c0388be /OpenSim/Region/Environment/Scenes | |
parent | Minor formatting cleanup. (diff) | |
download | opensim-SC_OLD-dfc553d0a4c25d6c1f491b228e89402c0415acda.zip opensim-SC_OLD-dfc553d0a4c25d6c1f491b228e89402c0415acda.tar.gz opensim-SC_OLD-dfc553d0a4c25d6c1f491b228e89402c0415acda.tar.bz2 opensim-SC_OLD-dfc553d0a4c25d6c1f491b228e89402c0415acda.tar.xz |
Fix up master avatar handling for estate owners. Introduces a new
hierarchical rights structure. MasterAvatar: Owner of the region server
(may be null), net gods (users with GodLevel 200), Estate owner
(from database). Look at Opensim.ini.example to enable net gods.
Estate owner will default to master avatar.
Diffstat (limited to 'OpenSim/Region/Environment/Scenes')
-rw-r--r-- | OpenSim/Region/Environment/Scenes/Scene.Inventory.cs | 2 | ||||
-rw-r--r-- | OpenSim/Region/Environment/Scenes/Scene.cs | 17 | ||||
-rw-r--r-- | OpenSim/Region/Environment/Scenes/ScenePresence.cs | 10 |
3 files changed, 28 insertions, 1 deletions
diff --git a/OpenSim/Region/Environment/Scenes/Scene.Inventory.cs b/OpenSim/Region/Environment/Scenes/Scene.Inventory.cs index ca77f2b..3f62610 100644 --- a/OpenSim/Region/Environment/Scenes/Scene.Inventory.cs +++ b/OpenSim/Region/Environment/Scenes/Scene.Inventory.cs | |||
@@ -116,6 +116,8 @@ namespace OpenSim.Region.Environment.Scenes | |||
116 | { | 116 | { |
117 | userlevel = 1; | 117 | userlevel = 1; |
118 | } | 118 | } |
119 | // TODO: remove this cruft once MasterAvatar is fully deprecated | ||
120 | // | ||
119 | if (m_regInfo.MasterAvatarAssignedUUID == AgentID) | 121 | if (m_regInfo.MasterAvatarAssignedUUID == AgentID) |
120 | { | 122 | { |
121 | userlevel = 2; | 123 | userlevel = 2; |
diff --git a/OpenSim/Region/Environment/Scenes/Scene.cs b/OpenSim/Region/Environment/Scenes/Scene.cs index 22251e9..00d8298 100644 --- a/OpenSim/Region/Environment/Scenes/Scene.cs +++ b/OpenSim/Region/Environment/Scenes/Scene.cs | |||
@@ -3777,5 +3777,22 @@ namespace OpenSim.Region.Environment.Scenes | |||
3777 | //Console.WriteLine("Terrain packet unacked, resending patch: " + patchX + " , " + patchY); | 3777 | //Console.WriteLine("Terrain packet unacked, resending patch: " + patchX + " , " + patchY); |
3778 | client.SendLayerData(patchX, patchY, Heightmap.GetFloatsSerialised()); | 3778 | client.SendLayerData(patchX, patchY, Heightmap.GetFloatsSerialised()); |
3779 | } | 3779 | } |
3780 | |||
3781 | // public bool IsAdministrator(LLUUID user) | ||
3782 | // { | ||
3783 | // if(RegionInfo.MasterAvatarAssignedUUID != LLUUID.Zero) | ||
3784 | // { | ||
3785 | // if(RegionInfo.MasterAvatarAssignedUUID == user) | ||
3786 | // return true; | ||
3787 | // } | ||
3788 | // | ||
3789 | // UserProfileData userProfile = | ||
3790 | // CommsManager.UserService.GetUserProfile(user); | ||
3791 | // | ||
3792 | // if(userProfile.GodLevel >= 200) | ||
3793 | // return true; | ||
3794 | // | ||
3795 | // return false; | ||
3796 | // } | ||
3780 | } | 3797 | } |
3781 | } | 3798 | } |
diff --git a/OpenSim/Region/Environment/Scenes/ScenePresence.cs b/OpenSim/Region/Environment/Scenes/ScenePresence.cs index d8d534e..b4cf70a 100644 --- a/OpenSim/Region/Environment/Scenes/ScenePresence.cs +++ b/OpenSim/Region/Environment/Scenes/ScenePresence.cs | |||
@@ -2017,7 +2017,15 @@ namespace OpenSim.Region.Environment.Scenes | |||
2017 | { | 2017 | { |
2018 | if (godStatus) | 2018 | if (godStatus) |
2019 | { | 2019 | { |
2020 | m_godlevel = 250; | 2020 | // TODO: remove this cruft once the master avatar is fully |
2021 | // deprecated. For now, assign god level 200 to anyone | ||
2022 | // who is granted god powers, but has no god level set. | ||
2023 | // | ||
2024 | UserProfileData userProfile = m_scene.CommsManager.UserService.GetUserProfile(agentID); | ||
2025 | if(userProfile.GodLevel > 0) | ||
2026 | m_godlevel = userProfile.GodLevel; | ||
2027 | else | ||
2028 | m_godlevel = 200; | ||
2021 | } | 2029 | } |
2022 | else | 2030 | else |
2023 | { | 2031 | { |