aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/Environment/Scenes/Scene.cs
diff options
context:
space:
mode:
Diffstat (limited to 'OpenSim/Region/Environment/Scenes/Scene.cs')
-rw-r--r--OpenSim/Region/Environment/Scenes/Scene.cs34
1 files changed, 17 insertions, 17 deletions
diff --git a/OpenSim/Region/Environment/Scenes/Scene.cs b/OpenSim/Region/Environment/Scenes/Scene.cs
index f861361..a703622 100644
--- a/OpenSim/Region/Environment/Scenes/Scene.cs
+++ b/OpenSim/Region/Environment/Scenes/Scene.cs
@@ -114,6 +114,7 @@ namespace OpenSim.Region.Environment.Scenes
114 protected IXMLRPC m_xmlrpcModule; 114 protected IXMLRPC m_xmlrpcModule;
115 protected IWorldComm m_worldCommModule; 115 protected IWorldComm m_worldCommModule;
116 protected IAvatarFactory m_AvatarFactory; 116 protected IAvatarFactory m_AvatarFactory;
117 protected IScenePermissions m_permissions;
117 118
118 // Central Update Loop 119 // Central Update Loop
119 120
@@ -169,13 +170,12 @@ namespace OpenSim.Region.Environment.Scenes
169 get { return m_timedilation; } 170 get { return m_timedilation; }
170 } 171 }
171 172
172 protected readonly PermissionManager m_permissionManager; 173 /// <summary>
173 // This is the instance to the permissions manager. 174 /// The reference by which general permissions in the scene can be set and queried.
174 // This manages permissions to clients on in world objects 175 /// </summary>
175 176 public IScenePermissions Permissions
176 public PermissionManager PermissionsMngr
177 { 177 {
178 get { return m_permissionManager; } 178 get { return m_permissions; }
179 } 179 }
180 180
181 public int TimePhase 181 public int TimePhase
@@ -219,7 +219,7 @@ namespace OpenSim.Region.Environment.Scenes
219 219
220 #region Constructors 220 #region Constructors
221 221
222 public Scene(RegionInfo regInfo, AgentCircuitManager authen, PermissionManager permissionManager, 222 public Scene(RegionInfo regInfo, AgentCircuitManager authen,
223 CommunicationsManager commsMan, SceneCommunicationService sceneGridService, 223 CommunicationsManager commsMan, SceneCommunicationService sceneGridService,
224 AssetCache assetCach, StorageManager storeManager, BaseHttpServer httpServer, 224 AssetCache assetCach, StorageManager storeManager, BaseHttpServer httpServer,
225 ModuleLoader moduleLoader, bool dumpAssetsToFile, bool physicalPrim, bool SeeIntoRegionFromNeighbor) 225 ModuleLoader moduleLoader, bool dumpAssetsToFile, bool physicalPrim, bool SeeIntoRegionFromNeighbor)
@@ -248,10 +248,7 @@ namespace OpenSim.Region.Environment.Scenes
248 EventManager.OnLandObjectRemoved += 248 EventManager.OnLandObjectRemoved +=
249 new EventManager.LandObjectRemoved(m_storageManager.DataStore.RemoveLandObject); 249 new EventManager.LandObjectRemoved(m_storageManager.DataStore.RemoveLandObject);
250 250
251 m_permissionManager = permissionManager; 251 m_innerScene = new InnerScene(this, m_regInfo);
252 m_permissionManager.Initialise(this);
253
254 m_innerScene = new InnerScene(this, m_regInfo, m_permissionManager);
255 252
256 // If the Inner scene has an Unrecoverable error, restart this sim. 253 // If the Inner scene has an Unrecoverable error, restart this sim.
257 // Currently the only thing that causes it to happen is two kinds of specific 254 // Currently the only thing that causes it to happen is two kinds of specific
@@ -613,6 +610,9 @@ namespace OpenSim.Region.Environment.Scenes
613 m_heartbeatTimer.Elapsed += new ElapsedEventHandler(Heartbeat); 610 m_heartbeatTimer.Elapsed += new ElapsedEventHandler(Heartbeat);
614 } 611 }
615 612
613 /// <summary>
614 /// Sets up references to loaded modules required by thie scene
615 /// </summary>
616 public void SetModuleInterfaces() 616 public void SetModuleInterfaces()
617 { 617 {
618 m_simChatModule = RequestModuleInterface<ISimChat>(); 618 m_simChatModule = RequestModuleInterface<ISimChat>();
@@ -621,6 +621,7 @@ namespace OpenSim.Region.Environment.Scenes
621 m_worldCommModule = RequestModuleInterface<IWorldComm>(); 621 m_worldCommModule = RequestModuleInterface<IWorldComm>();
622 XferManager = RequestModuleInterface<IXfer>(); 622 XferManager = RequestModuleInterface<IXfer>();
623 m_AvatarFactory = RequestModuleInterface<IAvatarFactory>(); 623 m_AvatarFactory = RequestModuleInterface<IAvatarFactory>();
624 m_permissions = RequestModuleInterface<IScenePermissions>();
624 } 625 }
625 626
626 #endregion 627 #endregion
@@ -1121,7 +1122,7 @@ namespace OpenSim.Region.Environment.Scenes
1121 /// <summary> 1122 /// <summary>
1122 /// Loads the World's objects 1123 /// Loads the World's objects
1123 /// </summary> 1124 /// </summary>
1124 public virtual void LoadPrimsFromStorage(bool m_permissions, LLUUID regionID) 1125 public virtual void LoadPrimsFromStorage(LLUUID regionID)
1125 { 1126 {
1126 m_log.Info("[SCENE]: Loading objects from datastore"); 1127 m_log.Info("[SCENE]: Loading objects from datastore");
1127 1128
@@ -1243,12 +1244,11 @@ namespace OpenSim.Region.Environment.Scenes
1243 1244
1244 LLVector3 pos = GetNewRezLocation(RayStart, RayEnd, RayTargetID, rot, bypassRaycast, RayEndIsIntersection, true, new LLVector3(0.5f,0.5f,0.5f), false); 1245 LLVector3 pos = GetNewRezLocation(RayStart, RayEnd, RayTargetID, rot, bypassRaycast, RayEndIsIntersection, true, new LLVector3(0.5f,0.5f,0.5f), false);
1245 1246
1246 if (PermissionsMngr.CanRezObject(ownerID, pos)) 1247 if (Permissions.CanRezObject(ownerID, pos))
1247 { 1248 {
1248 // rez ON the ground, not IN the ground 1249 // rez ON the ground, not IN the ground
1249 pos.Z += 0.25F; 1250 pos.Z += 0.25F;
1250 1251
1251
1252 AddNewPrim(ownerID, pos, rot, shape); 1252 AddNewPrim(ownerID, pos, rot, shape);
1253 } 1253 }
1254 } 1254 }
@@ -2499,7 +2499,7 @@ namespace OpenSim.Region.Environment.Scenes
2499 IClientAPI controllingClient) 2499 IClientAPI controllingClient)
2500 { 2500 {
2501 // First check that this is the sim owner 2501 // First check that this is the sim owner
2502 if (m_permissionManager.GenericEstatePermission(agentID)) 2502 if (Permissions.GenericEstatePermission(agentID))
2503 { 2503 {
2504 // User needs to be logged into this sim 2504 // User needs to be logged into this sim
2505 if (m_scenePresences.ContainsKey(agentID)) 2505 if (m_scenePresences.ContainsKey(agentID))
@@ -2577,7 +2577,7 @@ namespace OpenSim.Region.Environment.Scenes
2577 LLUUID kickUserID = new LLUUID("44e87126e7944ded05b37c42da3d5cdb"); 2577 LLUUID kickUserID = new LLUUID("44e87126e7944ded05b37c42da3d5cdb");
2578 if (m_scenePresences.ContainsKey(agentID) || agentID == kickUserID) 2578 if (m_scenePresences.ContainsKey(agentID) || agentID == kickUserID)
2579 { 2579 {
2580 if (m_permissionManager.GenericEstatePermission(godID)) 2580 if (Permissions.GenericEstatePermission(godID))
2581 { 2581 {
2582 if (agentID == kickUserID) 2582 if (agentID == kickUserID)
2583 { 2583 {
@@ -2896,7 +2896,7 @@ namespace OpenSim.Region.Environment.Scenes
2896 } 2896 }
2897 else if ((parcel.landData.landFlags & (uint)Parcel.ParcelFlags.AllowGroupScripts) != 0) 2897 else if ((parcel.landData.landFlags & (uint)Parcel.ParcelFlags.AllowGroupScripts) != 0)
2898 { 2898 {
2899 if (part.OwnerID == parcel.landData.ownerID || (parcel.landData.isGroupOwned && part.GroupID == parcel.landData.groupID) || PermissionsMngr.GenericEstatePermission(part.OwnerID)) 2899 if (part.OwnerID == parcel.landData.ownerID || (parcel.landData.isGroupOwned && part.GroupID == parcel.landData.groupID) || Permissions.GenericEstatePermission(part.OwnerID))
2900 { 2900 {
2901 return true; 2901 return true;
2902 } 2902 }