Welcome to the Second Life Forums Archive

These forums are CLOSED. Please visit the new forums HERE

Texture Animation question

Innula Zenovka
Registered User
Join date: 20 Jun 2007
Posts: 1,825
10-08-2009 13:17
I have been trying to figure out how to use llSetTextureAnim to make a ghostly figure move along the side of a prim, and I'm almost there, I think.

My prim has an aspect ratio of 1:4. I made a square transparent background in Gimp, divided it into 16 squares, 4x4, and put a an image in the top left hand corner. I then imported it, put it on my prim, and, after a bit of fiddling around, came up with
CODE
default
{
state_entry()
{
llSetTextureAnim(ANIM_ON | SMOOTH | LOOP,3, 1, 4,0, 15, 0.2);
}

}

This is almost the effect I want -- it's the right aspect ratio, anyway, but when the image appears at the start of the sequence it also appears, simultaneously, at the other end of the prim for a moment. So, briefly, I have an image at each end.

How should I adjust either the image or the code to get it working properly?
Osprey Therian
I want capslocklock
Join date: 6 Jul 2004
Posts: 5,049
10-08-2009 14:30
A static-y television I made a few years ago uses a 4x4 grid and is scripted:

llSetTextureAnim(ANIM_ON | LOOP, ALL_SIDES,4,4,0,0,8.0);
Innula Zenovka
Registered User
Join date: 20 Jun 2007
Posts: 1,825
10-09-2009 08:52
From: Osprey Therian
A static-y television I made a few years ago uses a 4x4 grid and is scripted:

llSetTextureAnim(ANIM_ON | LOOP, ALL_SIDES,4,4,0,0,8.0);
Thanks. I'm still getting the same problem, though. I think I understand why it's happening -- as soon as I get to the last frame, the first one starts up and so I get the back half of the old image and the front half of the new one for a moment. I'm not sure how to fix that, though.

Maybe I'm going about it in completely the wrong way. In the event, I'm going to use particles instead to make my ghosts go from a to b -- that gives me a lot more control (or at least I understand what I'm doing rather better). But if anyone could explain, for future reference, where I'm going wrong, I'd be very grateful. I sort of understand llSetTextureAnim but I would like to know more about it.
Osprey Therian
I want capslocklock
Join date: 6 Jul 2004
Posts: 5,049
10-09-2009 19:58
It's hard to say without seeing the texture.