I had this section working - changed something and now when I move to the State OwnerMenu I loose the ability to llDetectedKey ??
It is something to do with jumping to state OwnerMenu
//Menus
string message = "";
key id = "";
integer CHANNEL = 41;// dialog channel
list MENU_OWNER = ["use for self","Test"];
list MENU_STAFF = ["Replce Note", "Replce_PIC", "Off"];
default
{
touch_start(integer num)
{
llSay(0, llDetectedKey(0));//test
state OwnerMenu;
}
}
state OwnerMenu
{
state_entry()
{
llListen(41, "", NULL_KEY, ""
; // listen for dialogllDialog(llDetectedKey(0), "What do you want to do?", MENU_OWNER, CHANNEL); // present dialog on click
llSay(0, llDetectedKey(0));//test
}
listen(integer channel, string name, key id, string message)
{
if (llListFindList(MENU_OWNER, [message]) != -1) // verify dialog
{
llSay(0, name + "pick " +(message) + "'."
;if (message == "use for self"
// Action{
llSay(0, "Use for Self"
;}
else if (message == "Test"
// Action{
llSay(0, "Test"
;}
}
}
}
- but thanks it answers the question