Charity Donation Box Script -

Thread Started By YoungMoney

3254
0
  • 38 Vote(s) - 3.11 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Rate Thread
#1
All money paid into Donation Box is paid to a specific avatar set in script. Change the avatar key at top of script. This avatar will be sent all money paid.Set the script to No Modify before giving it to others so they cannot change key.

Code:
// Charity Donation Box Script - by Alicia Stella // ------------------------------------------------ /////////// SETTINGS //////////////////// key thereceiver = "00000000-0000-0000-0000-000000000000"; //key of avatar to receive all funds string thanks = "Thank you for the donation!"; string floattext = "Donation Box";
///////// BEGIN SCRIPT //////////////////

integer totaldonated; default { on_rez( integer sparam ) { llResetScript(); } state_entry() { llSetText("Waiting for Owner\nto Grant Pay Perms",<1,1,1>,1); llRequestPermissions(llGetOwner(),PERMISSION_DEBIT); } touch_start(integer total_number) { if ( llDetectedKey(0) == llGetOwner() ) { llRequestPermissions(llGetOwner(),PERMISSION_DEBIT); } } run_time_permissions(integer perm) { if(perm & PERMISSION_DEBIT) state ready; } } state ready { on_rez( integer sparam ) { llResetScript(); } state_entry() { llSetPayPrice(PAY_DEFAULT, [25, 50, 100, 500]); llSetText(floattext + "\nL$0 Donated so far",<1,1,1>,1); } money(key id, integer amount) { totaldonated = totaldonated + amount; llSetText(floattext + "\nL$" + (string)totaldonated + " Donated so far",<1,1,1>,1); llGiveMoney(thereceiver, amount); llInstantMessage(id, thanks); } }
Reply




Possibly Related Threads…
Thread Author Replies Views Last Post
  Donation box (goal and progress) steadymobbin 1 2,749 02-13-2017, 06:59 AM
Last Post: Pero
  Donation Script 1.0.0 steadymobbin 0 2,106 02-18-2013, 02:03 AM
Last Post: steadymobbin

Forum Jump:

1 Guest(s)
Share this:

About Second Life Copybot

Second Life CopyBot Forum is a place where you can get items for Second Life and other vitual worlds for free. With our CopyBot viewers you can export and import any content from these virtual worlds and modify them in 3D software such as Blender, 3D studio Macx etc...