Top Free Scripts
Script ID : 9
Audience : Default
Version 1.00.05
Published Date: 2006/10/17 2:10:00
Reads : 32415
Money

I've seen this script in Freebie packs all the time, and it's always wrong. It doesn't correctly show how much has been collected so far. I assume it's because it is an old script and SL may have changed since. Either way, this is my own version, and it works.

integer totaldonated;

default
{
    
on_rezinteger sparam )
    {
        
llResetScript();
    }

    
state_entry()
    {
        
llSetText("Donation Box\nL$0 Donated so far",<1,1,1>,1);
    }

    
money(key idinteger amount)
    {
        
totaldonated totaldonated amount;
        
llSetText("Donation Box\nL$" + (string)totaldonated " Donated so far",<1,1,1>,1);
        
llInstantMessage(id,"Thank you for the donation!");
    }
}

0
|  Links 
Printer Friendly Page Send this Script to a Friend
Search for Help
New Product
Free Item
Sponsor

Site Info
Total Hits