Jump to content

Search the Community

Showing results for tags 'script'.



More search options

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • People Forum
    • Your Avatar
    • Make Friends
    • Lifestyles and Relationships
    • Role Play
    • General Discussion Forum
    • Forums Feedback
    • Missed Connections
    • Second Life Education
  • Places and Events Forum
    • Favorite Destinations
    • Upcoming Events and Activities
    • Games in Second Life
  • Official Contests & Events
    • Leap Into Love Snapshot Contest
  • Creation Forum
    • Fashion
    • Art, Music and Photography
    • Animation Forum
    • Bakes on Mesh
    • Environmental Enhancement Project
    • Machinima Forum
    • Building and Texturing Forum
    • Mesh
    • LSL Scripting
    • LSL Library
    • Experience Tools Forum
    • Sansar for Second Life Residents
  • Technology Forum
    • Second Life Server
    • Second Life Viewer
    • Second Life Web
    • General Second Life Tech Discussion
  • Commerce Forum
    • Merchants
    • Inworld Employment
    • Wanted
  • Land Forum
    • General Discussion
    • Mainland
    • Linden Homes
    • Regions for Sale: Full Private Island
    • Region for Rent: Full Private Island
    • Regions for Sale: Homesteads
    • Region Rentals: Homestead
    • Parcels for Sale: Mainland
    • Parcels for Rent: Mainland
    • Wanted: Full Private Island
    • Wanted: Homesteads
    • Wanted: Mainland
  • International Forum
    • Deutsches Forum
    • Foro en español
    • Forum in italiano
    • Forum français
    • 日本語フォーラム
    • 한국어 포럼
    • Fórum em português
    • Forum polskie
    • المنتدى العربي
    • Türkçe Forum
    • Форум по-русски
  • Adult Content Forum
    • Highlight Upcoming Events
    • General Discussion
    • General Announcements
  • Answers
    • Abuse and Griefing
    • Account
    • Avatar
    • Creation
    • Inventory
    • Getting Started
    • Controls
    • Land
    • Linden Dollars (L$)
    • Shopping
    • Technical
    • Viewers
    • Everything Else
    • International Answers

Blogs

  • Commerce
  • Featured News
  • Inworld
  • Tools and Technology
  • Tips and Tricks
  • Land

Categories

  • English
  • Deutsch
  • Français
  • Español
  • Português
  • 日本語
  • Italiano
  • Pусский
  • Türkçe

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


About Me

