private void OnTriggerEnter2D(Collider2D other) { if (other.CompareTag("MainCharacter")) { if (weatherType.Equals(WeatherType.Day)) { weatherSystem.DayOrNight(); } else if (weatherType.Equals(WeatherType.Night)) { weatherSystem.DayOrNight(); } else if (weatherType.Equals(WeatherType.Rain)) { weatherSystem.Rain(); } else if (weatherType.Equals(WeatherType.Sunny)) { weatherSystem.Sunny(); } else if (weatherType.Equals(WeatherType.Leaves)) { weatherSystem.Leaves(); } else if (weatherType.Equals(WeatherType.DayNightCycle)) { weatherSystem.DayNightCycle(); } else if (weatherType.Equals(WeatherType.FullWeather)) { weatherSystem.FullWeather(); } } }