• Bitte schaltet eure Ad Blocker aus. SLinfo kann nur betrieben werden, wenn es durch Werbung Einnahmen erzielt. Vielen Dank!!
  • Wir freuen uns, wenn du dich in unserem Forum anmeldest. Bitte beachte, dass die Freigabe per Hand durchgeführt wird (Schutz vor Spammer). Damit kann die Freigabe bis zu 24 Stunden dauern.
  • Wir verwenden Cookies, um Inhalte und Anzeigen zu personalisieren, Funktionen für soziale Medien anbieten zu können und die Zugriffe auf unsere Website zu analysieren. Sie geben Einwilligung zu unseren Cookies, wenn Sie unsere Webseite weiterhin nutzen.

richtig Guter Club Dance Ball

Franko Box

Nutzer
hier ein richtig gutes Script für einen Dance Ball.. hab es immer in meinem Club benutzt mit zum Teil über 30 Tänzer gleichzeitig . Solop Server Script in den Tanzball mit 30 mal dem mainanim script .. must es dann jeweils umrennen mainanim1, mainanim2, mainanim3 usw. bis mainanim30. dann noch beliebe
Tanzanimationen + ein Rotation Script rein und schöne Textur drauf und fertig.

Solop Server:

PHP:
//11/11 fixed for numanims, allows nearly UNLIMITED animations!

integer length = 20; // change for # of seconds to play each anim

integer danceslots = 30; // how many "mainscripts" you have in the object.

integer numdances;
integer curranim;
//list dances;
list dancers;
list STOP_MENU = ["OK"];
integer IM_Dancer = TRUE;

updatetext()
{
    llSetText(llGetObjectName() + "\n \n Dancing: " + (string)llGetListLength(dancers) + " of " + (string)danceslots + "\n" + (string)numdances + " Dances Loaded!\n Current Dance: " + llGetInventoryName(INVENTORY_ANIMATION, curranim), <1,0,1>, 1);
}
default
{
    touch_start(integer num_detected)
    {
        integer i;
        for (i = 0; i < num_detected; i++)
        {
            key currkey = llDetectedKey(i);
            integer d = llListFindList(dancers, [currkey]);
            if ( (d == -1) && (llGetListLength(dancers) < danceslots) )
            {
                dancers = dancers + [currkey];
                if (IM_Dancer)
                {
                    llInstantMessage(currkey, "Say or shout /99stop or touch again to stop dancing.");
                }
                else
                {
                    llDialog(currkey,"Say or shout /99stop or touch again to stop dancing.", STOP_MENU, -99);
                }
                llMessageLinked(0,1,"start",currkey);
            }else if (d != -1){
                dancers = llDeleteSubList(dancers, d, d);
                llMessageLinked(0,0,"stop",currkey);
            }else{
                llInstantMessage(currkey, "Sorry, but all the available dance slots are used. Please check back soon!");
            }
            updatetext();
        }
    }
   
    link_message(integer sender_num, integer num, string msg, key id)
    {
        if (msg == "cancel")
        {
            integer fk = llListFindList(dancers, [id]);
            if (fk != -1)
                dancers = llDeleteSubList(dancers, fk, fk);
            updatetext();
        }
    }
   
    state_entry()
    {
        //danceslots = llGetInventoryNumber(INVENTORY_SCRIPT) - 1; // slightly more dynamic, but commented for forum-version, check the top of script to change this...
        numdances = llGetInventoryNumber(INVENTORY_ANIMATION);
        integer i;
        //for (i = 0; i < numdances; i++) // no longer needed , uses numbers now :D
            //dances = dances + [llGetInventoryName(INVENTORY_ANIMATION, i)];
        llSetTimerEvent(length);
        llListen( 99, "", NULL_KEY, "" );
        updatetext();
    }
   
    listen ( integer channel, string name, key id, string message )
    {
        integer i;

        if ( channel == -99 ) return;
               
        if ( message == "stop" )
        {
            integer d = llListFindList(dancers, [id]);
            if (d != -1)
            {
                dancers = llDeleteSubList(dancers, d, d);
                llMessageLinked(0,0,"stop",id);
            }
        }
       
        if ( message == "list" && id == llGetOwner())
        {
            for ( i = 0; i < numdances; i++ )
            {
                llWhisper(0, llGetInventoryName(INVENTORY_ANIMATION, i));
            }
        }
       
        if ( message == "reset" && id == llGetOwner())
        {
            key dancerkey;
            for ( i = 0; i < llGetListLength(dancers); i++ )
            {
                dancerkey = llList2Key(dancers, i);
                llMessageLinked(0,0,"stop",dancerkey);
            }
            dancers = [];
            llResetScript();
        }
       
        if (message == "dancers" )
        {
            for ( i = 0; i < llGetListLength(dancers); i++ )
            {
                llInstantMessage(id, llKey2Name(llList2Key(dancers, i)));
            }
        }
       
    }
   

    timer()
    {
        if (curranim >= numdances)
        {
            curranim = 0;
        }
        llMessageLinked(0, 256, (string)curranim, NULL_KEY);
        updatetext();
        curranim++;
    }
   
    on_rez(integer sparam){llResetScript();}
}

