FromOSD() public method

public FromOSD ( OSDMap map ) : void
map OSDMap
return void
Ejemplo n.º 1
0
        public void UnpackRegionInfoData(OSDMap args)
        {
            if (args.ContainsKey("region_id"))
                RegionID = args["region_id"].AsUUID();
            if (args.ContainsKey("region_name"))
                RegionName = args["region_name"].AsString();
            if (args.ContainsKey("http_port"))
                UInt32.TryParse(args["http_port"].AsString(), out m_httpPort);
            if (args.ContainsKey("region_xloc"))
            {
                int locx;
                Int32.TryParse(args["region_xloc"].AsString(), out locx);
                RegionLocX = locx;
            }
            if (args.ContainsKey("region_yloc"))
            {
                int locy;
                Int32.TryParse(args["region_yloc"].AsString(), out locy);
                RegionLocY = locy;
            }
            if (args.ContainsKey("region_type"))
                m_regionType = args["region_type"].AsString();

            if (args.ContainsKey("scope_id"))
                ScopeID = args["scope_id"].AsUUID();
            if (args.ContainsKey("all_scope_ids"))
                AllScopeIDs = ((OSDArray) args["all_scope_ids"]).ConvertAll<UUID>(o => o);

            if (args.ContainsKey("region_size_x"))
                RegionSizeX = args["region_size_x"].AsInteger();
            if (args.ContainsKey("region_size_y"))
                RegionSizeY = args["region_size_y"].AsInteger();
            if (args.ContainsKey("region_size_z"))
                RegionSizeZ = args["region_size_z"].AsInteger();

            if (args.ContainsKey("object_capacity"))
                m_objectCapacity = args["object_capacity"].AsInteger();
            if (args.ContainsKey("region_type"))
                RegionType = args["region_type"].AsString();
            if (args.ContainsKey("see_into_this_sim_from_neighbor"))
                SeeIntoThisSimFromNeighbor = args["see_into_this_sim_from_neighbor"].AsBoolean();
            if (args.ContainsKey("startupType"))
                Startup = (StartupType) args["startupType"].AsInteger();
            if (args.ContainsKey("InfiniteRegion"))
                InfiniteRegion = args["InfiniteRegion"].AsBoolean();
            if (args.ContainsKey("RegionSettings"))
            {
                RegionSettings = new RegionSettings();
                RegionSettings.FromOSD((OSDMap) args["RegionSettings"]);
            }
            if (args.ContainsKey("GridSecureSessionID"))
                GridSecureSessionID = args["GridSecureSessionID"];
            if (args.ContainsKey("OpenRegionSettings"))
            {
                OpenRegionSettings = new OpenRegionSettings();
                OpenRegionSettings.FromOSD((OSDMap) args["OpenRegionSettings"]);
            }
            else
                OpenRegionSettings = new OpenRegionSettings();
            if (args.ContainsKey("EnvironmentSettings"))
                EnvironmentSettings = args["EnvironmentSettings"];
            if (args.ContainsKey("region_terrain"))
                m_regionTerrain = args["region_terrain"].AsString();
            if (args.ContainsKey("region_area"))
                RegionArea = (uint) args["region_area"].AsInteger();
        }
Ejemplo n.º 2
0
        public void UnpackRegionInfoData(OSDMap args)
        {
            if (args.ContainsKey("region_id"))
            {
                RegionID = args["region_id"].AsUUID();
            }
            if (args.ContainsKey("region_name"))
            {
                RegionName = args["region_name"].AsString();
            }
            if (args.ContainsKey("http_port"))
            {
                uint.TryParse(args["http_port"].AsString(), out m_httpPort);
            }
            if (args.ContainsKey("region_xloc"))
            {
                int locx;
                int.TryParse(args["region_xloc"].AsString(), out locx);
                RegionLocX = locx;
            }
            if (args.ContainsKey("region_yloc"))
            {
                int locy;
                int.TryParse(args["region_yloc"].AsString(), out locy);
                RegionLocY = locy;
            }
            if (args.ContainsKey("region_type"))
            {
                m_regionType = args["region_type"].AsString();
            }

            if (args.ContainsKey("scope_id"))
            {
                ScopeID = args["scope_id"].AsUUID();
            }
            if (args.ContainsKey("all_scope_ids"))
            {
                AllScopeIDs = ((OSDArray)args["all_scope_ids"]).ConvertAll <UUID>(o => o);
            }

            if (args.ContainsKey("region_size_x"))
            {
                RegionSizeX = args["region_size_x"].AsInteger();
            }
            if (args.ContainsKey("region_size_y"))
            {
                RegionSizeY = args["region_size_y"].AsInteger();
            }
            if (args.ContainsKey("region_size_z"))
            {
                RegionSizeZ = args["region_size_z"].AsInteger();
            }

            if (args.ContainsKey("object_capacity"))
            {
                m_objectCapacity = args["object_capacity"].AsInteger();
            }
            if (args.ContainsKey("region_type"))
            {
                RegionType = args["region_type"].AsString();
            }
            if (args.ContainsKey("see_into_this_sim_from_neighbor"))
            {
                SeeIntoThisSimFromNeighbor = args["see_into_this_sim_from_neighbor"].AsBoolean();
            }
            if (args.ContainsKey("startupType"))
            {
                Startup = (StartupType)args["startupType"].AsInteger();
            }
            if (args.ContainsKey("InfiniteRegion"))
            {
                InfiniteRegion = args["InfiniteRegion"].AsBoolean();
            }
            if (args.ContainsKey("RegionSettings"))
            {
                RegionSettings = new RegionSettings();
                RegionSettings.FromOSD((OSDMap)args["RegionSettings"]);
            }
            if (args.ContainsKey("GridSecureSessionID"))
            {
                GridSecureSessionID = args["GridSecureSessionID"];
            }
            if (args.ContainsKey("OpenRegionSettings"))
            {
                OpenRegionSettings = new OpenRegionSettings();
                OpenRegionSettings.FromOSD((OSDMap)args["OpenRegionSettings"]);
            }
            else
            {
                OpenRegionSettings = new OpenRegionSettings();
            }
            if (args.ContainsKey("EnvironmentSettings"))
            {
                EnvironmentSettings = args["EnvironmentSettings"];
            }
            if (args.ContainsKey("region_terrain"))
            {
                m_regionTerrain = args["region_terrain"].AsString();
            }
            if (args.ContainsKey("region_area"))
            {
                RegionArea = (uint)args["region_area"].AsInteger();
            }
        }