예제 #1
0
        public static bool IsWeatherBoosted(this PokedexPokemon pkmn, GameplayWeather.Types.WeatherCondition weather)
        {
            var types     = pkmn?.Types;
            var isBoosted = types?.Exists(x => Strings.WeatherBoosts[weather].Contains(x)) ?? false;

            return(isBoosted);
        }
예제 #2
0
        public static string GetWeatherEmojiIcon(this GameplayWeather.Types.WeatherCondition weather)
        {
            var key       = $"weather_{Convert.ToInt32(weather)}";
            var emojiId   = MasterFile.Instance.Emojis[key];
            var emojiName = emojiId > 0 ? string.Format(Strings.EmojiSchema, key, emojiId) : weather.ToString();

            return(emojiName);
        }
예제 #3
0
 public void SetWeather(long id, GameplayWeather.Types.WeatherCondition type)
 {
     _weather[id] = type;
 }
예제 #4
0
 public string GetWeatherIcon(string style, GameplayWeather.Types.WeatherCondition weatherType)
 {
     return(_iconStyles[style] + "weather/" + (int)weatherType + ".png");
 }
예제 #5
0
 public string GetWeather(GameplayWeather.Types.WeatherCondition weather)
 {
     return(Translate($"weather_{(int)weather}"));
 }