Found 222 results

  1. Hello! Someone can create the following script for a small reward 500 ls? I need a script that allows you to simulate tossing the ball in your avatar's hand. the ball must be attached on the avatar, the hand holding the ball, and a tossing animation is triggered through the timer, the ball moves up and down.
  2. Hello! I need to make an object that starts to vibrate when an avatar sits on it and it plays animation. I found such a script of vibration and animation, but how should they be combined together? vibration integer k; integer flip = 1; list params; vector pos; integer link = 0; default { state_entry() { params = llGetLinkPrimitiveParams(link, [PRIM_POSITION]); pos = llList2Vector(params, 0); } touch_start(integer total_number) { if (k = !k) llSetTimerEvent(0.02+llFrand(0.1)); else llSetTimerEvent(0.0); } timer() { llSetLinkPrimitiveParamsFast(LINK_THIS, [PRIM_POSITION, pos + ((flip = -flip) * < 0.02, 0.01, 0.01 > )]); } } animation string animation; // the first animation in inventory will automatically be used // the animation name must be stored globally to be able to stop the animation when standing up default { state_entry() { // set sit target, otherwise this will not work llSitTarget(<0.0, 0.0, 0.1>, ZERO_ROTATION); } changed(integer change) { if (change & CHANGED_LINK) { key av = llAvatarOnSitTarget(); if (av) //evaluated as true if not NULL_KEY or invalid llRequestPermissions(av, PERMISSION_TRIGGER_ANIMATION); else // avatar is standing up { if (animation) llStopAnimation(animation); // stop the started animation llResetScript(); // release the avatar animation permissions } } } run_time_permissions(integer perm) { if (perm & PERMISSION_TRIGGER_ANIMATION) { animation = llGetInventoryName(INVENTORY_ANIMATION,0); // get the first animation from inventory if (animation) { llStopAnimation("sit"); // stop the default sit animation llStartAnimation(animation); } } } }
  3. Hello! I am trying to create a script with something like an alarm that sends me a message when someone comes to visit me in my absence. I managed to write something but its not ok. It sends messages all the time while person in range, and I only need one time alert. and at the same time, if a person leaves the range and comes back, the alarm must be triggered again. how to do it? That's what i managed to write so far float range = 10.0; // in meters float rate = 10.0; // in seconds default { state_entry() { llSensorRepeat( "", "", AGENT, range, TWO_PI, rate ); } sensor( integer number_detected ) { llInstantMessage( llGetOwner(), "ALERT!" ); } }
  4. Hello! A friend gave me a script, but neither she nor I know what it is for. can someone say what the script is and what is it for? (script name: desaparecer despacio) // // USER VARIABLES // // // INTERNAL VARIABLES // vector home; integer penState; float penColor; float color; float ghost; vector originalScale; float sizePercent; integer numAvatarsNearby; vector nearestAvPosition; key ownerKey; vector ownerPosition; // // INTERNAL FUNCTIONS // // move(steps) // move object a number of steps (meters) along its current heading // forward is along the positive x axis // if the pen is down, create a line segment along the path traveled // the line is positioned by its center, which is placed halfway back along the path move(float steps) { vector fwd = llRot2Fwd(llGetRot()) * steps; llSetPos(llGetPos() + fwd); if (penState == TRUE) { if (llGetInventoryType("lineSegment") == INVENTORY_NONE) { llSay(0, "Oops! To draw a line, my inventory needs a lineSegment. You can get one from the Scratch Inventory Box."); } else { integer randomID = llRound(llFrand(99999999)); llRezObject("lineSegment", llGetPos()-fwd/2, <0,0,0>, llGetRot(), randomID); llSay(1, (string)randomID + ":set length:"+ (string)llFabs(steps)); llSay(1, (string)randomID + ":set color:" + (string)penColor); } } } // turnRight(float angle) // turn angle degrees clockwise around the local z axis turnRight(float angle) { angle *= -1; rotation newRot = llEuler2Rot(<0,0,angle> * DEG_TO_RAD); llSetRot(newRot*llGetRot()); } // turnLeft(float angle) // turn angle degrees counterclockwise around the local z axis turnLeft(float angle) { rotation newRot = llEuler2Rot(<0,0,angle> * DEG_TO_RAD); llSetRot(newRot*llGetRot()); } //up(float steps) //move up along the global z axis by steps meters //does not leave a line segment up(float steps) { llSetPos(llGetPos()+<0,0,steps>); } //down(float steps) //move down along the global z axis by steps meters //does not leave a line segment down(float steps) { llSetPos(llGetPos()+<0,0,-1*steps>); } // turnPitch(float angle) // turn angle degrees upward around the local y axis turnPitch(float angle) { angle *= -1; rotation newRot = llEuler2Rot(<0,angle,0> * DEG_TO_RAD); llSetRot(newRot*llGetRot()); } // float getHeading() // return the current heading in the xy plane in degrees float getHeading() { return llRot2Angle(llGetRot())*RAD_TO_DEG; } // setHeading(float angle) // set the heading in the xy plane in degrees setHeading(float angle) { vector newVec = <0, 0, angle*DEG_TO_RAD>; rotation newRot = llEuler2Rot(newVec); llSetRot(newRot); } // turnRoll(float angle) // turn angle degrees clockwise around the local x axis turnRoll(float angle) { rotation newRot = llEuler2Rot(<angle,0,0> * DEG_TO_RAD); llSetRot(newRot*llGetRot()); } // changePenColorBy(float num) // change the pen color by an amount changePenColorBy(float num) { penColor += num; setPenColorTo(penColor); } // setPenColorTo(float num) // set the pen to a particular color setPenColorTo(float num) { penColor = (integer)num % 100; } // penDown() // put the pen down, so that when the object moves it will draw penDown() { penState = TRUE; } // penUp() // put the pen up, so that the object will not draw when it moves penUp() { penState = FALSE; } // clear() // broadcast a message to nearby line segments that will cause them to // delete themselves clear() { llSay(1, "clearLineSegments"); } // pointTowardNearestAv() // turn to point toward the nearest avatar pointTowardNearestAv() { vector myPos = llGetPos(); float xdiff = myPos.x - nearestAvPosition.x; float ydiff = myPos.y - nearestAvPosition.y; float angle = llAtan2(xdiff, ydiff) * RAD_TO_DEG; setHeading(270 - angle); } // pointTowardOwner() // turn to point toward the owner pointTowardOwner() { vector myPos = llGetPos(); float xdiff = myPos.x - ownerPosition.x; float ydiff = myPos.y - ownerPosition.y; float angle = llAtan2(xdiff, ydiff) * RAD_TO_DEG; setHeading(270 - angle); } // float distanceToNearestAv() // returns the distance in meters to the nearest avatar float distanceToNearestAv() { return llVecDist(llGetPos(), nearestAvPosition); } // float distanceToOwner() // returns the distance in meters to the owner float distanceToOwner() { return llVecDist(llGetPos(), ownerPosition); } // float randomMinToMax(float min, float max) // returns a random number between min and max integer randomMinToMax(float min, float max) { return llRound(llFrand(max - min) + min); } // say(string text) // say the text on the public chat channel 0 so all nearby avatars and objects will hear it say(string text) { llSay(0, text); } // broadcast(string message) // say the message on channel 1. No avatars will hear it. // all nearby objects will hear it. broadcast(string message) { llSay(1, message); } // setText(string text) // create opaque white floating text above the object setText(string text) { llSetText(text, <1,1,1>, 1); } // vector hueToRGB(float h) // take a color represented as a hue value between 1 and 100 and // return an RGB vector representing the same color. vector hueToRGB(float h) { integer i; float f; float p; float q; float t; float r; float g; float b; float s = 1; float v = 1; h *= 5; // sector 0 to 5 i = llFloor(h); f = h - i; // factorial part of h p = v * ( 1 - s ); q = v * ( 1 - s * f ); t = v * ( 1 - s * ( 1 - f ) ); if (i == 0) { r = v; g = t; b = p; } else if (i == 1) { r = q; g = v; b = p; } else if (i == 2) { r = p; g = v; b = t; } else if (i == 3) { r = p; g = q; b = v; } else if (i == 4) { r = t; g = p; b = v; } else { r = v; g = p; b = q; } return <r,g,b>; } // setColor(float num) // set the color of the object using a number between 1 and 100 representing a hue setColor(float num) { color = (integer)num % 100; llSetColor(hueToRGB(color / 100), ALL_SIDES); if (llGetObjectName() == "Scratch Bug") { llSetLinkColor(2, hueToRGB(color / 100), ALL_SIDES); } else { //llSetLinkColor(LINK_SET, hueToRGB(color / 100), ALL_SIDES); } } // changeColorBy(float num) // change the hue of the object by a number changeColorBy(float num) { float newColor = color + num; if (newColor < 0) { newColor = 0; } if (newColor > 100) { newColor = 100; } setColor(newColor); } // setGhost(float num) // set the ghost effect of the object to a value between 0 (opaque) and 100 (transparent) setGhost(float num) { ghost = (integer)num % 101; llSetAlpha(((100 - ghost) / 100), ALL_SIDES); llSetLinkAlpha(LINK_SET, ((100 - ghost) / 100), ALL_SIDES); } // changeGhostBy(float num) // change the ghost effect on an object by a number changeGhostBy(float num) { setGhost(ghost + num); } // setSize(float newSize) // set the size of the object to a percentage of its original size setSize(float newSize) { sizePercent = newSize; vector newScale = originalScale*(sizePercent/100); llSetScale(newScale); } // changeSizeBy(float change) // change the size of an object by a percentage of its original size changeSizeBy(float change) { sizePercent += change; vector newScale = originalScale*(sizePercent/100); llSetScale(newScale); } // playSound(string snd) // play a sound at full volume // snd can be the name of a sound in the inventory of the object, or the // UUID of a sound which exists somewhere else playSound(string snd) { llPlaySound(snd, 1); } // playSoundNamed(string snd) // play a sound at full volume // snd can be the name of a sound in the inventory of the object, or the // UUID of a sound which exists somewhere else // this is the version for text input of the name of a sound in a scratch block // so it checks the inventory and gives an error if the sound is missing playSoundNamed(string snd) { if (llGetInventoryType(snd) == INVENTORY_NONE) { llSay(0, "Oops! My inventory does not contain the sound " + snd); } else { llPlaySound(snd, 1); } } // wait(float secs) // pause all execution of this script for some number of seconds wait(float secs) { llSleep(secs); } // levelOut() // remove the x and y rotation components, so that the object is // level with respect to the ground levelOut() { vector myVec = llRot2Euler(llGetRot()); vector newVec = <0, 0, myVec.z>; rotation newRot = llEuler2Rot(newVec); llSetRot(newRot); } // goHome() // move the object back to its home position // home is set the the position of the object when it is created, // and can be set to a new position using setHomeHere() goHome() { llSetPos(home); //levelOut(); } // setHomeHere() // set the home position to the current position setHomeHere() { home = llGetPos(); } // startListening() // listen for messages on both channel 0, the public channel, // and channel 1, where broadcasts are sent startListening() { llListen(0, "", "", ""); llListen(1, "", "", ""); } // initInternal() // do some setup for internal functions // this includes setting various variables to their defaults // clearing text on the object, and turning on // the repeating sensor and timer events initInternal() { setHomeHere(); penState = FALSE; penColor = 0; color = 0; ghost = 0; sizePercent = 100; originalScale = llGetScale(); ownerKey = llGetOwner(); llSetText("", <1,1,1>, 0); llSensorRepeat("", "", AGENT, 96, PI, .1); llSetTimerEvent(.1); startListening(); } initAll() { initInternal(); } timer1(){ wait(15); setGhost(0); wait(0.1); setGhost(0.1); wait(0.1); setGhost(0.3); wait(0.1); setGhost(0.5); wait(0.1); setGhost(1); wait(0.1); setGhost(2); wait(0.1); setGhost(3); wait(0.1); setGhost(4); wait(0.1); setGhost(5); wait(0.1); setGhost(7); wait(0.1); setGhost(10); wait(0.1); setGhost(15); wait(0.1); setGhost(20); wait(0.1); setGhost(25); wait(0.1); setGhost(30); wait(0.1); setGhost(35); wait(0.1); setGhost(40); wait(0.1); setGhost(45); wait(0.1); setGhost(50); wait(0.1); setGhost(55); wait(0.1); setGhost(60); wait(0.1); setGhost(65); wait(0.1); setGhost(70); wait(0.1); setGhost(75); wait(0.1); setGhost(80); wait(0.1); setGhost(85); wait(0.1); setGhost(90); wait(0.1); setGhost(95); wait(0.1); setGhost(96); wait(0.1); setGhost(97); wait(0.1); setGhost(98); wait(0.1); setGhost(99); wait(0.1); setGhost(100); wait(15); setGhost(99); wait(0.1); setGhost(97); wait(0.1); setGhost(95); wait(0.1); setGhost(90); wait(0.1); setGhost(85); wait(0.1); setGhost(80); wait(0.1); setGhost(75); wait(0.1); setGhost(70); wait(0.1); setGhost(65); wait(0.1); setGhost(60); wait(0.1); setGhost(55); wait(0.1); setGhost(50); wait(0.1); setGhost(45); wait(0.1); setGhost(40); wait(0.1); setGhost(35); wait(0.1); setGhost(30); wait(0.1); setGhost(25); wait(0.1); setGhost(20); wait(0.1); setGhost(15); wait(0.1); setGhost(10); wait(0.1); setGhost(7); wait(0.1); setGhost(5); wait(0.1); setGhost(4); wait(0.1); setGhost(3); wait(0.1); setGhost(2); wait(0.1); setGhost(1); wait(0.1); setGhost(0.5); wait(0.1); setGhost(0.3); wait(0.1); setGhost(0); } default { state_entry() { initAll(); } on_rez(integer start_param) { initAll(); } sensor(integer n) { numAvatarsNearby = n; nearestAvPosition = llDetectedPos(0); integer i; for (i=0; i<n; i++) { if (llDetectedKey(i) == ownerKey) { ownerPosition = llDetectedPos(i); } } } touch_start(integer n) { } collision_start(integer n) { } listen(integer channel, string name, key id, string msg) { } timer() { timer1(); } }
  5. Hello! Question to experienced scripters. Has anyone ever worked with RCX flight scripts? I have this Land Light script. Its for the prim cone of light. In the off state it is a small cone but when it is turned on it increases. And I want to redo it into a simple light source (no cone prim). I need to remove all the excess that affects the size of my light source and leave only the turning on/off the parameters of light. What needs to be removed? Can anyone help? /** * @author(s): Reconx86 * @created: 2016.04.12 * * RCX Landing Lights: * A script too manage Landing Lights * * @license: * You are allowed to share this script full-perm with others and even use it in your own projects. * But do not sell the script seperately nor as part of a script package */ integer lLandLight; integer rLandLight; string objName = "landing light"; integer links; integer objTotal; list lstPrimNames; rcxGetNames() { lstPrimNames = []; integer link_nr; integer links = llGetNumberOfPrims(); for (link_nr = 0; link_nr <= links; link_nr++) { lstPrimNames += [llGetLinkName(link_nr)]; } } integer rcxName2Link (string prim_name) { integer link_nr = llListFindList(lstPrimNames, [prim_name]); if (link_nr == -1) { link_nr = llGetListLength(lstPrimNames); llOwnerSay(llGetScriptName() + ": Prim \"" + prim_name + "\" not found"); } return link_nr; } lightsOn(integer num, integer navSide) { list params; params = [ PRIM_GLOW, ALL_SIDES, num * 0.1, PRIM_POINT_LIGHT, num, <1.0, 1.0, 0.0>, //reflection/tint 1.0, 2, 0.5, PRIM_COLOR, ALL_SIDES, <0.0, 0.5, 1.0>, num * 0.07//Light transparancy ]; if (num) {//When lights are turned on this returns TRUE params += [ PRIM_POS_LOCAL, <16.4, navSide * 3.5, -2.64>, PRIM_SIZE, <5.00000, 5.00000, 30.00000> ]; } else {//Executes when lights are turned off params += [ PRIM_POS_LOCAL, <3.9, navSide * 3.5, 0.0>, PRIM_SIZE, <1.00000, 1.00000, 1.00000> ]; } if (~navSide) { llSetLinkPrimitiveParamsFast(lLandLight, params); llSetLinkAlpha(lLandLight, 0.0, 0); } else { llSetLinkPrimitiveParamsFast(rLandLight, params); llSetLinkAlpha(rLandLight, 0.0, 0); } } default { state_entry() { links = llGetObjectPrimCount(llGetKey()); rcxGetNames(); lLandLight = rcxName2Link("RCX Landing Light (Port)"); rLandLight = rcxName2Link("RCX Landing Light (Starboard)"); lstPrimNames = []; } link_message(integer sender, integer num, string msg, key id) { if (msg == "#landing_light") { lightsOn(num, 1); lightsOn(num, -1); llSetScriptState(llGetScriptName(), FALSE); } } }
  6. Hi! Is it possible to animate light texture option in the features tab with script and how? Not just flickering, I want to use gif texture.
  7. Hello everyone, I have 2 questions : My first : Here is the script for opening and closing a door. However, the sound of the opening starts when you click and the closing sound once the door is closed. I would like the closing sound to start during the closing movement and not once closed. My second : Do you think I can add a script in a second prim linked so that the two objects follow the same movement? Can you help me please ? /* * Smooth Rotating Linked Door With Hinge * * By: Lyn Mimistrobell * Version: 1.1 * License: Do whatever you like with it, just don't blame me if you break it :) */ /* * Define the rotation in degrees, using the door prim's local coordinate * system */ vector ROTATION = <0.0, 0.0, 180.0>; /* * Define the position of the virtual hinge; usually this is half the door * prim's width and thickness */ vector HINGE_POSITION = <-0.4, 1.3, 0.0>; /* * Define how fast the door opens, in seconds */ float SECONDS_TO_ROTATE = 1.0; /* * Define after how much time the door should close automatically, in seconds; * set to 0.0 to disable autolmatic closing */ float AUTO_CLOSE_TIME = 10.0; /* * Define a sound that plays when the door starts to open; set to NULL_KEY * for no sound. */ key SOUND_ON_OPEN = "b814a289-a786-ef81-e5df-e0e9b9aeebab"; /* * Define a sound that plays when the door has closed; set to NULL_KEY * for no sound. */ key SOUND_ON_CLOSE = "00429879-654d-7925-9e66-5c1695324e58"; /* * Define the volume of the opening and closing sounds */ float SOUND_VOLUME = 1.0; /* * NORMALLY, THERE IS NO NEED TO CHANGE ANYTHING BELOW THIS COMMENT. IF YOU DO * YOU RISK BREAKING IT. */ integer gClosed; // Door state: TRUE = closed, FALSE = opened rotation gRotationClosed; // Initial rotation of the door (closed) vector gPositionClosed; // Initial position of the door (closed) vector gRotationPerSecond; // The amount to rotate each second doOpenOrClose() { /* * Only perform the rotation if the door isn't root or unlinked */ integer linkNumber = llGetLinkNumber(); if (linkNumber < 2) return; if (gClosed) { /* * Store the initial rotation and position so we can return to it. * * Rotating back purely by calculations can in the longer term cause the door * to be positioned incorrectly because of precision errors * * We determine this everytime before the door is being opened in case it was * moved, assuming the door was closed whilst being manipulated. */ gPositionClosed = llGetLocalPos(); gRotationClosed = llGetLocalRot(); /* * Play the opening sound and preload the closing sound */ if (SOUND_ON_OPEN) llPlaySound(SOUND_ON_OPEN, SOUND_VOLUME); } vector hingePosition = gPositionClosed + HINGE_POSITION * gRotationClosed; /* * Reset the timer and start moving */ llResetTime(); while (llGetTime() < SECONDS_TO_ROTATE) { float time = llGetTime(); if (! gClosed) /* * Invert the timer for closing direction */ time = SECONDS_TO_ROTATE - time; rotation rotationThisStep = llEuler2Rot(gRotationPerSecond * time) * gRotationClosed; vector positionThisStep = hingePosition - HINGE_POSITION * rotationThisStep; llSetLinkPrimitiveParamsFast(linkNumber, [PRIM_ROT_LOCAL, rotationThisStep, PRIM_POS_LOCAL, positionThisStep]); } /* * Set the new state */ gClosed = !gClosed; if (gClosed) { /* * Finalize the closing movement */ llSetLinkPrimitiveParamsFast(linkNumber, [PRIM_ROT_LOCAL, gRotationClosed, PRIM_POS_LOCAL, gPositionClosed]); /* * Play the closing sound and preload the opening sound */ if (SOUND_ON_CLOSE) llPlaySound(SOUND_ON_CLOSE, SOUND_VOLUME); if (SOUND_ON_OPEN) llPreloadSound(SOUND_ON_OPEN); } else { /* * Finalize the opening movement */ rotation rotationOpened = llEuler2Rot(ROTATION * DEG_TO_RAD) * gRotationClosed; vector positionOpened = hingePosition - HINGE_POSITION * rotationOpened; llSetLinkPrimitiveParamsFast(linkNumber, [PRIM_ROT_LOCAL, rotationOpened, PRIM_POS_LOCAL, positionOpened]); /* * Preload the closing sound */ if (SOUND_ON_CLOSE) llPreloadSound(SOUND_ON_CLOSE); /* * Set a timer to automatically close */ llSetTimerEvent(AUTO_CLOSE_TIME); } } default { state_entry() { /* * Assume the door is closed when the script is reset */ gClosed = TRUE; /* * These doesn't change unless the script is changed, calculate them once */ gRotationPerSecond = (ROTATION * DEG_TO_RAD / SECONDS_TO_ROTATE); /* * Preload the opening sound */ if (SOUND_ON_OPEN) llPreloadSound(SOUND_ON_OPEN); } touch_start(integer agentCount) { doOpenOrClose(); } timer() { llSetTimerEvent(0.0); /* * Close the door if it isn't already closed */ if (! gClosed) doOpenOrClose(); } }
  8. I need to create a door that opens only if the avatar holds the key. I have a regular door script, but what to do next? Please, do not bother to answer if you are not a scripter.
  9. Hi! Is it possible to animate light texture option (next to light color window) in the features tab (advanced lighting) with SCRIPT and how? Not flickering or intensity stuff, I want to use animated "gif" texture.
  10. Hello! I have a bubble gum script and I need to change it. I need to link the gum to the rezzed object, remove the animation for the avatar from it and leave only the effect of inflating the bubble and the sound of a pop. In general, so that the chewing gum worked for the rezzed object and not attached for the avatar. please tell me what needs to be changed! Thanks for help! init() { llRequestPermissions(llGetOwner(), PERMISSION_TRIGGER_ANIMATION); llPreloadSound("ff0600f0-d8f4-20f6-52ec-a03bc520fee3"); llSetPos(<0,0,0>); llSetScale(<0,0,0>); } default { on_rez(integer num) { if(llGetAttached()) init(); } state_entry() { if(llGetAttached()) init(); } attach(key id) { init(); } run_time_permissions(integer perm) { if (perm & PERMISSION_TRIGGER_ANIMATION) { llSetTimerEvent(5 + (integer)llFrand(14)); } } timer() { llSetTimerEvent(0.0); llStartAnimation("express_kiss"); float itra; for(itra=0.004; itra<0.06; itra+=0.004) { llSetScale(<itra,itra,itra>); llSetPos(llGetLocalPos()+<0.0007,0.0,0.0>); } llPlaySound("ff0600f0-d8f4-20f6-52ec-a03bc520fee3", 1.0); llStopAnimation("express_kiss"); llSetScale(<0,0,0>); llSetPos(<0,0,0>); llSetTimerEvent(5 + (integer)llFrand(14)); } }
  11. Hello! Im a professional scripter with years of experience that offers a unique scripting service for second life, almost everything can be scripted or modified. Vehicles, breedables, RP systems, gambling, clothing , visuals, HUDs, tools, weapons, etc... Also PHP/SQL for external http server communication with databases. Contact me inworld with your request : Hao Zaytsev ( by notecard if possible ) Please do not reply this message or contact me throught the forum, better inworld! Cheers!
  12. Hello! I need some help please! I'm trying to make a speedometer. Does anyone know what is the actual speed of the flight or walking avatar in the sl? I need to calibrate. I tried two speedometers at the same time they show different numbers. Thank you!
  13. Please advise a good door script without a hinge for vehicle (boat)! what requirements should it meet? Thanks!
  14. Hello! help please to sort out! I'm trying to create a script for the 10 minutes demo rezzed object. what is better to use llSleep or llSetTimerEvent? and what's the difference basically in this case? llSleep seems shorter and simpler. thanks! default { state_entry() { llSleep(600); llDie(); } } or default { state_entry() { llSetTimerEvent(600); } timer() { llDie(); } }
  15. Hello! I'm trying to create a simple unpacker giving all content to the owner on rez and self-deleting. I have reviewed a bunch of scripts but they are all very difficult for a beginner. Please tell me how to start and where to go? that's what i have for now but it dont work... thanks for any help! default { on_rez(integer start_param) { llGiveInventory(llGetOwner(), llGetInventoryName(INVENTORY_OBJECT)); llDie; } }
  16. Hello. I'm VERY new to scripting in SL and I'm trying to create a very simple "secret" dungeon-type stone door, but can't seem to find quite what I'm looking for. Hope someone can help. I'm trying to create a simple, 1 prim rotating door. It's already set to accept a single sitter in a "pushing" position (with AVSitter) and makes the correct sound (4 seconds long) upon the avatar sitting. The only thing I want it to do now...upon sitting as well....is rotate slowly (for 4 seconds in time with the sound), 180 degrees around the Z axis and stop. Sounds pretty simple, but again, I'm totally new so I don't quite know what I'm looking for. I'd appreciate any help. Thank you!
  17. i have a sliding door script but it cannot be linked to other prims, does anyone have or can send me a link to where i can get a sliding door script that can be linked to other objects?
  18. Hello! Please help to combine these two scripts. I am trying to make a script for a linked door without a "hinge". I need to add the closing / opening sensor to the FIRST SCRIPT. Thank's for any help! FIRST SCRIPT (please help to add sensor here) // 2017 Maschinenwerk, Corp. // All Rights Reserved. /* * Define the rotation in degrees, using the door prim's local coordinate * system */ vector ROTATION = <0.0, 0.0, 80.0>; /* * Define the position of the virtual hinge; usually this is half the door * prim's width and thickness */ vector HINGE_POSITION = <-0.8, 0.05, 0.0>; /* * Define how fast the door opens, in seconds */ float SECONDS_TO_ROTATE = 1.0; /* * Define after how much time the door should close automatically, in seconds; * set to 0.0 to disable autolmatic closing */ float AUTO_CLOSE_TIME = 10.0; /* * Define a sound that plays when the door starts to open; set to NULL_KEY * for no sound. */ key SOUND_ON_OPEN = "e5e01091-9c1f-4f8c-8486-46d560ff664f"; /* * Define a sound that plays when the door has closed; set to NULL_KEY * for no sound. */ key SOUND_ON_CLOSE = "88d13f1f-85a8-49da-99f7-6fa2781b2229"; /* * Define the volume of the opening and closing sounds */ float SOUND_VOLUME = 1.0; /* * NORMALLY, THERE IS NO NEED TO CHANGE ANYTHING BELOW THIS COMMENT. IF YOU DO * YOU RISK BREAKING IT. */ integer gClosed; // Door state: TRUE = closed, FALSE = opened rotation gRotationClosed; // Initial rotation of the door (closed) vector gPositionClosed; // Initial position of the door (closed) vector gRotationPerSecond; // The amount to rotate each second doOpenOrClose() { /* * Only perform the rotation if the door isn't root or unlinked */ integer linkNumber = llGetLinkNumber(); if (linkNumber < 2) return; if (gClosed) { /* * Store the initial rotation and position so we can return to it. * * Rotating back purely by calculations can in the longer term cause the door * to be positioned incorrectly because of precision errors * * We determine this everytime before the door is being opened in case it was * moved, assuming the door was closed whilst being manipulated. */ gPositionClosed = llGetLocalPos(); gRotationClosed = llGetLocalRot(); /* * Play the opening sound and preload the closing sound */ if (SOUND_ON_OPEN) llPlaySound(SOUND_ON_OPEN, SOUND_VOLUME); } vector hingePosition = gPositionClosed + HINGE_POSITION * gRotationClosed; /* * Reset the timer and start moving */ llResetTime(); while (llGetTime() < SECONDS_TO_ROTATE) { float time = llGetTime(); if (! gClosed) /* * Invert the timer for closing direction */ time = SECONDS_TO_ROTATE - time; rotation rotationThisStep = llEuler2Rot(gRotationPerSecond * time) * gRotationClosed; vector positionThisStep = hingePosition - HINGE_POSITION * rotationThisStep; llSetLinkPrimitiveParamsFast(linkNumber, [PRIM_ROT_LOCAL, rotationThisStep, PRIM_POS_LOCAL, positionThisStep]); } /* * Set the new state */ gClosed = !gClosed; if (gClosed) { /* * Finalize the closing movement */ llSetLinkPrimitiveParamsFast(linkNumber, [PRIM_ROT_LOCAL, gRotationClosed, PRIM_POS_LOCAL, gPositionClosed]); /* * Play the closing sound and preload the opening sound */ if (SOUND_ON_CLOSE) llPlaySound(SOUND_ON_CLOSE, SOUND_VOLUME); if (SOUND_ON_OPEN) llPreloadSound(SOUND_ON_OPEN); } else { /* * Finalize the opening movement */ rotation rotationOpened = llEuler2Rot(ROTATION * DEG_TO_RAD) * gRotationClosed; vector positionOpened = hingePosition - HINGE_POSITION * rotationOpened; llSetLinkPrimitiveParamsFast(linkNumber, [PRIM_ROT_LOCAL, rotationOpened, PRIM_POS_LOCAL, positionOpened]); /* * Preload the closing sound */ if (SOUND_ON_CLOSE) llPreloadSound(SOUND_ON_CLOSE); /* * Set a timer to automatically close */ llSetTimerEvent(AUTO_CLOSE_TIME); } } default { state_entry() { /* * Assume the door is closed when the script is reset */ gClosed = TRUE; /* * These doesn't change unless the script is changed, calculate them once */ gRotationPerSecond = (ROTATION * DEG_TO_RAD / SECONDS_TO_ROTATE); /* * Preload the opening sound */ if (SOUND_ON_OPEN) llPreloadSound(SOUND_ON_OPEN); } touch_start(integer agentCount) { doOpenOrClose(); } timer() { llSetTimerEvent(0.0); /* * Close the door if it isn't already closed */ if (! gClosed) doOpenOrClose(); } } SECOND SCRIPT (sensor is here) float TIMER_CLOSE = 5.0; integer DIRECTION = -1; // direction door opens in. Either 1 (outwards) or -1 (inwards); integer DOOR_OPEN = 1; integer DOOR_CLOSE = 2; vector originalPos; door(integer what) { rotation rot; rotation delta; vector eul; llSetTimerEvent(0); if (what == DOOR_OPEN) { // llTriggerSound("doorOpen", 1); eul = < 0, 0, 90 * DIRECTION > ; //90 degrees around the z-axis, in Euler form } else if (what == DOOR_CLOSE) { // llTriggerSound("doorClose", 1); eul = < 0, 0, 90 * -DIRECTION > ; //90 degrees around the z-axis, in Euler form } eul *= DEG_TO_RAD; //convert to radians rotation rot = llGetRot(); delta = llEuler2Rot(eul); rot = delta * rot; llSetRot(rot); } default { on_rez(integer start_param) { llResetScript(); } state_entry() { originalPos = llGetPos(); llSensorRepeat("", "", AGENT, 5, PI, 1); } sensor(integer num_detected) { door(DOOR_OPEN); state open_state; } moving_end() { originalPos = llGetPos(); } } state open_state { state_entry() { llSensorRepeat("", "", AGENT, 5, PI, 1); } no_sensor() { door(DOOR_CLOSE); llSetPos(originalPos); state default; } sensor(integer num_detected) {} moving_start() { door(DOOR_CLOSE); state default; } }
  19. Why particles or hovertext remain even if script deleted?
  20. Hello folks, As the title say, i'm looking to be hired as scripter. I know well the Linden Scripting Language (LSL) and many others (especially web languages like PHP, HTML5, ASP.NET with MVC, JavaScript, NodeJS, Angular). If you need, i can also create projects in: C, C++, C#, Delphi, Perl, Python... I have many customers in SL (since approx 3 years) for custom full permissions LSL scripts mainly. I'm available for any small or mediums projects. I speak mainly French but i'm able to tchat in English (No english voice). I'm also good for security and hacking if you need these types of skills. If you are interested to work together, you can contact me directly in-world (UnderFawkes Resident).
  21. Всем привет. Некоторые пользователи тратят деньги или же часами ищут нужные скрипты для создания партиклей. На самом же деле, в клиенте Firestorm имеется специальный редактор, который облегчит вам процесс работы со скриптами.
  22. I am looking for a free or cheap script that will remember the sequence in which linked prims are touched. The reason I need this, is so that I can make a musical instrument that doesn't include songs, but the ability to create your own. There would be a dialog menu that pops up when you click the root prim. It asks you if you would like to record, or record with a loop, And if you choose option 1 you touch all the strings in the order you want them to play in, hit finish in the dialog menu, and it will play once. If you chose option 2, then the recorded sequence will play in a loop until you hit "stop" on the dialog menu. An extra thing I would like is the option to save your favorite sequences into a memory bank that has 10 slots. So you can easily switch to different sequences, allowing you to make a completely custom song. [Edit]: I would also like for sequences to be stored in notecards, along with a variable that sets the length of each note, so that the user can determine how long each note in their sequence will be. Defaulted to a whole note. This is for a prim object in which each string is a separate prim, that contains its own sound in its contents. So there needs to be communication between the linked prims and the root prim in order for this to work.. I am willing to pay for a script that does its job well.
  23. Hi there, I'm looking for a scripter to make an advanced script for an new idea that will create more simplicity for customers, which of course I will not share here :) Since most scripters are working by the hour and nobody can tell me how long it will take, I'm looking for a fixed price for the end product and/or a share in the profits. The script ownership must be exclusive, so no reselling afterwards. I'm used to working with designers/programmers RL and have completed the user story, so the programming will have a clear goal and set end result. Please IM me when you're able and available to take on this job. Thanks in advance, Truelove Infinity
  24. More specifically.... I can't figure out for the life of me what's causing this. I've tried taking everything off aside from what I physically can't remove aaand: This is driving me crazy. Anyone know what to do about this? It only happens when I try to move any direction (turn left, turn right, move forward/back etc). If I stay still, nothing happens. Crouching or jumping doesn't seem to affect it either.
  25. A day and a half ago I logged into SL and was trying to sit on something at my sim, but was unable to. I did not get an error i did not get something saying unable to sit. As soon as my avatar or anyone elses would sit, they would get kicked off the item without prompt. About 10 other people besides myself have looked everywhere for anything off or strange. The only time people can sit is when i disable scripts or when my avatar is not on the sim. I have submitted a ticket to linden labs but they are taking a while and it's making me really anxious. I'm looking to see if anyone has had any experience like this or has any answers because I am completely confused. I have even gone as far as to detached everything from my avatar and it makes no difference.
×
×
  • Create New...