Aurora.Modules.CityBuilder.CityModule.cmdSetParameter C# (CSharp) Метод

cmdSetParameter() публичный Метод

This method decodes the 'city set' console command.
public cmdSetParameter ( string module, string cmdParams ) : void
module string
cmdParams string
Результат void
        public void cmdSetParameter(string module, string[] cmdParams)
        {
            string param = string.Empty;
            string value = string.Empty;

            if (cmdParams.Length != 4)
            {
                m_log.InfoFormat("Invalid number of parameters supplied ({0})", cmdParams.Length);
                m_log.Info("city set <parameter> <value>");
                return;
            }

            param = cmdParams[2];
            value = cmdParams[3];

            m_log.InfoFormat("Attempting to set parameter {0} to {1}", param, value);

            /*
             *      Settable parameters for the City Builder plugin.
             *
             *  Property Name       Type        Default
             *
             *      Name            string      DEBUG: "Cobra ElDiablo", RELEASE: as per config file.
             *      Owner
             *      regioncount
             *      regionsize
             *      estate
             *      densities
             *
             */
            if (param == "Name")
            {
                m_log.InfoFormat("City name changed from {0}, to {1}", cityName, value);
                cityName = value;
                return;
            }
        }