NWNX:EE  8193.36.12
nwnx_dialog.nss
Go to the documentation of this file.
1 
6 #include "nwnx"
7 
8 const string NWNX_Dialog = "NWNX_Dialog";
9 
18 
26 
41 
45 
49 
55 
60 
64 string NWNX_Dialog_GetCurrentNodeText(int language=NWNX_DIALOG_LANGUAGE_ENGLISH, int gender=GENDER_MALE);
65 
71 void NWNX_Dialog_SetCurrentNodeText(string text, int language=NWNX_DIALOG_LANGUAGE_ENGLISH, int gender=GENDER_MALE);
72 
76 void NWNX_Dialog_End(object oObject);
77 
79 
80 
82 {
83  string sFunc = "GetCurrentNodeType";
84 
85  NWNX_CallFunction(NWNX_Dialog, sFunc);
86  return NWNX_GetReturnValueInt();
87 }
88 
90 {
91  string sFunc = "GetCurrentScriptType";
92 
93  NWNX_CallFunction(NWNX_Dialog, sFunc);
94  return NWNX_GetReturnValueInt();
95 }
96 
98 {
99  string sFunc = "GetCurrentNodeID";
100 
101  NWNX_CallFunction(NWNX_Dialog, sFunc);
102  return NWNX_GetReturnValueInt();
103 }
104 
106 {
107  string sFunc = "GetCurrentNodeIndex";
108 
109  NWNX_CallFunction(NWNX_Dialog, sFunc);
110  return NWNX_GetReturnValueInt();
111 }
112 
113 string NWNX_Dialog_GetCurrentNodeText(int language=NWNX_DIALOG_LANGUAGE_ENGLISH, int gender=GENDER_MALE)
114 {
115  string sFunc = "GetCurrentNodeText";
116 
117  NWNX_PushArgumentInt(gender);
118  NWNX_PushArgumentInt(language);
119  NWNX_CallFunction(NWNX_Dialog, sFunc);
120  return NWNX_GetReturnValueString();
121 }
122 
123 void NWNX_Dialog_SetCurrentNodeText(string text, int language=NWNX_DIALOG_LANGUAGE_ENGLISH, int gender=GENDER_MALE)
124 {
125  string sFunc = "SetCurrentNodeText";
126 
127  NWNX_PushArgumentInt(gender);
128  NWNX_PushArgumentInt(language);
130  NWNX_CallFunction(NWNX_Dialog, sFunc);
131 }
132 
133 void NWNX_Dialog_End(object oObject)
134 {
135  string sFunc = "End";
136 
137  NWNX_PushArgumentObject(oObject);
138  NWNX_CallFunction(NWNX_Dialog, sFunc);
139 }
NWNX_Dialog_GetCurrentScriptType
int NWNX_Dialog_GetCurrentScriptType()
Get the Script Type of the current text node.
Definition: nwnx_dialog.nss:89
NWNX_GetReturnValueInt
int NWNX_GetReturnValueInt()
Returns the specified type from the c++ side.
Definition: nwnx.nss:94
NWNX_DIALOG_LANGUAGE_JAPANESE
const int NWNX_DIALOG_LANGUAGE_JAPANESE
Definition: nwnx_dialog.nss:39
NWNX_DIALOG_LANGUAGE_CHINESE_TRADITIONAL
const int NWNX_DIALOG_LANGUAGE_CHINESE_TRADITIONAL
Definition: nwnx_dialog.nss:37
NWNX_Dialog_GetCurrentNodeID
int NWNX_Dialog_GetCurrentNodeID()
Get the absolute ID of the current node in the conversation.
Definition: nwnx_dialog.nss:97
NWNX_DIALOG_LANGUAGE_GERMAN
const int NWNX_DIALOG_LANGUAGE_GERMAN
Definition: nwnx_dialog.nss:32
NWNX_DIALOG_NODE_TYPE_STARTING_NODE
const int NWNX_DIALOG_NODE_TYPE_STARTING_NODE
Definition: nwnx_dialog.nss:14
NWNX_DIALOG_LANGUAGE_CHINESE_SIMPLIFIED
const int NWNX_DIALOG_LANGUAGE_CHINESE_SIMPLIFIED
Definition: nwnx_dialog.nss:38
NWNX_DIALOG_NODE_TYPE_REPLY_NODE
const int NWNX_DIALOG_NODE_TYPE_REPLY_NODE
Definition: nwnx_dialog.nss:16
NWNX_DIALOG_LANGUAGE_KOREAN
const int NWNX_DIALOG_LANGUAGE_KOREAN
Definition: nwnx_dialog.nss:36
NWNX_Dialog_GetCurrentNodeText
string NWNX_Dialog_GetCurrentNodeText(int language=NWNX_DIALOG_LANGUAGE_ENGLISH, int gender=GENDER_MALE)
Get the text of the current node.
Definition: nwnx_dialog.nss:113
NWNX_DIALOG_NODE_TYPE_ENTRY_NODE
const int NWNX_DIALOG_NODE_TYPE_ENTRY_NODE
Definition: nwnx_dialog.nss:15
NWNX_CallFunction
void NWNX_CallFunction(string pluginName, string functionName)
Scripting interface to NWNX.
Definition: nwnx.nss:54
NWNX_DIALOG_LANGUAGE_ENGLISH
const int NWNX_DIALOG_LANGUAGE_ENGLISH
Definition: nwnx_dialog.nss:30
NWNX_DIALOG_NODE_TYPE_INVALID
const int NWNX_DIALOG_NODE_TYPE_INVALID
Definition: nwnx_dialog.nss:13
NWNX_DIALOG_LANGUAGE_POLISH
const int NWNX_DIALOG_LANGUAGE_POLISH
Definition: nwnx_dialog.nss:35
NWNX_Dialog_GetCurrentNodeIndex
int NWNX_Dialog_GetCurrentNodeIndex()
Get the index of the current node in the list of replies/entries.
Definition: nwnx_dialog.nss:105
NWNX_DIALOG_SCRIPT_TYPE_OTHER
const int NWNX_DIALOG_SCRIPT_TYPE_OTHER
Definition: nwnx_dialog.nss:22
NWNX_GetReturnValueString
string NWNX_GetReturnValueString()
Returns the specified type from the c++ side.
Definition: nwnx.nss:109
NWNX_PushArgumentString
void NWNX_PushArgumentString(string value)
Pushes the specified type to the c++ side.
Definition: nwnx.nss:74
NWNX_DIALOG_LANGUAGE_SPANISH
const int NWNX_DIALOG_LANGUAGE_SPANISH
Definition: nwnx_dialog.nss:34
NWNX_DIALOG_SCRIPT_TYPE_STARTING_CONDITIONAL
const int NWNX_DIALOG_SCRIPT_TYPE_STARTING_CONDITIONAL
Definition: nwnx_dialog.nss:23
NWNX_PushArgumentObject
void NWNX_PushArgumentObject(object value)
Pushes the specified type to the c++ side.
Definition: nwnx.nss:69
NWNX_DIALOG_LANGUAGE_FRENCH
const int NWNX_DIALOG_LANGUAGE_FRENCH
Definition: nwnx_dialog.nss:31
NWNX_Dialog_End
void NWNX_Dialog_End(object oObject)
End a conversation oObject is involved in, it will fire the OnAbort script of the conversation.
Definition: nwnx_dialog.nss:133
NWNX_PushArgumentInt
void NWNX_PushArgumentInt(int value)
Pushes the specified type to the c++ side.
Definition: nwnx.nss:59
NWNX_Dialog_SetCurrentNodeText
void NWNX_Dialog_SetCurrentNodeText(string text, int language=NWNX_DIALOG_LANGUAGE_ENGLISH, int gender=GENDER_MALE)
Set the text of the current node for given language/gender.
Definition: nwnx_dialog.nss:123
NWNX_DIALOG_LANGUAGE_ITALIAN
const int NWNX_DIALOG_LANGUAGE_ITALIAN
Definition: nwnx_dialog.nss:33
NWNX_DIALOG_SCRIPT_TYPE_ACTION_TAKEN
const int NWNX_DIALOG_SCRIPT_TYPE_ACTION_TAKEN
Definition: nwnx_dialog.nss:24
NWNX_Dialog_GetCurrentNodeType
int NWNX_Dialog_GetCurrentNodeType()
Get the Node Type of the current text node.
Definition: nwnx_dialog.nss:81