- Joined
- Feb 24, 2018
- Messages
- 404
The idea is to create a dialog with two buttons for each human player at the beginning of the game.
I figured I'd use hashtables, since that would let me adapt the trigger for variable number of players.
Here's what I came up with:
However, in game it does nothing. No dialog windows appear, nothing.
Where have I made a mistake?
I figured I'd use hashtables, since that would let me adapt the trigger for variable number of players.
Here's what I came up with:
-
Initialization
-

Events
-


Map initialization
-
-

Conditions
-

Actions
-


Set intPlayerCount = 1
-


Hashtable - Create a hashtable
-


Set Player_Hashtable = (Last created hashtable)
-


Player Group - Pick every player in (All players controlled by a User player) and do (Actions)
-



Loop - Actions
-




Hashtable - Save Handle Of(Picked player) as intPlayerCount of 1 in Player_Hashtable
-




Set intPlayerCount = (intPlayerCount + 1)
-
-
-


Hashtable - Create a hashtable
-


Set DialogB_Hashtable = (Last created hashtable)
-


Hashtable - Create a hashtable
-


Set Dialog_Hashtable = (Last created hashtable)
-
-
-
CharacterCreation1
-

Events
-


Time - Elapsed game time is 1.00 seconds
-
-

Conditions
-

Actions
-


For each (Integer A) from 1 to intPlayerCount, do (Actions)
-



Loop - Actions
-




Dialog - Clear (Load (Integer A) of 1 in Dialog_Hashtable)
-




Dialog - Change the title of (Load (Integer A) of 1 in Dialog_Hashtable) to Character
-




Dialog - Create a dialog button for (Load (Integer A) of 1 in Dialog_Hashtable) labelled Create New Character
-




Hashtable - Save Handle Of(Last created dialog Button) as (Integer A) of 1 in DialogB_Hashtable
-




Dialog - Create a dialog button for (Load (Integer A) of 1 in Dialog_Hashtable) labelled Load Save Code
-




Hashtable - Save Handle Of(Last created dialog Button) as (Integer A) of 2 in DialogB_Hashtable
-




Dialog - Show (Load (Integer A) of 1 in Dialog_Hashtable) for (Load (Integer A) of 1 in Player_Hashtable)
-




Trigger - Add to CharacterCreation2a <gen> the event (Dialog - A dialog button is clicked for (Load (Integer A) of 1 in Dialog_Hashtable))
-
-
-
-
Where have I made a mistake?
Last edited:
