Jump to content

Messagebox Problems


Mattiewagg

Recommended Posts

Okay. I'm having an issue with the following script (an excerpt from my MCM), for my mod Simple Taxes:

 

 


Event OnSelectST()

	If ShowCompMes == 0

		SetTextOptionValueST("Exit MCM")
		ShowCompMes = 1
		Utility.Wait(0.5)
		SetTextOptionValueST("Add Compatibility")
		Int Button1 = ChangeCountMes.Show()

		If Button1 == 0

			Int Button2 = ChangeCountHouseMes.Show()

			If Button2 == 0

				Game.IncrementStat("Houses Owned", 1)
				Button1 = ChangeCountMes.Show()

			ElseIf Button2 == 1

				Game.IncrementStat("Houses Owned", -1)
				Button1 = ChangeCountMes.Show()

			ElseIf Button2 == 2

				Button1 = ChangeCountMes.Show()

			ElseIf Button2 == 3

				;do nothing

			EndIf

		ElseIf Button1 == 1

			Int Button3 = ChangeCountHorseMes.Show()

			If Button3 == 0

				Game.IncrementStat("Horses Owned", 1)
				Button1 = ChangeCountMes.Show()

			ElseIf Button3 == 1

				Game.IncrementStat("Horses Owned", -1)
				Button1 = ChangeCountMes.Show()

			ElseIf Button3 == 2

				Button1 = ChangeCountMes.Show()

			ElseIf Button3 == 3

				;do nothing?

			EndIf

		ElseIf Button1 == 2

			;do nothing

		EndIf

		ShowCompMes = 0

	EndIf

EndEvent

 

 

 

The issue is that if you press button 0 or 1 for Button2 or Button3, and then click button 2 after that for either of them, it will show the original menu but if you press 0 or 1 for that original menu after doing all that, it will close the menu. Can anyone help?

Edited by Matthiaswagg
Link to comment
Share on other sites

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...