internal static void CreateCountries() { var countryNameGenerator = new CountryNameGenerator(); var cultureNameGenerator = new CultureNameGenerator(); //int howMuchCountries =3; int howMuchCountries = allProvinces.Count / Options.ProvincesPerCountry; howMuchCountries += Game.Random.Next(6); if (howMuchCountries < 8) { howMuchCountries = 8; } for (int i = 0; i < howMuchCountries; i++) { //Game.updateStatus("Making countries.." + i); Culture culture = new Culture(cultureNameGenerator.generateCultureName(), ColorExtensions.getRandomColor()); allCultures.Add(culture); Province province = GetAllProvinces().Where(x => x.Country == UncolonizedLand).Random(); Country country = new Country(countryNameGenerator.generateCountryName(), culture, culture.getColor(), province, 100f); allCountries.Add(country); //count.setBank(count.bank); country.GiveMoneyFromNoWhere(100); } Game.Player = allCountries[1]; // not wild Tribes, DONT touch that allCountries.Random().SetName("Zacharia"); //foreach (var pro in allProvinces) // if (pro.Country == null) // pro.InitialOwner(World.UncolonizedLand); }
void Awake() { instance = this; }