Attachment Protocols
From OpenSimulator
Contents |
Introduction
WIP: These are rough notes on some aspects of attachments - will be filled out as time goes on -- Justincc 22:50, 4 April 2013 (UTC)
On login, the simulator sends information to the viewer about the current attachments and rezzes them attached to the avatar in the region. This information is pulled from the avatar service.
On viewers without a "Current Outfit" folder (version 1 viewers and some version 2 viewers), this is the primary way in which a viewer is notified as to what is attached.
On viewers that do have a "Current Outfit" folder, they will request
Protocol
Below is a list of the UDP messages involved in attachment manipulation that flow between the viewer and the simulator. This list may not be complete.
Direct UDP messages
ObjectAttach
Viewer -> Simulator. Attachment an object in the scene.
ObjectDetach
Viewer -> Simulator. Detach an attachment into the user's inventory.
ObjectDrop
Viewer -> Simulator. Detach an attachment into the scene.
RezSingleAttachmentFromInv
Viewer -> Simulator. Attach an object from the user's inventory.
RezMultipleAttachmentsFromInv
Viewer -> Simulator. Rez multiple attachments at once from the user's inventory.
Associated UDP messages
KillObject
Simulator -> Viewer. Sent by the simulator to tell the viewer that an object has been detached. For a V3 viewer, this will trigger a subsequent RemoveInventoryItem to remove the item's link in the Current Outfit folder.
ObjectUpdate
Simulator -> Viewer. Tells the viewer about the properties of the new attachment (position, attachment point, etc.). Also conveys the attachment point, the position and which item this attachment comes from (if appropriate).
UpdateCreateInventoryItem
Simulator -> Viewer. Tells the viewer that a new inventory item is present for a newly received attachment. For a V3 viewer, this will trigger a further LinkInventoryItem message to create a link for that item in the Current Outfit folder.