示例#1
0
        public override void Use(Player p, string message)
        {
            if (!p.cpe || !p.extensions.Contains(Extension.EnvWeatherType))
            {
                Help(p); return;
            }
            message = message.Trim().ToLower();
            switch (message)
            {
            case "sun":
                p.SendWeather(Weather.SUNNY);
                Player.SendMessage(p, "The sun came out!");
                break;

            case "rain":
                p.SendWeather(Weather.RAINING);
                Player.SendMessage(p, "It started to rain!");
                break;

            case "snow":
                p.SendWeather(Weather.SNOWING);
                Player.SendMessage(p, "It started to snow!");
                break;

            default:
                Help(p);
                return;
            }
        }