public void AddRegion(Scene scene)
        {
            if (m_Enabled)
            {
                scene.RegisterModuleInterface <IGridService>(this);
                if (m_ThisGridInfo == null)
                {
                    m_ThisGridInfo = scene.SceneGridInfo;
                }

                GridRegion r = new GridRegion(scene.RegionInfo);
                m_RegionInfoCache.CacheLocal(r);

                scene.EventManager.OnRegionUp += OnRegionUp;
            }
        }
예제 #2
0
        public void AddRegion(Scene scene)
        {
            if (!m_Enabled)
                return;

            lock(m_scenes)
            {
                if(!m_scenes.Contains(scene))
                    m_scenes.Add(scene);
            }
            scene.RegisterModuleInterface<IGridService>(this);

            GridRegion r = new GridRegion(scene.RegionInfo);
            m_RegionInfoCache.CacheLocal(r);

            scene.EventManager.OnRegionUp += OnRegionUp;
        }