Scriptname SoSCivlizationConfigScript extends Quest  Conditional

Quest Property CivilizationConfigQuest  Auto  

Message Property EnableDisableMainMenu  Auto  

Message Property EnableDisableBasements  Auto  
Message Property EnableDisableCats  Auto  
Message Property EnableDisableCityActivity  Auto  
Message Property EnableDisableCityCrowd  Auto  
Message Property EnableDisableDogs  Auto  
Message Property EnableDisableEasterEggs  Auto  
Message Property EnableDisableFarms  Auto  
Message Property EnableDisableJails  Auto  
Message Property EnableDisableSnoring  Auto  
Message Property EnableDisableStables  Auto  
Message Property EnableDisableTavernActivity  Auto  
Message Property EnableDisableTavernCrowd  Auto  
Message Property EnableDisableTavernShouts  Auto  
Message Property EnableDisableTownShouts  Auto  
Message Property EnableDisableWeather  Auto  
Message Property EnableDisableWilderness  Auto  
Message Property EnableDisableEndMessage  Auto  

Int ChosenOption = 0
Int EnableDisablePage

Int BasementsDisabled  Conditional
Int CatsDisabled  Conditional
Int CityActivityDisabled  Conditional
Int CityCrowdDisabled  Conditional
Int DogsDisabled  Conditional
Int EasterEggsDisabled  Conditional
Int FarmsDisabled  Conditional
Int JailsDisabled  Conditional
Int SnoringDisabled  Conditional
Int StablesDisabled  Conditional
Int TavernActivityDisabled  Conditional
Int TavernCrowdDisabled  Conditional
Int TavernShoutsDisabled  Conditional
Int TownShoutsDisabled  Conditional
Int WeatherDisabled  Conditional
Int WildernessDisabled  Conditional


Event OnInit() ; This event will run once, when the script is initialized
	RegisterForSingleUpdate(2)
EndEvent

