Welcome to the Second Life Forums Archive

These forums are CLOSED. Please visit the new forums HERE

Looking for pictture loop script:)

WindFairie Rosencrans
Registered User
Join date: 4 Feb 2005
Posts: 72
04-05-2005 15:44
Hi all,
Does anyone have a picture loop script
it makes the slide shoes of the pics possible
when I put the series of the texture images in the contents
displaying them one by one
Saw it in a shop and want to use it myself too.

If anyone can write the script or give me the copy of it,
I d appreciate that,

Good time all!!
Palomma Casanova
Free Dove Owner
Join date: 5 Apr 2004
Posts: 635
04-05-2005 17:03
I think I have one...
_____________________
Palomma
Jeffrey Gomez
Cubed™
Join date: 11 Jun 2004
Posts: 3,522
04-05-2005 17:34
Yeah, I have one. Had to wait until I could log in and retrieve it. :)

Special plug to Ama Omega, for the particle script I still use.

Just put this script and the pictures you want to display in inventory. It uses a particle for lagless smooth transitions.

CODE

// Mask Flags - set to TRUE to enable
integer glow =TRUE; // Make the particles glow
integer bounce = FALSE; // Make particles bounce on Z plan of object
integer interpColor = TRUE; // Go from start to end color
integer interpSize = TRUE; // Go from start to end size
integer wind = FALSE; // Particles effected by wind
integer followSource = FALSE; // Particles follow the source
integer followVel = TRUE; // Particles turn to velocity direction

// Choose a pattern from the following:
// PSYS_SRC_PATTERN_EXPLODE
// PSYS_SRC_PATTERN_DROP
// PSYS_SRC_PATTERN_ANGLE_CONE_EMPTY
// PSYS_SRC_PATTERN_ANGLE_CONE
// PSYS_SRC_PATTERN_ANGLE
integer pattern = PSYS_SRC_PATTERN_ANGLE;

// Select a target for particles to go towards
// "" for no target, "owner" will follow object owner
// and "self" will target this object
// or put the key of an object for particles to go to
//key target="self";
key target="";

// Particle paramaters
float age =5; //how long will particles live (in seconds)
float maxSpeed = 0.01; //maximum speed a particle should be moving
float minSpeed = 0.01; //minimum speed a particle should be movie
string texture=""; //texture applied to the particles
float startAlpha =1.0; //alpha transparency at start
float endAlpha =0.0; //alpha at end
vector startColor = <1,1,1>; //particles start as this color
vector endColor = <1,1,1>; //and end as thiscolor
vector startSize = <3,3,3>; //particles start at this size
vector endSize = <3,3,3>; //and end at this size
vector push = <0,0,0>; //how far to push particles

// System paramaters
float rate = 2; // How fast to emit particles
float radius = 3.0; // Radius to emit particles for BURST pattern
integer count =3; // How many particles to emit per BURST
float outerAngle = 0.0; // Outer angle for all ANGLE patterns
float innerAngle = 0.0; // Inner angle for all ANGLE patterns
vector omega = <0,0,0>; // Rotation of ANGLE patterns around the source
float life = 0;



// Script variables
integer flags;

updateParticles()
{
if (target == "owner") target = llGetOwner();
if (target == "self") target = llGetKey();
if (glow) flags = flags | PSYS_PART_EMISSIVE_MASK;
if (bounce) flags = flags | PSYS_PART_BOUNCE_MASK;
if (interpColor) flags = flags | PSYS_PART_INTERP_COLOR_MASK;
if (interpSize) flags = flags | PSYS_PART_INTERP_SCALE_MASK;
if (wind) flags = flags | PSYS_PART_WIND_MASK;
if (followSource) flags = flags | PSYS_PART_FOLLOW_SRC_MASK;
if (followVel) flags = flags | PSYS_PART_FOLLOW_VELOCITY_MASK;
if (target != "") flags = flags | PSYS_PART_TARGET_POS_MASK;


//llMakeSmoke( 500, 1, 1, 10, 1, "Alien FaceSucker.tga", <0,0,0>);
if (1) { llParticleSystem([ PSYS_PART_MAX_AGE,age,
PSYS_PART_FLAGS,flags,
PSYS_PART_START_COLOR, startColor,
PSYS_PART_END_COLOR, endColor,
PSYS_PART_START_SCALE,startSize,
PSYS_PART_END_SCALE,endSize,
PSYS_SRC_PATTERN, pattern,
PSYS_SRC_BURST_RATE,rate,
PSYS_SRC_ACCEL, push,
PSYS_SRC_BURST_PART_COUNT,count,
PSYS_SRC_BURST_RADIUS,radius,
PSYS_SRC_BURST_SPEED_MIN,minSpeed,
PSYS_SRC_BURST_SPEED_MAX,maxSpeed,
PSYS_SRC_TARGET_KEY,target,
PSYS_SRC_ANGLE_BEGIN,innerAngle,
PSYS_SRC_ANGLE_END,outerAngle,
PSYS_SRC_OMEGA, omega,
PSYS_SRC_MAX_AGE, life,
PSYS_SRC_TEXTURE, texture,
PSYS_PART_START_ALPHA, startAlpha,
PSYS_PART_END_ALPHA, endAlpha
]);
}
}
integer current = 0;
default
{
state_entry()
{
llSetTimerEvent(0.1);
}
timer()
{
llSetTimerEvent(30.0);
integer textures = llGetInventoryNumber(INVENTORY_TEXTURE);
if(current > textures - 1) current = 0;
texture = llGetInventoryKey(llGetInventoryName(INVENTORY_TEXTURE,current));
current += 1;
updateParticles();
}
}
_____________________
---