Difference between revisions of "ShowPopup"
From Dragon Age Toolset Wiki
m (Adding Remarks heading) |
m (Fixing category) |
||
(One intermediate revision by the same user not shown) | |||
Line 1: | Line 1: | ||
{{dafunction | {{dafunction | ||
|name = ShowPopup | |name = ShowPopup | ||
− | |brief = Show a pop-up message box | + | |brief = Show a pop-up message box. |
|param1type = int | |param1type = int | ||
|param1name = nMessageStrRef | |param1name = nMessageStrRef | ||
Line 8: | Line 8: | ||
|param2type = int | |param2type = int | ||
|param2name = nPopupType | |param2name = nPopupType | ||
− | |param2desc = a reference to the popup type, defined in [[popups | + | |param2desc = a reference to the popup type, defined in [[popups 2da]] |
|param2default = | |param2default = | ||
|param3type = object | |param3type = object | ||
Line 32: | Line 32: | ||
== Remarks == | == Remarks == | ||
<!-- This section contains additional comments, observations and known issues. --> | <!-- This section contains additional comments, observations and known issues. --> | ||
− | When a button is pressed and the pop-up is closed, the contents of the text- | + | When a button is pressed and the pop-up is closed, the contents of the text-field will be returned as the 0th string argument to the [[EVENT_TYPE_POPUP_RESULT]] event to the module. |
− | + | The text is filtered as it is typed using the same filter that is applied to the player's name; thus, you cannot enter spaces nor many forms of punctuation. The text-field is currently limited to 20 characters (same as the player name). | |
<!-- == Examples == --> | <!-- == Examples == --> | ||
<!-- This section contains examples transcluded from the snippet library. --> | <!-- This section contains examples transcluded from the snippet library. --> | ||
<!-- == See also == --> | <!-- == See also == --> | ||
<!-- This section contains links to articles, functions or constant groups. --> | <!-- This section contains links to articles, functions or constant groups. --> | ||
− | [[Category: | + | [[Category:GUI functions]] |
Latest revision as of 00:04, 11 February 2013
Show a pop-up message box.
void ShowPopup(
int nMessageStrRef,
int nPopupType,
object oOwner = OBJECT_INVALID,
int bShowInputField = FALSE,
int nDefaultInputStrRef = 0
);
int nMessageStrRef,
int nPopupType,
object oOwner = OBJECT_INVALID,
int bShowInputField = FALSE,
int nDefaultInputStrRef = 0
);
- Parameters:
- nMessageStrRef
- a string reference to the text of the message box
- nPopupType
- a reference to the popup type, defined in popups 2da
- oOwner
- the owner of this popup
- bShowInputField
- a boolean which controls whether the pop-up will have a text-input field
- nDefaultInputStrRef
- a string reference to the default text for the text-input. If 0, the input field will start empty
- Returns:
- Nothing.
- Source:
- script.ldf
Remarks
When a button is pressed and the pop-up is closed, the contents of the text-field will be returned as the 0th string argument to the EVENT_TYPE_POPUP_RESULT event to the module.
The text is filtered as it is typed using the same filter that is applied to the player's name; thus, you cannot enter spaces nor many forms of punctuation. The text-field is currently limited to 20 characters (same as the player name).