Difference between revisions of "MessageBox Tutorial"
Jump to navigation
Jump to search
m
→Activator Script
imported>Haama (→Activator Script: Using Variable-Loaded method, changed around extra button info) |
imported>Haama |
||
Line 349: | Line 349: | ||
Begin GameMode | Begin GameMode | ||
If Working | If Working | ||
If (Choosing == 0) ;meaning it shouldn't be running | |||
Set Working to 0 | |||
;Add anything that needs to be re-initialized, | |||
Elseif (Choosing == -1) ;Display your menu | |||
Messagebox "Which option?" "First Option" "Second Option" ... "Tenth Option" | |||
Set Choosing to 1 | |||
Set Choice to -1 | |||
Elseif (Choosing == 1) ;Catch the player's decision | |||
If (Choice == -1) ;No choice yet | |||
Set Choice to GetButtonPressed | |||
Elseif (Choice == 0) ;First Option | |||
;run your code for the first decision | |||
Set Choosing to 0 ;to finish up | |||
Elseif (Choice == 1) ;Second Option | |||
;run your code for the second decision | |||
Set Choosing to 0 ;to finish up | |||
;... | ;... | ||
; | ; Elseif (Choice == 9) ;Tenth Option | ||
;run your code for the tenth decision | |||
; | ; Set Choosing to 0 ;to finish up | ||
Endif | |||
Endif | Endif | ||
Set Working to 1 | |||
Endif | Endif | ||
End</pre> | End</pre> | ||
You can start your menus from any script with < | You can start your menus from any script with <pre>YourActivatorsReferenceEditorID.Activate player, 1</pre>. | ||
==Moving Between Multiple Menus== | ==Moving Between Multiple Menus== |