BlueCadetBlueDodgerBlueGreenLimeOrangePinkRedSaddleBrown Thursday, August 28, 2008
Small width layoutMedium width layoutMaximum width layoutMaximum textMedium textSmall text

Openlife Forums

You are here » Learning Center ยป Forums
Openlife Grid Forums
 
  Openlife Forums  Scripting  Openlife LSL Ex...  Give Inventory Script....
Previous Previous
 
Next Next
New Post 4/12/2008 1:42 PM
User is offline Butch
4 posts
Openlife Newbie


Give Inventory Script....  (United States)

Does anyone have a working "Give Inventory" script?

Thanks.

 
New Post 4/17/2008 9:49 AM
User is offline Petrol
38 posts
Openlife Newbie


Re: Give Inventory Script....  (Bulgaria)

There isn't anything inside a "Give Inventory" script other than the llGiveInventory function, which sadly isn't implemented yet.

 
New Post 7/5/2008 8:46 AM
User is offline Osiris
36 posts
Openlife Newbie




Re: Give Inventory Script....  (United States)

here is a working Notecard Giver.....

 

// MULTIPLE NOTECARD GIVER
// WITH FLOATING TEXT
// WARNING-- PERMANENT.  CANNOT BE REMOVED ONCE APPLIED!

//   Gives a note card to a person clicking on it. 
// 
 
string FLOAT_TEXT="TOUCH FOR NOTECARD WITH MORE INFORMATION";
vector FLOAT_COLOR=<0.8, 0.9, 0.0>;
float  FLOAT_ALPHA=1.0;

default
{
    state_entry()
    {
       llWhisper(0, "Ready!");
       llSetText(FLOAT_TEXT, FLOAT_COLOR, FLOAT_ALPHA);
    }

    touch_start(integer total_number)
    {
        //  Find out who clicked, and give them a note card
        key giver;
        giver = llDetectedKey(0);
        string name = llDetectedName(0);
           
        if (giver != NULL_KEY) {
            integer InvNum;
            string NoteName;
            integer NumCards = llGetInventoryNumber(INVENTORY_NOTECARD);
            for (   InvNum = 0; InvNum < NumCards; InvNum++) {
                NoteName = llGetInventoryName(INVENTORY_NOTECARD, InvNum);
                llGiveInventory(giver, NoteName);
            }
        }
    }
}

 
Previous Previous
 
Next Next
  Openlife Forums  Scripting  Openlife LSL Ex...  Give Inventory Script....
Popular Forum Threads
In the past 1 week, we have 44 new thread(s) and 120 new post(s)
The most popular thread has been Where do we come from? Openlife Demographics 07/2008
The most active thread has been GLBT Region?
Privacy Statement | Terms Of UseAll Rights Reserved 2007 Openlifegrid.com