Hope this isnt too simple a question. I am a scripting novice.
Heres the telport script I was working with (it was freebie):
key lastAVkey = NULL_KEY;
string fltText = "Go downstairs";
vector dest = <47.633,23.086,43.830>;
init()
{
llSetSitText("Teleport"
;llSetText(fltText, <1,1,1>, 1);
llSitTarget(dest-llGetPos(), <0,0,0,1>
;}
default
{
state_entry()
{
init();
}
touch_start(integer i)
{
init();
}
changed(integer change)
{
key currentAVkey = llAvatarOnSitTarget();
if (currentAVkey != NULL_KEY && lastAVkey == NULL_KEY)
{
lastAVkey = currentAVkey;
if (!(llGetPermissions() & PERMISSION_TRIGGER_ANIMATION))
llRequestPermissions(currentAVkey,PERMISSION_TRIGGER_ANIMATION);
llSleep(0.5);
llUnSit(currentAVkey);
llStopAnimation("sit"
;llResetScript();
}
}
}
