- Joined
- Aug 14, 2007
- Messages
- 66
So I am trying to create a drop down list dialog that allows players to choose 1 of 5 options: Random, Protoss, Terran, Zerg, and None.
The aesthetics work just fine but I cant get the game to recognize what the player has actually selected and I realized that the game thought that the player had chosen every single one of the options whenever the player configured the drop down menu and selected an item. since random is the last one in my dialogue event trigger it ends up being the one selected every time.
If anyone could take a quick look and tell me what event/condition I need to differentiate which one is selected that would be awesome.
The aesthetics work just fine but I cant get the game to recognize what the player has actually selected and I realized that the game thought that the player had chosen every single one of the options whenever the player configured the drop down menu and selected an item. since random is the last one in my dialogue event trigger it ends up being the one selected every time.
If anyone could take a quick look and tell me what event/condition I need to differentiate which one is selected that would be awesome.
-
Setup
-
Events
- Timer - Elapsed time is 1.0 Game Time seconds
- Local Variables
- Conditions
-
Actions
-
Player Group - Pick each player in Players and do (Actions)
-
Actions
- Dialog - Create a Modal dialog of size (500, 200) at (0, -100) relative to Center of screen
- Variable - Set OptionMenu[(Picked player)] = (Last created dialog)
- Dialog - Create a Pulldown for dialog OptionMenu[(Picked player)]
- Variable - Set OptionMenu_RaceList[(Picked player)] = (Last created dialog item)
- Dialog - Move OptionMenu_RaceList[(Picked player)] to (0, 50) relative to Bottom of dialog for (Player group((Picked player)))
- Dialog - Set OptionMenu_RaceList[(Picked player)] tooltip to "Select your race preference to opt ..." for (Player group((Picked player)))
- Dialog - Add list item "Random" to OptionMenu_RaceList[(Picked player)] for (Player group((Picked player)))
- Variable - Set OptionMenu_RaceList_Random[(Picked player)] = (Last created dialog item)
- Dialog - Add list item "Protoss" to OptionMenu_RaceList[(Picked player)] for (Player group((Picked player)))
- Variable - Set OptionMenu_RaceList_Protoss[(Picked player)] = (Last created dialog item)
- Dialog - Add list item "Terran" to OptionMenu_RaceList[(Picked player)] for (Player group((Picked player)))
- Variable - Set OptionMenu_RaceList_Terran[(Picked player)] = (Last created dialog item)
- Dialog - Add list item "Zerg" to OptionMenu_RaceList[(Picked player)] for (Player group((Picked player)))
- Variable - Set OptionMenu_RaceList_Zerg[(Picked player)] = (Last created dialog item)
- Dialog - Add list item "None" to OptionMenu_RaceList[(Picked player)] for (Player group((Picked player)))
- Variable - Set OptionMenu_RaceList_None[(Picked player)] = (Last created dialog item)
- Dialog - Show OptionMenu[(Picked player)] for (Player group((Picked player)))
-
Actions
-
Player Group - Pick each player in Players and do (Actions)
-
Events
-
Select Race
-
Events
- Dialog - Any Dialog Item is used by Player Any Player with event type Any
- Local Variables
- Conditions
-
Actions
-
General - If (Conditions) then do (Actions) else do (Actions)
-
If
- OptionMenu_RaceList_None[(Triggering player)] == (Used dialog item)
-
Then
- UI - Display "None Selected" for (All players) to Subtitle area
- Variable - Set PlayerOpt[(Triggering player)] = false
- Variable - Set SelectedRace_Random[(Triggering player)] = false
- Else
-
If
-
General - If (Conditions) then do (Actions) else do (Actions)
-
If
- OptionMenu_RaceList_Protoss[(Triggering player)] == (Used dialog item)
-
Then
- UI - Display "Protoss Selected" for (All players) to Subtitle area
- Variable - Set SelectedRace[(Triggering player)] = Protoss
- Variable - Set SelectedRace_Random[(Triggering player)] = false
- Variable - Set PlayerOpt[(Triggering player)] = true
- Else
-
If
-
General - If (Conditions) then do (Actions) else do (Actions)
-
If
- OptionMenu_RaceList_Terran[(Triggering player)] == (Used dialog item)
-
Then
- UI - Display "Terran Selected" for (All players) to Subtitle area
- Variable - Set SelectedRace[(Triggering player)] = Terran
- Variable - Set SelectedRace_Random[(Triggering player)] = false
- Variable - Set PlayerOpt[(Triggering player)] = true
- Else
-
If
-
General - If (Conditions) then do (Actions) else do (Actions)
-
If
- OptionMenu_RaceList_Zerg[(Triggering player)] == (Used dialog item)
-
Then
- UI - Display "Zerg Selected" for (All players) to Subtitle area
- Variable - Set SelectedRace[(Triggering player)] = Zerg
- Variable - Set SelectedRace_Random[(Triggering player)] = false
- Variable - Set PlayerOpt[(Triggering player)] = true
- Else
-
If
-
General - If (Conditions) then do (Actions) else do (Actions)
-
If
- OptionMenu_RaceList_Random[(Triggering player)] == (Used dialog item)
-
Then
- UI - Display "Random Selected" for (All players) to Subtitle area
- Variable - Set SelectedRace_Random[(Triggering player)] = true
- Variable - Set PlayerOpt[(Triggering player)] = true
- Else
-
If
-
General - If (Conditions) then do (Actions) else do (Actions)
-
Events