public Weather() { climate = Climate.Temperate; elevation = Elevation.SeaLevel; season = Season.Spring; precipitationIntensity = PrecipitationIntensity.Heavy; precipitationFrequency = PrecipitationFrequency.Intermittent; precipitationForm = PrecipitationForm.RainHeavy; cloudCover = CloudCover.CloudsMedium; windStrength = WindStrength.Light; windCheckSize = CharacterSize.None; windBlownAwaySize = CharacterSize.None; severeWeatherEvent = SevereWeatherEvent.None; inDesert = false; isDay = true; nightTempDrop = 0; RecalculateAll(true); }
private void SetSevereEvents() // if the system spits out a crazy number cool things happen { if ((windStrength == WindStrength.Severe || windStrength == WindStrength.Windstorm) && isRaining && precipitationForm == PrecipitationForm.SnowHeavy) { if (DiceRoller.RollD100() <= 20) { rainForHours = DiceRoller.RollD12(2); } severeWeatherEvent = SevereWeatherEvent.Blizzard; } else if ((windStrength == WindStrength.Severe || windStrength == WindStrength.Windstorm) && inDesert) { severeWeatherEvent = SevereWeatherEvent.Sandstorm; } else if ((windStrength == WindStrength.Severe || windStrength == WindStrength.Windstorm) && inDesert && precipitationForm == PrecipitationForm.Thunderstorm) { severeWeatherEvent = SevereWeatherEvent.Haboob; } else if (precipitationForm == PrecipitationForm.Thunderstorm) { if (DiceRoller.RollD100() <= 5) { severeWeatherEvent = SevereWeatherEvent.Hail; } } else if (precipitationForm == PrecipitationForm.RainHeavy && windStrength == WindStrength.Windstorm && windSpeed >= 75) { severeWeatherEvent = SevereWeatherEvent.Hurricane; } else if (windSpeed >= 174) { severeWeatherEvent = SevereWeatherEvent.Tornado; } else { severeWeatherEvent = SevereWeatherEvent.None; } }