only problem with that is that the grid that will get the script does not
allow OSfunctions. What is weird is that my script works in some cases.

On Thu, Oct 20, 2011 at 12:35 AM, Fritigern Gothly <
[email protected]> wrote:

> Hmmm... Why not use osTeleportAgent?
> http://opensimulator.org/wiki/OsTeleportAgent
>
> On Thu, Oct 20, 2011 at 9:25 AM, Chris Collins <[email protected]> wrote:
> > I have the following script that is working within SL but does not always
> > work in OpenSim. Sometimes it works other times it does not. Can anyone
> see
> > anything that would be causing issues on Opensim
> > vector DEST = <130, 182, 36>;
> > vector SITPOS = <0,0,0.5>;
> > key gAv;
> >
> > moveTo(vector origin, vector destination ) { // removed jumpdist
> >     float dist = llVecDist(origin, destination);
> >     integer passes = llCeil( llLog(dist/10.0) / llLog(2.0) );
> >     integer i;
> >     list params = [PRIM_POSITION, destination];
> >     for (i=0; i<passes; i++) {
> >         params = (params=[]) + params + params;
> >     }
> >     llSetPrimitiveParams(params);
> > }
> >
> > teleport(key av) {
> >     if (av == NULL_KEY)
> >     {
> >         return;
> >     }
> >
> >     vector origin = llGetPos();
> >     llSetAlpha (0.0, ALL_SIDES);
> >     moveTo(origin, DEST);
> >     // no need to sleep -- llSetPrimParams has 0.2s delay
> >     llUnSit(av);
> >     moveTo(DEST, origin);
> >     llSetAlpha (1.0, ALL_SIDES);
> > }
> >
> > default
> > {
> >     state_entry()
> >     {
> >         llSetClickAction (CLICK_ACTION_SIT);
> >         llSitTarget(SITPOS,llEuler2Rot(<0,0,-90> * DEG_TO_RAD));
> >     }
> >
> >     changed(integer changebits)
> >     {
> >         if (changebits & CHANGED_LINK)
> >         {
> >             gAv = llAvatarOnSitTarget();
> >             if (gAv != NULL_KEY)
> >             {
> >                 teleport(gAv);
> >             }
> >         }
> >     }
> > }
> > _______________________________________________
> > Opensim-dev mailing list
> > [email protected]
> > https://lists.berlios.de/mailman/listinfo/opensim-dev
> >
> >
>
>
>
> --
> -- Friti
> _______________________________________________
> Opensim-dev mailing list
> [email protected]
> https://lists.berlios.de/mailman/listinfo/opensim-dev
>



-- 
-- 
Chris Collins
CEO
Tipodean Technologies
+1 415-515-6928 | [email protected]
Skype: cozza13 | SL: Chris Collins
Website: www.tipodean.com
Twitter: http://www.twitter.com/tipodean
http://www.linkedin.com/in/collinschris
http://www.builtbuy.me
Tools for your distributed workforce
_______________________________________________
Opensim-dev mailing list
[email protected]
https://lists.berlios.de/mailman/listinfo/opensim-dev

Reply via email to