Jump to content

LailaSystem

Resident
  • Posts

    1
  • Joined

  • Last visited

Reputation

0 Neutral

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

  1. Hey, I'm currently trying to send RLV command using llOwnerSay through menu buttons The issue i'm having is that the first time i click the menu button nothing happens, the second time the bool i have in there switches but the command isnt sent, the third time i click it the bool flips again and the command is sent meaning i have in this case, far touch restricted but my boolean saying it is false (not restricted) and i had to click it three times... any help would be highly appreciated key owner; key toucher; key locker; list MainM = ["Lock/Unlock","Owners","--"]; list LockerM = ["Lock/Unlock","Owners","RLV Options"]; list OwnersM = ["Add Primary", "Remove Primary", "--"]; list RLVM = ["Far Touch","Touch Self","Touch Others","Touch World","<BACK>","TEST"]; integer Channel = 1234567; integer handle; integer hasOwner = FALSE; integer islocked = FALSE; integer far = FALSE; integer self = FALSE; integer others = FALSE; integer world = FALSE; MainMenu(key id) { handle = llListen(Channel,"","",""); llDialog(id,"Main Menu", MainM,Channel); } OwnersMenu(key id) { handle = llListen(Channel,"","",""); llDialog(id,"Owners Menu", OwnersM,Channel); } LockerMenu(key id) { handle = llListen(Channel,"","",""); llDialog(id,"Locker Menu", LockerM,Channel); } RLVMenu(key id) { handle = llListen(Channel,"","",""); llDialog(id,"RLV Menu", RLVM, Channel); } RLVUnlock() { llOwnerSay("Unlocked"); llOwnerSay( "@clear"); owner = ""; llSetLinkPrimitiveParamsFast(2, [PRIM_DESC, "iamunlocked"]); islocked = FALSE; far = FALSE; self = FALSE; others = FALSE; world = FALSE; llListenRemove(handle); } RLVLock() { llOwnerSay("Locked"); llOwnerSay( "@remoutfit=n" ); llOwnerSay( "@remattach=n"); llOwnerSay("@detach:ATTACH_RUARM=y"); llSetLinkPrimitiveParamsFast(2, [PRIM_DESC, "iamlocked"]); islocked=TRUE; } RLVFar() { if(world == TRUE) { llOwnerSay("@fartouch=y"); } } RLVWorld() { if(world == TRUE) { llOwnerSay("@touchworld=y"); } } RLVOthers() { if(world == TRUE) { llOwnerSay("@touchattachother=y"); } } RLVSelf() { if(world == TRUE) { llOwnerSay("@touchattachself=y");; } } default { state_entry() { } touch_start(integer x) { if(hasOwner == TRUE) { if(llDetectedKey(0) == llGetObjectDesc()) { owner = llGetObjectDesc(); MainMenu(owner); } else { string ToucherName = llKey2Name(llDetectedKey(0)); llSay(PUBLIC_CHANNEL,"NOT OWNER: You have no access to these restraints " + ToucherName); } } else if(hasOwner == FALSE) { if(llDetectedKey(0) != NULL_KEY) { toucher = llDetectedKey(0); MainMenu(toucher); } } } //Menu Options below listen(integer chan, string Name, key id, string message) { if(chan == Channel) { if(message == "Lock/Unlock") { llSetObjectDesc(toucher); RLVLock(); llListenRemove(handle); state locked; } if(message == "Owners") { OwnersMenu(toucher); llListenRemove(handle); } //TO DO: OWNERS MENU OPTIONS } } } state locked { state_entry() { llOwnerSay("You have been locked by " + "secondlife:///app/agent/" + llGetObjectDesc() + "/displayname"); } attach(key id) { if("iamlocked" == llList2String(llGetLinkPrimitiveParams(2, [ PRIM_DESC ]), 0)) { islocked = TRUE; } if(islocked == TRUE) { llOwnerSay( "@remoutfit=n" ); llOwnerSay( "@remattach=n"); RLVFar(); RLVWorld(); RLVOthers(); RLVSelf(); } } touch_start(integer x) { if(llDetectedKey(0) == llGetObjectDesc()) { owner = llDetectedKey(0); LockerMenu(owner); } else { string ToucherName = llKey2Name(llDetectedKey(0)); llSay(PUBLIC_CHANNEL,"NOT LOCKER: You have no access to these restraints " + ToucherName); } } listen(integer chan, string Name, key id, string message) { if(chan == Channel) { if(message == "Lock/Unlock") { llSetObjectDesc(""); RLVUnlock(); llListenRemove(handle); state default; } else if(message == "RLV Options") { RLVMenu(owner); llListenRemove(handle); } else if(message == "Touch Self") { llSay(PUBLIC_CHANNEL, "SELF"); if(self == TRUE) { llOwnerSay("@touchattachself=n"); self = FALSE; llListenRemove(handle); } else { llOwnerSay("@touchattachself=y"); self = TRUE; llListenRemove(handle); } } else if(message == "Far Touch") { llSay(PUBLIC_CHANNEL, "FAR"); if(far == TRUE) { llOwnerSay("@fartouch=n"); far = FALSE; llListenRemove(handle); } else { llOwnerSay("@fartouch=y"); far = TRUE; llListenRemove(handle); } } else if(message == "Touch Others") { llSay(PUBLIC_CHANNEL, "OTHERS"); if(others == TRUE) { llOwnerSay("@touchattachother=n"); others = FALSE; llListenRemove(handle); } else { llOwnerSay("@touchattachother=y"); others = TRUE; llListenRemove(handle); } } else if(message == "Touch World") { llSay(PUBLIC_CHANNEL, "WORLD"); if(world == TRUE) { llOwnerSay("@touchworld=n"); world = FALSE; llListenRemove(handle); } else { llOwnerSay("@touchworld=y"); world = TRUE; llListenRemove(handle); } } else if(message == "<BACK>") { llSay(PUBLIC_CHANNEL, "BACK"); LockerMenu(owner); llListenRemove(handle); } else if(message == "TEST") { if(self == TRUE) { llSay(PUBLIC_CHANNEL, "Self True"); } if(self == FALSE) { llSay(PUBLIC_CHANNEL, "Self false"); } if(far == TRUE) { llSay(PUBLIC_CHANNEL, "Far True"); } if(far == FALSE) { llSay(PUBLIC_CHANNEL, "far false"); } if(others == TRUE) { llSay(PUBLIC_CHANNEL, "others True"); } if(others == FALSE) { llSay(PUBLIC_CHANNEL, "others false"); } if(world == TRUE) { llSay(PUBLIC_CHANNEL, "world True"); } if(world == FALSE) { llSay(PUBLIC_CHANNEL, "world false"); } llListenRemove(handle); } } } }
×
×
  • Create New...