Jump to content

DominicBasino

Resident
  • Posts

    6
  • Joined

  • Last visited

Posts posted by DominicBasino

  1. I want to make a script that when touched it gives a person a menu to chose what hey want to recieve from that object. This is what I have so far. Where am I going wrong cause its only giving me one item to chose from:

     

    list MENU1 = [];
    list MENU2 = [];
    integer listener;
    integer MENU_CHANNEL = 1000;

    default
    {
    touch_start(integer total_number)
    {
    if(llGetInventoryNumber(INVENTORY_ALL) > 1)
    {
    if(llGetInventoryName(INVENTORY_ALL, 0) != llGetScriptName())
    {
    llGiveInventory(llDetectedKey(0),llGetInventoryName(INVENTORY_ALL, 0));
    }
    else
    llGiveInventory(llDetectedKey(0),llGetInventoryName(INVENTORY_ALL, 1));
    }
    else
    llInstantMessage(llDetectedKey(0), "There is no item to give away!");
    }
    }

  2. Okay I want to make a script that when touched it gives a person a menu to chose what hey want to recieve from that object. This is what I have so far....Where am I going wrong cause its only giving me one item to chose from:

     

    list MENU1 = [];
    list MENU2 = [];
    integer listener;
    integer MENU_CHANNEL = 1000;

    default
    {
    touch_start(integer total_number)
    {
    if(llGetInventoryNumber(INVENTORY_ALL) > 1)
    {
    if(llGetInventoryName(INVENTORY_ALL, 0) != llGetScriptName())
    {
    llGiveInventory(llDetectedKey(0),llGetInventoryName(INVENTORY_ALL, 0));
    }
    else
    llGiveInventory(llDetectedKey(0),llGetInventoryName(INVENTORY_ALL, 1));
    }
    else
    llInstantMessage(llDetectedKey(0), "There is no item to give away!");
    }
    }

  3. Okay. So I wrote a donation script and it works, but when a person pays it the hover text will not how the payment made. 

    Example:

    Before Billy pays donation jar the hover text shows :  Total donations L$0

    Once Billy pays the donation jar the hover text should show : Total Donations L$50 (but it doesn't)

    here is the script below please help me fix this:

     

     

    integer nTotalDonation;

    default
    {
    on_rez(integer start_param)
    {
    llResetScript();
    }
    state_entry()
    {
    llSetText("Psi Alpha Psi Fraternity Donations!\n" + "Total Donations: L$" + (string)nTotalDonation, <1.0,1.0,1.0>, 1);
    }

    money(key id, integer amount)
    {
    string cGiver = llKey2Name(id);
    llSay(PUBLIC_CHANNEL, "Psi Alpha Psi thanks you for the donation.");
    llInstantMessage(llGetOwner(), "Donation Jar in " + llGetRegionName() + "(" + (string)llGetPos() + ")" + "has recieved a donation from " + cGiver + "; " + (string) amount + "L");
    nTotalDonation += amount;
    }
    }

×
×
  • Create New...