[Opensim-users] Question; What is the difference between and ASSET and a ITEM

Justin Clark-Casey jjustincc at googlemail.com
Wed Sep 17 23:27:41 UTC 2014


You're correct that usually one would look up the item via the Item ID and then look up the asset via the asset ID in 
the item.

However, in this case both item ID and asset ID are embedded directly.  In the case of NPCs, the item ID is actually 
ignored (and could be zeroed).  The asset IDs are vital since they point to baked textures and attachments.

This is why one needs to clone an existing avatar's appearance for an NPC - for an avatar the viewer has done the work 
of baking and uploading the textures and we simply make those persistent in the database instead of transient.  If we 
had code to bake appearances server-side then this wouldn't be necessary.

On 13/09/14 17:29, Marcus Llewellyn wrote:
> My understanding is that the item ID is used by inventory as a pointer to an asset. Since NPCs don't have an inventory,
> they effectively borrow inventory items from a user. Both the item UUID and the asset UUID are needed for an appearance
> note card to work.
>
> On Sep 13, 2014 11:20 AM, "Thomas Ringate" <tringate at gmail.com <mailto:tringate at gmail.com>> wrote:
>
>     In the appearance notecard for an NPC two UUID’s are listed for each object that is attached, or for wearables.
>     Example:
>     <key>point</key>
>     <integer>8</integer>
>     <key>item</key>
>     <uuid>b9bb4e8f-2ba0-4f02-a47c-2efbfc9b2299</uuid>
>     <key>asset</key>
>     <uuid>5225b537-dc05-4e0b-9a03-23a1990ec5a8</uuid>
>     What is the difference between the “ASSET” and the “ITEM”?
>     I have discovered that if the UUID is present in my asset cache the NPC will rezz without any difficulty but if it
>     is missing, I only will see a cloud, or partial NPC.
>     I have written a php program that decodes the appearance note card, finds the asset in the cache, reads the asset,
>     and then displays what the NPC
>     is made of.  It  displays the name of the object, and allows me to remove attachments or replace them with other
>     attachments.
>     I have identified those textures required as a minimum for an NPC to rezz.  This makes it simpler to delete
>     notecards that will result
>     in a non-displayable NPC.
>     I use this to preprocess appearance note cards to make it faster to only rezz good appearances.
>     Tom
>
>     _______________________________________________
>     Opensim-users mailing list
>     Opensim-users at opensimulator.org <mailto:Opensim-users at opensimulator.org>
>     http://opensimulator.org/cgi-bin/mailman/listinfo/opensim-users
>
>
>
> _______________________________________________
> Opensim-users mailing list
> Opensim-users at opensimulator.org
> http://opensimulator.org/cgi-bin/mailman/listinfo/opensim-users
>


-- 
Justin Clark-Casey (justincc)
OSVW Consulting
http://justincc.org
http://twitter.com/justincc


More information about the Opensim-users mailing list