Difference between revisions of "LSL Protocol/Restrained Love Relay/Bugs and Pending Features"

From Second Life Wiki
Jump to navigation Jump to search
(bug report added)
Line 13: Line 13:
; Suggested fix : change in <code>timer()</code>: <code>sendRLCmd ("@sit:"+(string)kSource+"=force");</code> to <code>sendRLCmd ("@sit:"+(string)lastForceSitDestination+"=force");</code>
; Suggested fix : change in <code>timer()</code>: <code>sendRLCmd ("@sit:"+(string)kSource+"=force");</code> to <code>sendRLCmd ("@sit:"+(string)lastForceSitDestination+"=force");</code>
; Note : This causes trouble in case the person set down without being forced.
; Note : This causes trouble in case the person set down without being forced.
== Stuck on crash/relog with objects asking for relay upon being sat on ==
; Discovered by : Gregor Mougin
; Problem : Many objects check for presence of a relay and the RR viewer by asking for the !version when sat on. If the user crashes, and the object was used by someone else in the meantime (or, for testing, reset), the relay enforces all previous restrictions whereas the object doesn't know of them.
; Workaround : none
; Suggested fix :
<lsl>
--- RLV_v1.014a 2008-07-06 23:17:14.000000000 +0200
+++ RLV_v1.014a-xxx    2008-07-06 23:18:32.000000000 +0200
@@ -545,10 +545,16 @@
                loginPendingForceSit = FALSE;
                releaseRestrictions();
            }
-            else
-            {
-                sendRLCmd ("@sit:"+(string)kSource+"=force");
-            }
+            // XXX
+            // DON'T do it here
+            // Some (many?) objects ask the relay for the !version upon
+            // sitting on it. Since the !version is interpreted the same
+            // as !pong, the relay would think the object is still available
+            // and put all restrictions on the wearer unconditionally.
+            //else
+            //{
+            //    sendRLCmd ("@sit:"+(string)kSource+"=force");
+            //}
        }
 
        if (!loginPendingForceSit && !loginWaitingForPong)
@@ -583,6 +589,18 @@
 
            loginWaitingForPong = FALSE; // whatever the message, it is for me => it satisfies the ping request
 
+            // XXX
+            // force sit here instead of unconditionally in the timer event
+            if (loginPendingForceSit)
+            {
+                integer agentInfo = llGetAgentInfo(llGetOwner());
+               
+                loginPendingForceSit = FALSE;
+                if (!(agentInfo & AGENT_SITTING))
+                    sendRLCmd ("@sit:"+(string)kSource+"=force");
+            }
+            // end XXX
+           
            if (!isObjectKnow(id))
            {
                debug("asking for permission because kSource is NULL_KEY");
</lsl>

Revision as of 14:34, 6 July 2008

Stuck: Accepting Permission after !release

Discovered by
Maike Short
Workaround
Don't accept requests after you have been freed. In case it happend, reenter the cage / sit down again; relog.
Suggested fix
not yet

Force Sit during Login on the control object instead of the forced-sit one

Discovered by
Azoth Amat
Workaround
Put the script into the same object as the one the person is forced to sit on.
Suggested fix
change in timer(): sendRLCmd ("@sit:"+(string)kSource+"=force"); to sendRLCmd ("@sit:"+(string)lastForceSitDestination+"=force");
Note
This causes trouble in case the person set down without being forced.

Stuck on crash/relog with objects asking for relay upon being sat on

Discovered by
Gregor Mougin
Problem
Many objects check for presence of a relay and the RR viewer by asking for the !version when sat on. If the user crashes, and the object was used by someone else in the meantime (or, for testing, reset), the relay enforces all previous restrictions whereas the object doesn't know of them.
Workaround
none
Suggested fix

<lsl> --- RLV_v1.014a 2008-07-06 23:17:14.000000000 +0200 +++ RLV_v1.014a-xxx 2008-07-06 23:18:32.000000000 +0200 @@ -545,10 +545,16 @@

                loginPendingForceSit = FALSE;
                releaseRestrictions();
            }

- else - { - sendRLCmd ("@sit:"+(string)kSource+"=force"); - } + // XXX + // DON'T do it here + // Some (many?) objects ask the relay for the !version upon + // sitting on it. Since the !version is interpreted the same + // as !pong, the relay would think the object is still available + // and put all restrictions on the wearer unconditionally. + //else + //{ + // sendRLCmd ("@sit:"+(string)kSource+"=force"); + //}

        }
 
        if (!loginPendingForceSit && !loginWaitingForPong)

@@ -583,6 +589,18 @@

            loginWaitingForPong = FALSE; // whatever the message, it is for me => it satisfies the ping request
 

+ // XXX + // force sit here instead of unconditionally in the timer event + if (loginPendingForceSit) + { + integer agentInfo = llGetAgentInfo(llGetOwner()); + + loginPendingForceSit = FALSE; + if (!(agentInfo & AGENT_SITTING)) + sendRLCmd ("@sit:"+(string)kSource+"=force"); + } + // end XXX +

            if (!isObjectKnow(id))
            {
                debug("asking for permission because kSource is NULL_KEY");

</lsl>