Difference between revisions of "EVENT TYPE POPUP RESULT"

From Dragon Age Toolset Wiki
Jump to: navigation, search
(split off of event)
 
(formatting)
Line 1: Line 1:
*<b>Sent When:</b> player responds to area transition prompt.
+
{{event
*<b>Sent From:</b>
+
|when= player responds to area transition prompt.
*<b>Sent To:</b> module
+
|from=
 
+
|to= module
Parameters:
+
|object0name= oOwner
 
+
|object0desc= owner of popup
*object oOwner = GetEventObject(ev, 0);      // owner of popup
+
|int0name= nPopupID
*int nPopupID = GetEventInteger(ev, 0);    // popup ID
+
|int0desc = popup ID
*int nButton   = GetEventInteger(ev, 1);    // button result (1 - 4)
+
|int1name= nButton
*string sInput = GetEventString(ev,0);      // string entered into optional text field
+
|int1desc= button result (1 - 4)
 +
|string0name= sInput
 +
|string0desc= string entered into optional text field
 +
}}
  
 
Calling the "[[ShowPopup]]" script function causes a popup window to be displayed to the user, with up to four buttons whose text is defined in the "popups" 2DA and up to one text input field (with a filter on the input the player can type there that's the same as the filter on player names - up to 20 characters, no spaces, limited punctuation, no empty strings). This event is generated and sent to the module script with the popup's result.
 
Calling the "[[ShowPopup]]" script function causes a popup window to be displayed to the user, with up to four buttons whose text is defined in the "popups" 2DA and up to one text input field (with a filter on the input the player can type there that's the same as the filter on player names - up to 20 characters, no spaces, limited punctuation, no empty strings). This event is generated and sent to the module script with the popup's result.
  
 
[[Category:Event types|POPUP_RESULT]]
 
[[Category:Event types|POPUP_RESULT]]

Revision as of 20:30, 24 July 2009

Source:
[Undocumented]
Sent when:
player responds to area transition prompt.
Sent from:
Sent to:
module
Parameters:
  • Integer 0: popup ID
  • Integer 1: button result (1 - 4)
  • String 0: string entered into optional text field
  • Object 0: owner of popup

Usage

case EVENT_TYPE_POPUP_RESULT:
{
int nPopupID = GetEventInteger(ev, 0); // popup ID
int nButton = GetEventInteger(ev, 1); // button result (1 - 4)
string sInput = GetEventString(ev, 0); // string entered into optional text field
object oOwner = GetEventObject(ev, 0); // owner of popup

// insert event-handling code here

break;
}

Calling the "ShowPopup" script function causes a popup window to be displayed to the user, with up to four buttons whose text is defined in the "popups" 2DA and up to one text input field (with a filter on the input the player can type there that's the same as the filter on player names - up to 20 characters, no spaces, limited punctuation, no empty strings). This event is generated and sent to the module script with the popup's result.