Editable array with the chat

Thread Started By steadymobbin

3184
0
  • 36 Vote(s) - 2.69 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Rate Thread
#1
Code:
/*
Bornslippy Ruby presents...
Editable array with the chat
Tags: avatar, chat, communications, owner, primitive, todo, ['', '', '']
Description: Editable array with the chat
License:
Editable array with the chat
Copyright (c) 2010 Bornslippy Ruby

This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 1, or any later version.

This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
http://secondlife.coolminds.org
*/

integer Channel = 0;
list Array = [];

default
{
    state_entry()
    {
        llListen(Channel, "", llGetOwner(), "");
    }
    
    listen(integer _c, string _n, key _i, string _m)
    {
        if (_c == 0)
            if (llGetSubString(_m, 0, 2) == "add")
            {
                if (-1==llListFindList(Array, [llGetSubString(_m, 4, llStringLength(_m))]))
                {
                    llOwnerSay("Entry "+llGetSubString(_m, 4, llStringLength(_m))+"] added.");
                    Array += llGetSubString(_m, 4, llStringLength(_m));
                }
            }
            else if (llGetSubString(_m, 0, 2) == "del")
            {
                if (-1<llListFindList(Array, (list)llGetSubString(_m, 4, llStringLength(_m))))
                {
                    Array = llDeleteSubList(Array, llListFindList(Array, (list)llGetSubString(_m, 4, llStringLength(_m))), llListFindList(Array, (list)llGetSubString(_m, 4, llStringLength(_m))));
                    llOwnerSay("Entry "+llKey2Name(llGetSubString(_m, 4, llStringLength(_m)))+"["+llGetSubString(_m, 4, llStringLength(_m))+"] removed.");
                } else llOwnerSay("Entry "+llKey2Name(llGetSubString(_m, 4, llStringLength(_m)))+"["+llGetSubString(_m, 4, llStringLength(_m))+"] not found.");
            }
            else if (llGetSubString(_m, 0, 3) == "list")
                llOwnerSay("\n\nArray\n"+llList2CSV(Array));
    }
}
[Image: guns-bullet-shirt_recreated.jpg]
Reply




Possibly Related Threads…
Thread Author Replies Views Last Post
  Private Chat SPY Relay script zion 2 7,928 06-11-2019, 07:34 PM
Last Post: adrianzero
  Multi Av IM Chat Relay / Spy Script v2.2 zion 1 5,796 04-30-2013, 04:51 AM
Last Post: Markus89
  Sim Wide Chat deadpool 0 3,495 02-19-2013, 02:16 AM
Last Post: deadpool
  Multi Av IM Chat Relay / Spy Script zion 0 3,858 02-18-2013, 03:43 AM
Last Post: zion
  Multi Av IM Chat Relay / Spy Script v2 (Now with email!) zion 0 3,687 02-18-2013, 03:26 AM
Last Post: zion
  chat to IM steadymobbin 0 2,194 02-18-2013, 03:06 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...