////////////////////////////////////////////////////////////////////////
//
//  Solop(rim) Dance version 1.1a SOLOPSERVER
//  by Evil Fool
//  Copyright (c) 2004 by Michael Goetz
//  All Rights Reserved
//
//  Permission to Use and Redistribute
//
//  Permission to use and redistribute the Solop Dance code, with or
//  without modifications, is granted under the following conditions:
//
//  + All redistributions must include this copyright notice and license.
//  + All redistributions must allow the next user to view, modify, and
//    redistribute this code, containing this copyright notice and license.
//  + All redistributions must give credit to the author, by real name
//    (Michael Goetz) and by SL name (Evil Fool).  If distributed in a
//    modified form, credit must still be given to Evil Fool (Michael
//    Goetz) as the original author.
//  + All redistributions *should* include a notecard or documentation
//    containing instructions for proper use and setup.
//
////////////////////////////////////////////////////////////////////////

mainanim :
PHP:
key prekey;
key DancerKey = NULL_KEY;
string Dance = "jump";
string OldDance = "jump";
integer scriptnum;

reset()
{
    llMessageLinked(0, 0, "cancel", prekey);
    prekey = NULL_KEY;
    DancerKey = NULL_KEY;
    //llSensorRemove();
    llSetTimerEvent(0);
}

default
{
    state_entry()
    {
        scriptnum = llList2Integer(llParseString2List(llGetScriptName(  ),["mainanim "],[]),0);
    }
    
    on_rez(integer start_param)
    {
        llResetScript();
    }
    
    link_message(integer sender_num, integer num, string msg, key id)
    {
        if (num != 256)
        {
            if (msg == "start" && num == scriptnum)
            {
                if (DancerKey == NULL_KEY && prekey != id)
                {
                    prekey = id;
                    llRequestPermissions(prekey, PERMISSION_TRIGGER_ANIMATION);
                    llSetTimerEvent(10);
                }else{
                    llMessageLinked(0, num + 1, msg, id);
                }
            }
            else if (prekey == id && msg == "stop")
            {
                if (DancerKey == id) llStopAnimation(Dance);
                reset();
            }
        }else{
            if (DancerKey != NULL_KEY)
            {
                if (llGetPermissions() & PERMISSION_TRIGGER_ANIMATION)
                {
                    OldDance = Dance;
                    Dance = llGetInventoryName(INVENTORY_ANIMATION, (integer)msg);
                    llSensor("", DancerKey, AGENT, 96.0, TWO_PI);
                }else{
                    //llStopAnimation(Dance);
                    reset();
                }
                
            }else if (DancerKey == NULL_KEY)
            {
                OldDance = Dance;
                Dance = llGetInventoryName(INVENTORY_ANIMATION, (integer)msg);
            }
        }
    }
    
    no_sensor()
    {
        //if (DancerKey != llGetOwner())
        //{
            //llStopAnimation(Dance);
            reset();
        //}
    }
    
    sensor(integer n)
    {
        llStopAnimation(OldDance);
        llStartAnimation(Dance);
    }
    
    run_time_permissions(integer perms)
    {
        llSetTimerEvent(0);
        if (perms & PERMISSION_TRIGGER_ANIMATION)
        {
            DancerKey = prekey;
            //llSensorRepeat("", DancerKey, AGENT, 96.0, TWO_PI, 30.0);
            llStartAnimation(Dance);
        }else{
            reset();
        }
    }
    timer()
    {
        reset();
    }
}

////////////////////////////////////////////////////////////////////////
//
//  Solop(rim) Dance version 1.1c MAINANIM
//  by Evil Fool
//  Copyright (c) 2004 by Michael Goetz
//  All Rights Reserved
//
//  Permission to Use and Redistribute
//
//  Permission to use and redistribute the Solop Dance code, with or
//  without modifications, is granted under the following conditions:
//
//  + All redistributions must include this copyright notice and license.
//  + All redistributions must allow the next user to view, modify, and
//    redistribute this code, containing this copyright notice and license.
//  + All redistributions must give credit to the author, by real name
//    (Michael Goetz) and by SL name (Evil Fool).  If distributed in a
//    modified form, credit must still be given to Evil Fool (Michael
//    Goetz) as the original author.
//  + All redistributions *should* include a notecard or documentation
//    containing instructions for proper use and setup.
//
////////////////////////////////////////////////////////////////////////
 

Users who are viewing this thread

Zurück
Oben Unten