BOT_EVENT_LISTEN_DIALOG
From SmartBots Developers Docs
Revision as of 09:41, 20 May 2017 by Chevonn Edelmann (Talk | contribs) (Created page with "{{DISPLAYTITLE:BOT_EVENT_LISTEN_DIALOG}} <onlyinclude>Raised when Bot receives a dialog menu</onlyinclude> {{API Event Table}} {{API Variable Group|''event'' object propertie...")
Raised when Bot receives a dialog menu
Reference
This event comes with the following event object:
Variable | Required | Description | |
---|---|---|---|
event object properties: | |||
str | Dialog details in the format "channel\nObjectName\nOwnerName\nDialogMsg\nButtons" | ||
id | UUID of object that sent dialog |
Example
link_message( integer sender_num, integer num, string str, key id ) {
/////////////////// Bot listen dialog event
if(num==BOT_EVENT_LISTEN_DIALOG) {
// Split details with a semi colon "\n"
list details = llParseString2List(str, ["\n"], []);
llOwnerSay("Channel: " + llList2String(details,0));
llOwnerSay("Object Name: " + llList2String(details,1));
llOwnerSay("Owner Name: " + llList2String(details,2));
llOwnerSay("Dialog Message: " + llList2String(details,2));
llOwnerSay("Buttons: " + llList2String(details,2));
llOwnerSay("Object UUID: " + (string)id);
}
}