Event OnUpdate()

	ChosenOption = EnableDisableMainMenu.Show()

		If (ChosenOption == 0)
			EnableDisablePage = 1
			If (EnableDisablePage == 1)
				EnableDisablePage = 0
					ChosenOption = EnableDisableCityCrowd.Show()
						If (ChosenOption == 0)
							CityCrowdDisabled = 0
							EnableDisablePage = 2
						ElseIf (ChosenOption == 1)
							CityCrowdDisabled = 1
							EnableDisablePage = 2
						Endif
			Endif
		ElseIf (chosenOption == 1)
			EnableDisableEndMessage.Show()
			Stop()
		Endif
		
		If (EnableDisablePage == 2)
				EnableDisablePage = 0
					ChosenOption = EnableDisableCityActivity.Show()
						If (ChosenOption == 0)
							CityActivityDisabled = 0
							EnableDisablePage = 3
						ElseIf (ChosenOption == 1)
							CityActivityDisabled = 1
							EnableDisablePage = 3
						Endif	
		Endif	

		If (EnableDisablePage == 3)
				EnableDisablePage = 0
					ChosenOption = EnableDisableTownShouts.Show()
						If (ChosenOption == 0)
							TownShoutsDisabled = 0
							EnableDisablePage = 4
						ElseIf (ChosenOption == 1)
							TownShoutsDisabled = 1
							EnableDisablePage = 4
						Endif	
		Endif

		If (EnableDisablePage == 4)
				EnableDisablePage = 0
					ChosenOption = EnableDisableCats.Show()
						If (ChosenOption == 0)
							CatsDisabled = 0
							EnableDisablePage = 5
						ElseIf (ChosenOption == 1)
							CatsDisabled = 1
							EnableDisablePage = 5
						Endif	
		Endif

		If (EnableDisablePage == 5)
				EnableDisablePage = 0
					ChosenOption = EnableDisableDogs.Show()
						If (ChosenOption == 0)
							DogsDisabled = 0
							EnableDisablePage = 6
						ElseIf (ChosenOption == 1)
							DogsDisabled = 1
							EnableDisablePage = 6
						Endif	
		Endif	

		If (EnableDisablePage == 6)
				EnableDisablePage = 0
					ChosenOption = EnableDisableTavernCrowd.Show()
						If (ChosenOption == 0)
							TavernCrowdDisabled = 0
							EnableDisablePage = 7
						ElseIf (ChosenOption == 1)
							TavernCrowdDisabled = 1
							EnableDisablePage = 7
						Endif	
		Endif	

		If (EnableDisablePage == 7)
				EnableDisablePage = 0
					ChosenOption = EnableDisableTavernActivity.Show()
						If (ChosenOption == 0)
							TavernActivityDisabled = 0
							EnableDisablePage = 8
						ElseIf (ChosenOption == 1)
							TavernActivityDisabled = 1
							EnableDisablePage = 8
						Endif	
		Endif

		If (EnableDisablePage == 8)
				EnableDisablePage = 0
					ChosenOption = EnableDisableTavernShouts.Show()
						If (ChosenOption == 0)
							TavernShoutsDisabled = 0
							EnableDisablePage = 9
						ElseIf (ChosenOption == 1)
							TavernShoutsDisabled = 1
							EnableDisablePage = 9
						Endif	
		Endif

		If (EnableDisablePage == 9)
				EnableDisablePage = 0
					ChosenOption = EnableDisableBasements.Show()
						If (ChosenOption == 0)
							BasementsDisabled = 0
							EnableDisablePage = 10
						ElseIf (ChosenOption == 1)
							BasementsDisabled = 1
							EnableDisablePage = 10
						Endif	
		Endif

		If (EnableDisablePage == 10)
				EnableDisablePage = 0
					ChosenOption = EnableDisableStables.Show()
						If (ChosenOption == 0)
							StablesDisabled = 0
							EnableDisablePage = 11
						ElseIf (ChosenOption == 1)
							StablesDisabled = 1
							EnableDisablePage = 11
						Endif	
		Endif

		If (EnableDisablePage == 11)
				EnableDisablePage = 0
					ChosenOption = EnableDisableJails.Show()
						If (ChosenOption == 0)
							JailsDisabled = 0
							EnableDisablePage = 12
						ElseIf (ChosenOption == 1)
							JailsDisabled = 1
							EnableDisablePage = 12
						Endif	
		Endif

		If (EnableDisablePage == 12)
				EnableDisablePage = 0
					ChosenOption = EnableDisableFarms.Show()
						If (ChosenOption == 0)
							FarmsDisabled = 0
							EnableDisablePage = 13
						ElseIf (ChosenOption == 1)
							FarmsDisabled = 1
							EnableDisablePage = 13
						Endif	
		Endif

		If (EnableDisablePage == 13)
				EnableDisablePage = 0
					ChosenOption = EnableDisableWilderness.Show()
						If (ChosenOption == 0)
							WildernessDisabled = 0
							EnableDisablePage = 14
						ElseIf (ChosenOption == 1)
							WildernessDisabled = 1
							EnableDisablePage = 14
						Endif	
		Endif

		If (EnableDisablePage == 14)
				EnableDisablePage = 0
					ChosenOption = EnableDisableWeather.Show()
						If (ChosenOption == 0)
							WeatherDisabled = 0
							EnableDisablePage = 15
						ElseIf (ChosenOption == 1)
							WeatherDisabled = 1
							EnableDisablePage = 15
						Endif	
		Endif

		If (EnableDisablePage == 15)
				EnableDisablePage = 0
					ChosenOption = EnableDisableSnoring.Show()
						If (ChosenOption == 0)
							SnoringDisabled = 0
							EnableDisablePage = 16
						ElseIf (ChosenOption == 1)
							SnoringDisabled = 1
							EnableDisablePage = 16
						Endif	
		Endif

		If (EnableDisablePage == 16)
				EnableDisablePage = 0
					ChosenOption = EnableDisableEasterEggs.Show()
						If (ChosenOption == 0)
							EasterEggsDisabled = 0
							EnableDisablePage = 17
						ElseIf (ChosenOption == 1)
							EasterEggsDisabled = 1
							EnableDisablePage = 17
						Endif	
		Endif

		If (EnableDisablePage == 17)
			EnableDisablePage = 0
			EnableDisableEndMessage.Show()
			CivilizationConfigQuest.Stop()
		Endif			

EndEvent

