Welcome to the Second Life Forums Archive

These forums are CLOSED. Please visit the new forums HERE

Give Script

Morgaine Alter
dreamer
Join date: 10 Jan 2008
Posts: 1,204
10-02-2009 12:44
what script would I need hat would give one a texture when they find a cube and touch it?
The standard one didnt work for me, maybe because its not a prim object?
_____________________
https://www.xstreetsl.com/modules.php?name=Marketplace&MerchantID=125705

From: Phil Deakins
My zip gun stays right where it belongs - in my pants!
Destiny Niles
Registered User
Join date: 23 Aug 2006
Posts: 949
10-02-2009 12:51
Just a guest but your script is probally reading the inventory names using the llGetInventoryName function http://wiki.secondlife.com/wiki/LlGetInventoryName

Change the type from INVENTORY_OBJECT to INVENTORY_TEXTURE
Rolig Loon
Not as dumb as I look
Join date: 22 Mar 2007
Posts: 2,482
10-02-2009 12:56
Assuming that you want to give someone a texture that is in your object's inventory, try something simple like this, and then add bells and whistles to it as necessary .....

CODE

default
{
touch_start(integer num)
{
llGiveInventory(llDetectedKey(0),llGetInventoryName(INVENTORY_TEXTURE,0));
}
}


ETA: Pffffttt... The forum jams a space into the word "Name". Take it out before you use the script.
_____________________
It's hard to tell gender from names around here but if you care, Rolig = she. And I exist only in SL, so don't ask.... ;)

Look for my work in XStreetSL at
Morgaine Alter
dreamer
Join date: 10 Jan 2008
Posts: 1,204
10-02-2009 13:02
thank you all
I did have to change the wording to give texture :)
_____________________
https://www.xstreetsl.com/modules.php?name=Marketplace&MerchantID=125705

From: Phil Deakins
My zip gun stays right where it belongs - in my pants!