Jump to content

Weasho

Resident
  • Posts

    11
  • Joined

  • Last visited

Reputation

0 Neutral

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

  1. Thanks. Only looking to mirror prims of all shapes and sizes. I know that none symetrical mesh objects can not be mirrored due to that they already have a defined shape. Not in such a great need that I would lay that many lindens on a script.
  2. Hello, I've previously and recently tried to find a mirroring script for second life that works. So far the so claimed "mirroring" doesn't mirror, but simply turns the objects 180 degrees. A mirrored object is way different from something just turned around. Example Image With unsymetrical mesh objects and or just simple boxes that you want mirrored against eachother, the oposite of x y and z combined is a tricky thing to calculate. At least for me, and seemebly for many others as I've not found a propper code to mirror objects as though they were flipped twin copies. If anyone knows how ot make or have a script or the calculation for flipping an object as if seen in a mirror. I know that mesh objects can not be flipped as such, only need it to work for boxes. -- Thanks
  3. As the llSetLinkAlpha is shorter all in all I'll save some bytes on the bunny head if I use it. ;p Thanks, though I do like it in sync. In my next script idea, probably after I get the texture scroll/zoom/rotate script to work. I'll probably lose my mind trying to figgure stuff out. Hopefully eventually I'll be able to help out rather than get help ;p Cheers :-)
  4. Big thanks, it works now! :-) I had to use llGetLinkNumber to get each of the eyes IDs and then I made the fadein() and fadeout() do the same command on each eye at the same time. In action on my bunnyface. Well, my girlfriends mask that is. Mine needs to be redone, it is a cat one. float delay = 0.03; float i; float j;fadeout(){ for (i = 2; i > 0; i--) { llSetLinkAlpha(1, (i/2), ALL_SIDES); llSetLinkAlpha(12, (i/2), ALL_SIDES); llSleep(delay); } llSetLinkAlpha(1, 0, ALL_SIDES); llSetLinkAlpha(12, 0, ALL_SIDES);}fadein(){ for (j = 0; j < 2; j++) { llSetLinkAlpha(1, (j/2), ALL_SIDES); llSetLinkAlpha(12, (j/2), ALL_SIDES); llSleep(delay); } llSetLinkAlpha(1, 1, ALL_SIDES); llSetLinkAlpha(12, 1, ALL_SIDES);}default{ state_entry() { llSetTimerEvent(1); } timer() { fadein(); float rval = llFloor(llFrand(6)) + 2.0; llSleep(rval); fadeout(); }} * Script credits and original script link are both mentioned in my first post. * The delay between each blink isn't perfect and neither is the blinking. I may tweak it to go between 100% opacity to 0% without a fade effect. But I believe it looks good now. :-) * May tweak the closed eyes position, but I believe it looks good as it is. * I hope I'm not the only one who ends up finding a good use for this. Some script description(for curious searchers): * In the script llSetLinkAlpha is used, if you are wondering about the llSetLinkAlpha(1, and 12, parameters they are link IDs to specific objects. To the number of these give the object you need the ID from the script bellow and it should tell you the number you require in a chat message. //Reference link: http://wiki.secondlife.com/wiki/LlGetLinkNumber default { touch_start(integer total_number) { llOwnerSay((string) llGetLinkNumber()); } } * The fadein() {*} is a function called by using fadein() , the same goes for fadeout() * To make blinking eyes I disguiced closed eyes with opened eyes and made the opened eyes fade away to reviele the closed ones. Simple. You could also use a texture animation to achive this and/or other methods. It is all up to what you prefer. Putting searchwords in here for future searches: blinking eyes, blink effect, linked script, fade in, fade out, eyes Edit: Adding description to script.
  5. On that note I assume I can just run two lines of script with the same variables except for the link number and both eyes should get synced. Well, there is something I missed as I do not understand how the link numbers work, what they are or how to get them. Thanks!
  6. Hello again SL-forums, I've encountered a new problem when scripting. I'm trying to create a "mask" or "helmet" using various blocks and textures I've built. I've layered two pairs of eyes, one pair closed and one pair opened and then attempted putting a script on them to make it look as if they were blinking eyes with a random interval. The problem is that using iiSetAlpha or iiSetLinkedAlpha will, when linked, both interact with all objects linked in the "group" and ruin the purpose. However I modded a script I found which used the llSetAlpha (ops wrote, ii earlier) with llSetPrimitiveParms([PRIM_COLOR... etc instead. This allowed me to have one object blink without effecting everything in the linked group. I've checked through some linking and communication script examples but I can't manage to utilize either to what I need them for. I need two eyes to communicate so that both blink at the same time. I've got an idea of how it could work, 1. Invis object 2. two eyes. 3. Invis objects says "blink" to both eyes. 4. Eyes react with the "blink"-command. 5. ~dance at result~ float delay = 0.03; float i; float j; fadeout() { for (i = 2; i > 0; i--) { llSetPrimitiveParams([PRIM_COLOR, ALL_SIDES, llGetColor(0), (i/2)]); llSleep(delay); } llSetPrimitiveParams([PRIM_COLOR, ALL_SIDES, llGetColor(0), 0]); } fadein() { for (j = 0; j < 2; j++) { llSetPrimitiveParams([PRIM_COLOR, ALL_SIDES, llGetColor(0), (j/2)]); llSleep(delay); } llSetPrimitiveParams([PRIM_COLOR, ALL_SIDES, llGetColor(0), 1.0]); } default { state_entry() { llSetTimerEvent(1); } timer() { fadein(); float rval = llFloor(llFrand(6)) + 2.0; llSleep(rval); fadeout(); } } This is a modification of a script, original script was made by LoganBauer at sluniverse.com and can be found here. If I've missed some posts when searching and you know the link to these, please share if it isn't too much trouble. Thanks in advance, - Bombo
  7. Thanks bigtime for the help :-) In my "rest" I thought I'd tackle gf's bunny-head-block that I'm making. Encountering new problems in an eye-blink script there. Won't include that problem in this thread, but will make a reference link if I can't figgure out how to solve it. Additionally I'll update this thread once and if I manage to make the desired animation for the surface I want to mod. May end up thinking the texture file-size is too large and drop the attempt though. Depends on the detail of the animation of corse. Cheers!
  8. Stopping here for now as mind is spinning too much. Will need to check more references later. First some food and a break. ;p Thanks in advance to whoever may decide to look into this with me or/and help out. :-) cheers.
  9. Ty for the reply. There is a scale function too, I've checked through the functions. I just do not know how and if you can use several together. If not isn't it possible to make an animation-loop where it simulates frames where each frame has their own settings and creating smooth movement with a FPS calculation to count frames? I've got no clue how to put it together but, just a theory. * FPS calculatin according to how long you want animation. 5 sec at 29 fps, 5*29 , each frame having a delay between eachother of 1.0/29 ( where the result is put on a timer ) * Variables that change and reset throught a loop to create the smooth moving animation. # Am attempting to write as much as I can and can learn # The code is a WIP, I'm just posting where I am atm for comments and possible assistance. //settings,etc.integer length=5;integer fps=24;float turn=1.0; // 1 * #turn = 1 * 360 degrees over #framesfloat sizex=1;float sizey=1;//auto-set varsinteger frames=;float delay=;integer frame=1;float angle=;//calc delaysframes=length*fpsdelay=1.0/fpsangle=1/(frames+frame);llSetTextureAnim( // a FUNCTION that requires the following PARAMETER list: (0 // option list: use // to disable any you do not want. // | ANIM_ON // Disable this line to turn off animations. | LOOP // repeat animation over and over. - almost always needed // | REVERSE // animate in opposite direction. //| PING_PONG // reverses completed animation back to starting point //| SMOOTH // disables flip-book style 'frames' animation | ROTATE // spins texture instead of offsetting it // | SCALE // zoom/shrinks texture instead of offsetting it. ), ALL_SIDES, // One face number or ALL_SIDES. 0=top, 1=side, 2=bottom,... depending on shape. sizex,sizey, // Grid Size, for 'frames' style animation, X frames wide, by Y Frames tall. angle, // START: first frame, or first offset, scale or rotation angle. TWO_PI, // LENGTH: # of frames to show, distance to offset or scale, use TWO_PI for ROTATE! 0 // "frames per second" smaller = slower ); // End of the PARAMETER list for the llSetTextureAnim() FUNCTION.default{ state_entry() { llSetTimerEvent(delay); llResetTime(); } timer() { }} ~shakes head~ Need to experiment with minor loops first. Trying to add angles, size changes as well as scroll values before I even know any of the code. ;p
  10. Hello there, I'm attempting to make a sort of 60s/Austin power-ish animation on a texture for a mask I'm experimenting on. I've not got nearly enough understanding on the scripting subject but experimented some. After looking at some codes I only came as far as to rotate it. If anyone could help make anything that looks something like; An image : http://i46.tinypic.com/2lnygcg.gif The code I have so far is pretty basic. default { state_entry() { llSetTexture("test_texture", ALL_SIDES); llSetTextureAnim(ANIM_ON | LOOP | ROTATE | SMOOTH, ALL_SIDES, 1, 1, 1, TWO_PI, 0.5); } } Thank you,:cathappy: Weasho. # Progress and logical conclutions updates! :3 Need: * Functions for rotation angle, size and texture positioning that can be called throught the looping through the script. * Calculations dependent frames/current frame. * A certain confirmation if it is impossible to do this or not. Have: * Not much, trying to create a rotation loop first.
×
×
  • Create New...