π¦οΈWeather Module
Last updated
Was this helpful?
Last updated
Was this helpful?
Was this helpful?
Harness the power of the weather with the Weather Module. Determine what Weather Profiles can be played using a Forecast Profile and watch as COZY automatically propagates that information to the rest of the weather sphere.
Use data from the Climate Module and Time Module to select a weather profile to play
Manage a forecast
Determine what weather profiles will be used by the system
Determine a transition time (in seconds) for your weather
// Use this code to get the current weather
CozyWeather.instance.weatherModule.ecosystem.currentWeather;
// Use this code to set the current weather
CozyWeather.instance.weatherModule.ecosystem.SetWeather(yourWeatherProfile);
// This code will add yourWeather (reference for your weather profile) to the end of the forecast.
// It will play for 5 in-game hours before changing.
CozyWeather.instance.weatherModule.ecosystem.ForecastNewWeather(yourWeather, new MeridiemTime(5, 00));
// By converting the weatherTimer float variable into Meridiem Time architecture, it will print with much nicer formatting
Debug.Log((MeridiemTime)CozyWeather.instance.weatherModule.ecosystem.weatherTimer);