Jump to content

Inventory giver folder with touch range limit


MadsCook
 Share

You are about to reply to a thread that has been inactive for 489 days.

Please take a moment to consider if this thread is worth bumping.

Recommended Posts

Hello

I am new to LSL scripting. 

I am looking for a script that can deliver all object inside the content tab as in a folder. 

But to be able to get the content you need to be:

1. With-in a a specified distance from object.
2. Be a member of a group

Anyone that can help me? 

Link to comment
Share on other sites

Sounds like a decent first project if you want to figure it out yourself.

 

the main pieces:

31 minutes ago, MadsCook said:

deliver all object inside the content tab as in a folder. 

list inventory;
integer nItems = llGetInventoryNumber(INVENTORY_ALL);
integer i;
for(;i<nItems;++i)
{ inventory+= llGetInventoryName(INVENTORY_ALL,i);
}
llGiveInventoryList(llDetectedKey(0),"Folder name",inventory);
31 minutes ago, MadsCook said:

With-in a a specified distance from object.

if( llVecDist( llDetectedPos(0),llGetPos() )  <  someDistance)
{ // then...
}
31 minutes ago, MadsCook said:

Be a member of a group

Assuming the object is set to the group to check:

if(llDetectedGroup(0))
{  // then...
}

group checking is a bit awkward because you can only check against the ~active group.

Edited by Quistess Alpha
minor things.
  • Like 1
  • Thanks 2
Link to comment
Share on other sites

You are about to reply to a thread that has been inactive for 489 days.

Please take a moment to consider if this thread is worth bumping.

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
 Share

×
×
  • Create New...