|LSL Portal||Functions | Events | Types | Operators | Constants | Flow Control | Script Library | Categorized Library | Tutorials|
|LSL Feature Request|
|The described function does not exist. This article is a feature request.|
Sends data to a user's viewer, for use in creating a new (unsaved) notecard.
Returns an integer that evaluates to boolean true if the resident was present to receive the notecard (but does not indicate whether the user chose to ignore it, or it was blocked by mute, etc.)
|• key||resident_key||–||Key of the resident to whom the data is sent. Resident's avatar must be in the same sim as the script's object.|
|• string||notecard_name||–||Name to give to the new notecard if it is saved.|
|• string||notecard_desc||–||Text for the notecard's description field.|
|• string||body||–||Text for the notecard's body.|
This would send data to a user's viewer through a new channel, requesting that the viewer open a new notecard and populate its description and contents with the data given. If the user chose to save the notecard, it would go to the inventory "Notecards" folder, and would be given the name provided in the function call. The viewer would be free to prompt the user before displaying the new window, and muting should work as standard for scripted chats and inventory offers.
- This function causes the script to sleep for 1.0 seconds.
- Resident must be connected to the same sim as the script's object.
- Notecard is not automatically saved to the scripted object's inventory. It simply provides another convenient channel for sending data to the user. The sending script also has no way to know whether the user ignored the sent data, or chose not to save the new notecard.
- A significant reason for desiring notecards be creatable by script is for convenient creation of program-formatted text, particularly in a form that a script would then expect to read back. Another benefit would be out-of-band data that the user can save independently without copy/paste from chat history and without contaminating the flow of normal chat. None of these benefits necessarily requires that a new asset be created server-side, and requiring viewer interaction and explicit manual action by the user would provide the necessary protection against SPAMMING the servers with unnecessary asset creation.
- This idea was briefly run past a Linden back in 2006, and was given at least a vague head nod, where other requests were shot down on sight. It was noted that a new communication channel would have to be implemented to the viewer somehow, which was not seen as trivial at the time.
//function integer llNewNotecard( key resident_key, string notecard_name, string notecard_desc, string body );