Welcome to the Second Life Forums Archive

These forums are CLOSED. Please visit the new forums HERE

Discussion: code I made up to handle texture animations

BigJohn Jade
Registered User
Join date: 5 Aug 2003
Posts: 93
11-16-2006 06:56
The code I made back in 2006 has been update and you can find it here.

http://forums.secondlife.com/showth...593#post1336593
Nada Epoch
The Librarian
Join date: 4 Nov 2002
Posts: 1,423
Original Thread
11-16-2006 08:22
/54/0a/149347/1.html
_____________________
i've got nothing. ;)
Winter Ventura
Eclectic Randomness
Join date: 18 Jul 2006
Posts: 2,579
11-17-2006 18:22
What was wrong with...

CODE

default
{
state_entry()
{
llSetTexture(
"f1298416-d78b-7357-7046-5029ff5730b9", // image filename or UUID
ALL_SIDES // Which side(s)?
);

llSetTextureAnim(
ANIM_ON | LOOP, // Animation settings
ALL_SIDES, // Which side(s)?
4, // frames X
4, // frames y
0, // start frame
0, // number of frames (0 for all)
3.0 // frames per second
);
}
}


or the less handholdy version:

CODE

default
{
state_entry()
{
llSetTexture("f1298416-d78b-7357-7046-5029ff5730b9", ALL_SIDES);
llSetTextureAnim(ANIM_ON | LOOP, ALL_SIDES, 4, 4, 0, 0, 3.0 );
}
}
_____________________

● Inworld Store: http://slurl.eclectic-randomness.com
● Website: http://www.eclectic-randomness.com
● Twitter: @WinterVentura
Xio Jester
Killed the King.
Join date: 13 Nov 2006
Posts: 813
11-18-2006 16:16
I'm a n00b, not a scripting wizard like you guys, but the image filename goes between the quotation marks, separated by commas right?

From: Winter Ventura
llSetTexture(
"f1298416-d78b-7357-7046-5029ff5730b9", // image filename or UUID
ALL_SIDES // Which side(s)?
);

_____________________
~ In Shakespeare, 'Tis The Fool Who Speaks The Most Profound Truth. ~

http://slexchange.com/modules.php?name=Marketplace&MerchantID=37521
Winter Ventura
Eclectic Randomness
Join date: 18 Jul 2006
Posts: 2,579
11-18-2006 16:19
Yeap. filename, or UUID If you had a file that you uploaded, called "box texture" it would look like this:

CODE

default
{
state_entry()
{
llSetTexture(
"box texture", // image filename or UUID
ALL_SIDES // Which side(s)?
);

llSetTextureAnim(
ANIM_ON | LOOP, // Animation settings
ALL_SIDES, // Which side(s)?
4, // frames X
4, // frames y
0, // start frame
0, // number of frames (0 for all)
3.0 // frames per second
);
}
}


or the less handholdy version:

CODE

default
{
state_entry()
{
llSetTexture("box texture", ALL_SIDES);
llSetTextureAnim(ANIM_ON | LOOP, ALL_SIDES, 4, 4, 0, 0, 3.0 );
}
}
_____________________

● Inworld Store: http://slurl.eclectic-randomness.com
● Website: http://www.eclectic-randomness.com
● Twitter: @WinterVentura
Xio Jester
Killed the King.
Join date: 13 Nov 2006
Posts: 813
11-18-2006 16:19
Thanks buddy :cool: :cool:
_____________________
~ In Shakespeare, 'Tis The Fool Who Speaks The Most Profound Truth. ~

http://slexchange.com/modules.php?name=Marketplace&MerchantID=37521
BigJohn Jade
Registered User
Join date: 5 Aug 2003
Posts: 93
09-24-2008 21:47
I know this is old post and just shows I don't hang on forums that much. But the code I did just lets me add it all within one line of code not two lines. My code I made will set the texture as well face number and the settings for the animation. I use it more like sprites then anything. I should had gave more info out on how use it that is for sure but the new update URL does that and thanks.

From: Winter Ventura
What was wrong with...

CODE

default
{
state_entry()
{
llSetTexture(
"f1298416-d78b-7357-7046-5029ff5730b9", // image filename or UUID
ALL_SIDES // Which side(s)?
);

llSetTextureAnim(
ANIM_ON | LOOP, // Animation settings
ALL_SIDES, // Which side(s)?
4, // frames X
4, // frames y
0, // start frame
0, // number of frames (0 for all)
3.0 // frames per second
);
}
}


or the less handholdy version:

CODE

default
{
state_entry()
{
llSetTexture("f1298416-d78b-7357-7046-5029ff5730b9", ALL_SIDES);
llSetTextureAnim(ANIM_ON | LOOP, ALL_SIDES, 4, 4, 0, 0, 3.0 );
}
}