Jump to content

4m x 4m prim on wall somewhere; Want to teleport to "just in front of it" ...


Domitan Redenblack
 Share

You are about to reply to a thread that has been inactive for 4624 days.

Please take a moment to consider if this thread is worth bumping.

Recommended Posts

Sure, stand exacty where you want to teleport to, go to World at the top of the screen and select Create Landmark Here or open the map and select Copy Slurl to paste it on a web page.

For either of these to work the Land will have to have it's Land Point settings set to 'Anywhere'. You can do this in About Land >>> Options or ask the sim owner if they can do it for your area if you do not have access to the About Land controls.

Link to comment
Share on other sites

by script the position is

llGetRegionCorner() + llGetPos() + LocalOffset * llGetRot()

if you don't need gridwide coordinates, drop the region corner.

LocalOffset is the distance and direction from the prim center on the objects local axis. llGetRot spins that around to match its' facing.

Link to comment
Share on other sites

Sorry, all, no. Let me clarify.

I have vendor prims that parcel owners move around. When they are moved or rezzed, they report their location to my net database. I have a HUD to track various things about the vendor prims.

What I want is to have a way to "pop in, in front of the vendor" for my sales agents to check on them etc.

To do this, I need a point 1-2m in front of a given face of the vendor prim. This location would be determined when the vendor reports in regularly.

Simply put: given a flat prim, how do I generate a location x,y,z which is 2m from the center of the given face of the prim?

 

Link to comment
Share on other sites

Void's answer is pretty much all you need for this.  The problem becomes trivial once "the given face" is abandoned in favor of "local offset" -- that is, the desired x, y, z offset from the center of the zero-rotated prim.  As she mentions, the llGetRot() is to maintain that offset relative to any other orientation of the prim.

(In the general case, numbered faces aren't necessarily where you'd expect to find them when a prim acquires or loses cuts, hollow surfaces, etc., so a face-relative script that's supposed to be robust to all that is either horrendously complicated or wrong.)

Link to comment
Share on other sites

lets assume you use a simple box, and the top is the face that's towards the customer displaying watever.

<0.0, 0.0, 1.0> * llGetRot()

is 1m away from the top, and always faces the same direction as the top. if you rotate the object, the point rotates with it.

Link to comment
Share on other sites

You are about to reply to a thread that has been inactive for 4624 days.

Please take a moment to consider if this thread is worth bumping.

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
 Share

×
×
  • Create New...