Welcome to the Second Life Forums Archive

These forums are CLOSED. Please visit the new forums HERE

get texture offset?

paulie Femto
Into the dark
Join date: 13 Sep 2003
Posts: 1,098
10-10-2005 16:40
I start a texture slide animation with:
llSetTextureAnim(ANIM_ON | SMOOTH | LOOP, 3, 0,0, 0, 0, .05);

I see the texture sliding. The TEXTURE edit box also confirms that the texture's horizontal offset is changing. I can click the texture and watch the horizontal offset numbers changing.

The problem I have is that I cant seem to READ the texture's current horizontal offset in my script.

Ive tried using llGetTextureOffset, like this:

vector offset=llGetTextureOffset(3);

(im reading side 3. yes, ive confirmed this is the correct side.)

the vector I get back is always <0.0, 0.0, 0.0>

******************************************

Ive tried llGetPrimitiveParams, like this:

list mylist = llGetPrimitiveParams([PRIM_TEXTURE, 3]);
vector offset = llList2Vector(mylist,2);

to read the 2nd element (offsets) of the texture on the 3rd face.

the vector I get back is always <0.0,0.0,0.0>


Can someone point me to what Im doin wrong? Thanks!
_____________________
REUTERS on SL: "Thirty-five thousand people wearing their psyches on the outside and all the attendant unfettered freakishness that brings."
DoteDote Edison
Thinks Too Much
Join date: 6 Jun 2004
Posts: 790
10-10-2005 17:28
llSetTextureAnim() is a client-side effect, and I imagine that llGetTextureOffset() is grabbing the offsets as listed on the server. So, your client knows the texture offsets, but the server still thinks they're at <0.0, 0.0, 0.0>.