Scripts Library
- Freda Frostbite
- Posts: 742
- Joined: Sat Mar 29, 2014 2:10 am
- Location: Florida, space coast.
- Has thanked: 608 times
- Been thanked: 769 times
Re: Scripts Library
Darn, it does not seem to work. It does not respond to touching as the script says it will. Any other thoughts?
- Deuce Halsey
- Posts: 322
- Joined: Mon Oct 14, 2013 9:30 pm
- Has thanked: 391 times
- Been thanked: 262 times
Re: Scripts Library
That's odd. It worked for me. I'll send you a copy of my working version in game.
- These users thanked the author Deuce Halsey for the post:
- Freda Frostbite
- Freda Frostbite
- Posts: 742
- Joined: Sat Mar 29, 2014 2:10 am
- Location: Florida, space coast.
- Has thanked: 608 times
- Been thanked: 769 times
- Constance Peregrine
- Posts: 2352
- Joined: Sun Dec 23, 2012 11:35 am
- Has thanked: 2780 times
- Been thanked: 1487 times
Re: Scripts Library
hard to say but good Duece helped ya-))
Laissez faire et laissez passer, le monde va de lui même!
My little sounds store https://www.kitely.com/market?store=2040306
Ephemeral wanderer...
My little sounds store https://www.kitely.com/market?store=2040306
Ephemeral wanderer...
- Constance Peregrine
- Posts: 2352
- Joined: Sun Dec 23, 2012 11:35 am
- Has thanked: 2780 times
- Been thanked: 1487 times
follower
Found this in another item someplace...tested in kitely and should be fun-))
It did not work for me in the merchants sandbox but did on my own land, which is cool, just noting....use your imagination and make cool followers-))
It did not work for me in the merchants sandbox but did on my own land, which is cool, just noting....use your imagination and make cool followers-))
Code: Select all
//Simple Rotation Follower Script
//If this script is set to run, it will turn to match the orientation of the target selected.
// It will perfer to follow the owner
// but if the owner is not there it will pick someone at random within 50 m
// and follow them.
//Based off of scripts by SL Ope Rand & Christopher Omega
// AXIS_* constants, represent the unit vector 1 unit on the specified axis.
vector AXIS_UP = <0,0,1>;
vector AXIS_LEFT = <0,1,0>;
vector AXIS_FWD = <1,0,0>;
vector offset = < -2,2, -0.45>; //1 meter behind and 1 meter above owner's center.
vector roffset=<0,0,0>;
float rspeed =0.4;
integer range=20;
integer nestSize=20;
key lastTargetID;
vector nest;
integer nestDefined = 0;
integer textureChan = 9854;
rotation getRotToPointAxisAt(vector axis, vector target) {
return llGetRot() * llRotBetween(axis * llGetRot(), target - llGetPos());
}
integer legalPos( vector pos)
{
if ((pos.x>5)&&( pos.x<250)&&(pos.y>5)&&( pos.y<250))
{
if (nestDefined==1)
{
if( (pos.x>nest.x-nestSize)&&( pos.x<nest.x+nestSize)&&(pos.y>nest.y-nestSize)&&( pos.y<nest.y+nestSize) )
{
return 1;
}
else
{
return 0; // Not in our nest zone
}
}
else
{
// No Nest Zone Defined
return 1;
}
}
else
{
return 0; // They broke our liberal rules so we're SOOO over with them
}
}
// Strength and damping are values used to control
// how llRotLookAt and llLookAt move, these values are tunable.
float strength = 1.0;
float damping = 0.1250;
default
{
state_entry() {
nestDefined=0;
lastTargetID = llGetOwner();
//Stops it from tipping over
llSetStatus(STATUS_ROTATE_X, FALSE);
llSetStatus(STATUS_ROTATE_Y, TRUE);
llSetStatus(STATUS_ROTATE_Z, FALSE);
llSetStatus(STATUS_PHYSICS, FALSE);
//llSensorRepeat(string name, key id, integer type, float range, float arc, float rate)
//llSensorRepeat("",llGetOwner(),AGENT,60,PI,0.2); //set the last three variables lower/higher to lessen lag
llSensorRepeat("","",AGENT,range,PI,1);
llListen( 0, "", llGetOwner(), "" );
}
on_rez(integer start_param) { llResetScript(); }
listen(integer channelIn, string name, key id, string message)
{
if (llSubStringIndex(message,"NEST") >= 0)
{
nest = llGetPos();
llSay(0,"The range of my Nest is: X( "+ (string)(nest.x-nestSize) + ") to X( "+ (string)(nest.x+nestSize) +
") and y( "+ (string)(nest.y-nestSize)+ ") to y("+ (string)(nest.y+nestSize) +")");
nestDefined=1;
}
if (llSubStringIndex(message,"DENEST") >= 0)
{
nestDefined=0;
}
}
sensor(integer num_detected)
{
// Pick someone at random but perfer the owner and last target
integer target_selected = (integer)llFrand((float)num_detected);
integer i;
for(i = 0; i < num_detected; i++)
{
if ( (llDetectedKey(i)== lastTargetID) && (legalPos(llDetectedPos(i))==1) )
{
target_selected = i; // Go with our existing target if possible
}
if ( (llDetectedKey(i)== llGetOwner()) && (legalPos(llDetectedPos(i))==1) )
{
target_selected = i;
lastTargetID=llGetOwner(); // forget about that passing fad
}
}
//llShout(0, "num_detected "+ (string)num_detected + " target_selected "+ (string) target_selected);
//vector target = llDetectedPos(0);
vector target = llDetectedPos(target_selected);
// This line points the fwd (X) axis at the target:
//llRotLookAt(getRotToPointAxisAt(AXIS_FWD, target), strength, damping);
// llLookAt(llGetOwner(),strength, damping);
// This line points the left (Y) axis at the target:
// llRotLookAt(getRotToPointAxisAt(AXIS_LEFT, target), strength, damping);
// This points the up (Z) axis at the target:
// llRotLookAt(getRotToPointAxisAt(AXIS_UP, target), strength, damping);
// Get position and rotation
vector pos = llDetectedPos(target_selected);
rotation rot = llDetectedRot(target_selected);
vector mypos = llGetPos();
// Offset back one metre in X and up one metre in Z based on world coordinates.
// use whatever offset you want.
vector worldOffset = offset;
// Offset relative to owner needs a quaternion.
vector avOffset = offset * rot;
pos += avOffset+roffset; // use the one you want, world or relative to AV.
//llShout(0, "MoveTo "+ (string)pos + " @ "+ (string) rspeed);
//llMoveToTarget(pos,rspeed);
if (legalPos(pos) ==1)
{
llSetPos(pos);
llSetRot(rot);
}
else
{
lastTargetID = NULL_KEY; // Not in our nest zone
}
llResetScript();
}
}
- These users thanked the author Constance Peregrine for the post:
- Chris Namaste
Laissez faire et laissez passer, le monde va de lui même!
My little sounds store https://www.kitely.com/market?store=2040306
Ephemeral wanderer...
My little sounds store https://www.kitely.com/market?store=2040306
Ephemeral wanderer...
- Constance Peregrine
- Posts: 2352
- Joined: Sun Dec 23, 2012 11:35 am
- Has thanked: 2780 times
- Been thanked: 1487 times
Scrubber
Just saw a basic script isn't here, so, here...
Code: Select all
// The Scrubber v1.3 - Jopsy Pendragon, 8/22/2007
// Just drop this script on a prim that's giving you grief.
// It will reset/unset most persistant prim settings that
// can only be set by scripts and then remove itself.
// This script is in the public domain and may be used freely.
// Please leave this comment block intact if you share this script!
default
{
state_entry()
{
llSetSitText( "" );
llSetTouchText( "" );
llParticleSystem( [ ] );
llSetText( "", ZERO_VECTOR, 1.0 );
llTargetOmega( ZERO_VECTOR, 0, 0 );
llSetCameraAtOffset( ZERO_VECTOR );
llSetCameraEyeOffset( ZERO_VECTOR );
llSitTarget( ZERO_VECTOR, ZERO_ROTATION );
llSetTextureAnim( FALSE , ALL_SIDES, 1, 1, 0, 0, 0.0 );
llStopSound();
llOwnerSay("This Prim is Clean... ");
llRemoveInventory( llGetScriptName() ); // vanish without a trace...
}
}
Laissez faire et laissez passer, le monde va de lui même!
My little sounds store https://www.kitely.com/market?store=2040306
Ephemeral wanderer...
My little sounds store https://www.kitely.com/market?store=2040306
Ephemeral wanderer...
- Carlos Loff
- Posts: 280
- Joined: Sat Dec 28, 2013 8:58 pm
- Location: Lisbon - Portugal
- Has thanked: 263 times
- Been thanked: 191 times
- Contact:
Re: Scripts Library
Great post, great helps, great people, ling live Kitely, thanks
- These users thanked the author Carlos Loff for the post:
- Constance Peregrine
Kitely - Meta Lisbon --> grid.kitely.com:8002:Meta Lisbon Startups
Join Me on Meetup --> https://www.meetup.com/metalisbonstartups/
Join Kitely Group --> Meta Lisbon Startups
Join Me on Meetup --> https://www.meetup.com/metalisbonstartups/
Join Kitely Group --> Meta Lisbon Startups
- Constance Peregrine
- Posts: 2352
- Joined: Sun Dec 23, 2012 11:35 am
- Has thanked: 2780 times
- Been thanked: 1487 times
Balloon Generator
I just left this http://www.giessenict.nl/index.php/nl/o ... -generator at the http://www.kitely.com/virtual-world/Ila ... ts-Sandbox for anyone who wishes to pick up a copy rather than do it yourselves-))
I was just making sure it worked here and just decided to leave it there 'cause it is so pretty and this is http://en.wikipedia.org/wiki/Day_of_the_Dead and you can celebrate the dead [or being dead]!!
I was just making sure it worked here and just decided to leave it there 'cause it is so pretty and this is http://en.wikipedia.org/wiki/Day_of_the_Dead and you can celebrate the dead [or being dead]!!
- These users thanked the author Constance Peregrine for the post:
- Roswenthe Blackwell
Laissez faire et laissez passer, le monde va de lui même!
My little sounds store https://www.kitely.com/market?store=2040306
Ephemeral wanderer...
My little sounds store https://www.kitely.com/market?store=2040306
Ephemeral wanderer...
- Ilan Tochner
- Posts: 6692
- Joined: Sun Dec 23, 2012 8:44 am
- Has thanked: 5164 times
- Been thanked: 4631 times
- Contact:
Re: Scripts Library
Hi Constance,
Leaving items in the Kitely Merchants Sandbox is ill advised. They will be auto-returned within 8 hours at the most (they may be returned sooner if the person who placed them there doesn't remain in that sandbox world).
Leaving items in the Kitely Merchants Sandbox is ill advised. They will be auto-returned within 8 hours at the most (they may be returned sooner if the person who placed them there doesn't remain in that sandbox world).
- These users thanked the author Ilan Tochner for the post:
- Constance Peregrine
- Roswenthe Blackwell
- Posts: 163
- Joined: Sat Mar 29, 2014 10:14 pm
- Has thanked: 76 times
- Been thanked: 158 times
Re: Scripts Library
I picked it up and dropped it (inactive) near the land point at Meddlesome so it doesn't get lost. I also put it in my library.
- These users thanked the author Roswenthe Blackwell for the post (total 2):
- Constance Peregrine • Robert Stanley