Difference between revisions of "LlRequestMoney"

From Second Life Wiki
Jump to navigation Jump to search
(created function)
 
m (forgot message parameter)
Line 31: Line 31:
     {
     {
         llGiveInventory(llDetectedKey(0),content);  // Give the Resident the free content
         llGiveInventory(llDetectedKey(0),content);  // Give the Resident the free content
         llRequestMoney(llDetectedKey(0),creator,50); // Request the Resident donate L$50  
         llRequestMoney(llDetectedKey(0),creator,50,"To support future content"); // Request the Resident donate L$50  
     }
     }
}
}
</lsl>
</lsl>
}}
}}

Revision as of 19:43, 5 January 2008

Emblem-important-yellow.png LSL Feature Request
The described function does not exist. This article is a feature request.

Summary

Function: llRequestMoney( key source, key destination, integer amount, string message );

Sends a request to agent source that they give L$ amount to agent destination, possibly for the reason specified in message The resulting notification should also indicate which object and agent that initiated request

• key source The Resident who the money is being requested from
• key destination The intended recipient of the money
• integer amount number of L$, must be greater than zero
• string message Useful for indicating why the money is being requested

Examples

<lsl> // Free content vendor with donation request // The vendor can be placed around the grid // The vendor doesn't have to be owned by the creator string content = "Free Shirt"; key creator = "83b3987f-9520-4275-8efe-3ac13dd3f635"; default {

   touch_start(integer touched)
   {
       llGiveInventory(llDetectedKey(0),content);   // Give the Resident the free content
       llRequestMoney(llDetectedKey(0),creator,50,"To support future content"); // Request the Resident donate L$50 
   }

}

</lsl>

Deep Notes

Signature

//function void llRequestMoney( key source, key destination, integer amount, string message );