Using Warpos to get higher than 300m
|
|
Kether Farshore
Registered User
Join date: 9 Apr 2009
Posts: 9
|
05-19-2009 21:24
Ok im trying to make a script that will allow me to TP to my skybox set at 500m. I'm looking into the warpos script to do this and was studying the code at: http://lslwiki.net/lslwiki/wakka.php?wakka=LibraryWarpPoshowever, I'm still a bit confused. Does using warpos require a clear straight line up to your destination? also, where do you enter the final destination coordinates in that script? I dont see the x, y, z values anywhere. or am I not reading the script correctly? thanks
|
|
Hewee Zetkin
Registered User
Join date: 20 Jul 2006
Posts: 2,702
|
05-19-2009 21:51
It doesn't require a clear, straight line in terms of whether there are objects in the way, but it requires a clear, straight line of parcels over which to pass. If there is a parcel with object entry turned off between the start and end points, it may have a problem. If you are going straight up without crossing any parcel boundaries then that shouldn't be a problem, of course. Oh, and the destination is given as the single parameter to the function, so what you do is call the function with the destination position in region coordinates. See http://www.lslwiki.net/lslwiki/wakka.php?wakka=vector
|
|
Viktoria Dovgal
…
Join date: 29 Jul 2007
Posts: 3,593
|
05-19-2009 21:58
From: Kether Farshore however, I'm still a bit confused. Does using warpos require a clear straight line up to your destination? Yes and no =) It will move through other objects just fine. It can pass between full parcels fine too, as long as an avatar is sitting on the object. It can't pass through ban lines. It (like any other kind of movement) is risky across sim borders. To deal with the full parcel problem and other nasties that might eat and object that tries to return home, many warppos teleporters use a disposable platform. Rez a new platform for the trip, and the platform uses llDie on itself once the avatar stands up. For the ban line problem, a simple bent path works pretty well. vector oldPos = llGetPos(); // starting location vector newPos = <20.0, 100.0, 2500.5>; // where in the sim we want to go if (oldPos.z < 800.0) { // below potential ban lines? They can go up to 768m warpPos(<oldPos.x, oldPos.y, 800.0>); } if (newPos.z < 800.0) { // how about our destination? warpPos(<newPos.x, newPos.y, 800.0>); } warpPos(newPos); // go there for real
|
|
Void Singer
Int vSelf = Sing(void);
Join date: 24 Sep 2005
Posts: 6,973
|
05-20-2009 00:38
you can totally use warppos to run around parcels. it's jumpPos that wonlt do it directly (but you can use multiple jumpPos sets to do it) but since your skybox is only 500m away you can uses corner aligned sit teleport vPosOffset = <1,1,1> vPosTarget = <target in region coordinates> - llGetPos(); if (llVecMag( vPosTarget ) <= llVecMag( <300.0, 300.0, 300.0> )){ llSetRot( llRotBetween( vPosOffset, vPosTarget - llGetPos() ) ); //-- sit target uses magnitute rotated to align through <1,1,1> }else{ // too far }
(too tired to do all the math but that's i mostly.)
_____________________
| | . "Cat-Like Typing Detected" | . This post may contain errors in logic, spelling, and | . grammar known to the SL populace to cause confusion | | - Please Use PHP tags when posting scripts/code, Thanks. | - Can't See PHP or URL Tags Correctly? Check Out This Link... | - 
|
|
Viktoria Dovgal
…
Join date: 29 Jul 2007
Posts: 3,593
|
05-20-2009 01:10
From: Void Singer you can totally use warppos to run around parcels. it's jumpPos that wonlt do it directly (but you can use multiple jumpPos sets to do it) PosJump is the one that can sail through ban lines, that's the overflow exploit LL wants to kill. warpPos is the one that needs to bend around ban lines, I have the dented prims to prove it. All the legs of the bent trip could be stuffed into one llSetPrimitiveParms but that's a little dicey on the memory side of things.
|
|
Void Singer
Int vSelf = Sing(void);
Join date: 24 Sep 2005
Posts: 6,973
|
05-20-2009 01:57
From: Viktoria Dovgal PosJump is the one that can sail through ban lines, that's the overflow exploit LL wants to kill.
warpPos is the one that needs to bend around ban lines, I have the dented prims to prove it. All the legs of the bent trip could be stuffed into one llSetPrimitiveParms but that's a little dicey on the memory side of things. I wasn't aware jumpPos would walk through banlines or no object entry, though I expected it'd ignore no script intevening parcels
_____________________
| | . "Cat-Like Typing Detected" | . This post may contain errors in logic, spelling, and | . grammar known to the SL populace to cause confusion | | - Please Use PHP tags when posting scripts/code, Thanks. | - Can't See PHP or URL Tags Correctly? Check Out This Link... | - 
|
|
Viktoria Dovgal
…
Join date: 29 Jul 2007
Posts: 3,593
|
05-20-2009 20:04
Yep, the sim sees you at the starting and ending points, there doesn't appear to be a path in between, you are just there like *poof*. One cool side effect in a teleporter, the avatar can look like Mr. Fantastic/Elastigirl for a moment on longer jumps.
|
|
Void Singer
Int vSelf = Sing(void);
Join date: 24 Sep 2005
Posts: 6,973
|
05-21-2009 00:31
From: Viktoria Dovgal Yep, the sim sees you at the starting and ending points, there doesn't appear to be a path in between, you are just there like *poof*. One cool side effect in a teleporter, the avatar can look like Mr. Fantastic/Elastigirl for a moment on longer jumps. lol that's too funny... so if you had land on either side of a 8m strip of no object entry, no script, banlines, whatever. you could jump it with a normal move? that's actually neat to know, as I had always thought there was at least some intermediate calculation.
_____________________
| | . "Cat-Like Typing Detected" | . This post may contain errors in logic, spelling, and | . grammar known to the SL populace to cause confusion | | - Please Use PHP tags when posting scripts/code, Thanks. | - Can't See PHP or URL Tags Correctly? Check Out This Link... | - 
|
|
Kether Farshore
Registered User
Join date: 9 Apr 2009
Posts: 9
|
05-22-2009 14:23
thanks for all your help guys.
my skybox is right above my house at 500m so there shouldnt be any problem with permissions or ban lines.
Will give it a try once more time...
|
|
Kether Farshore
Registered User
Join date: 9 Apr 2009
Posts: 9
|
05-25-2009 18:28
Ok I tried both solutions offered by Void and Viktoria.
Both give me a syntax error at the first vPos line. What am I doing wrong?
also, what is this pnp line?
sorry, I'm still new to scripting..
|
|
Void Singer
Int vSelf = Sing(void);
Join date: 24 Sep 2005
Posts: 6,973
|
05-25-2009 21:23
neither of those is a full script, they are code fragments meant to go into a larger script as for the [/php] and tags... if you see them, ignore them, or better yet check out the link below my post, to enable them to WORK and show indented code (SL forums are currently crippled to disable most formatting in posts, the link below leads you to stuff that will reenable it for you only, along with links and and basic text formatting)
_____________________
| | . "Cat-Like Typing Detected" | . This post may contain errors in logic, spelling, and | . grammar known to the SL populace to cause confusion | | - Please Use PHP tags when posting scripts/code, Thanks. | - Can't See PHP or URL Tags Correctly? Check Out This Link... | - 
|
|
Kether Farshore
Registered User
Join date: 9 Apr 2009
Posts: 9
|
05-26-2009 09:56
Thanks Void. Gonna read that link now..
|