Doorbell / Türklingel für OS geändert (mit privat & public Einstellung)

1 Jahr 9 Monate her #16 von Copper Tomsen


  • Beiträge: 13

  • Geschlecht: unbekannt
  • Geburtstag: 22 Mai 2020
  • Mal schun ob ein script hier reinzukopieren ist. Ich habe das Original für SL bischen überarbeitet. Hat auch privat und public Funktion zur Auswahl:

    //Seamed to be a script for SL in original.So Copper Tomsen played a little with it in april 2021 to make it work in OS :-)
    // BASIC RING BUTTON
    // by buttbadger Mirabeau

    // Usage: When someone touches the doorbell, it rings and the toucher's name will be said in chat.
    // When the owner touches it, they can ring the bell or choose a Public and Private setting. (Private by default)
    // Private setting will send the notification in private IM in localchat. Only you can read it.
    // Public setting will send the notification in localchat, visible for everybody in range.

    // Like,
    // This script is open source and free. It can't be resold as it is. You can put it in part of your sales
    // as long as you keep the script in fullperm.

    // The title to display above the button. just leave "" if you don't want any
    string ringpanel = "Touch me to ring";

    // The door bell sound. By default it take the first sound available in the prim


    // This is the end of the thing the button will say if someone rings. The name of the clicker will be at the beginning, then its key: Everyone in chat range will hear
    string ringnotice = "is ringing at the door!";

    // Set this to TRUE if you want the notice to display for everyone around and not just you
    integer publicshout = TRUE;

    // Some other junk
    integer antispam;
    key userkey;
    key owner;
    list menuitems;
    integer channel;
    integer listener;

    ringing()
    {
            llPlaySound(llGetInventoryName(INVENTORY_SOUND,0), 1.0);
            //llPlaySound(llGetInventoryName(INVENTORY_SOUND,0), 1.0); // Uncomment if sound is not enough loud
            //llPlaySound(llGetInventoryName(INVENTORY_SOUND,0), 1.0); // Uncomment if sound is not enough loud
            
            if (antispam == FALSE) // That way, the button can still ring but it won't spam you with IMs
            {
                antispam = TRUE;
                llSetTimerEvent(60.0);
                if (publicshout == FALSE) llOwnerSay((llDetectedName(0)) + " " + ringnotice);  // It will say "Display Name (user name) is ringing at your door!" by default
                else llSay(0,(llDetectedName(0)) + (string)userkey + "/inspect " + ringnotice);
            }
    }

    default
    {
        state_entry()
        {
            antispam = FALSE;
            owner = llGetOwner();
            llSetText(ringpanel, <1,1,1>, 1.5);
        }
         on_rez(integer num)
        {
            // Reset script when rezzed
            llResetScript();
        }
        touch_start(integer total_number)
        {
            userkey = llDetectedKey(0);
            if (userkey != owner)  ringing();
            else state ownermenu;
        {
                llSay(0, "Staff contacted, if available, will arrive shortly!");
                llInstantMessage(llGetOwner(), llDetectedName(0) + " rang the bell (floor 2) at " + llGetRegionName());
              }
         }
     
        
        timer()  // ends the antispam timer
        {
            llSetTimerEvent(0.0);
            antispam = FALSE;
        }
    }

    state ownermenu
    {
        state_entry()
        {
            if (publicshout == TRUE) menuitems = ["Private","Ring!","CANCEL"];
            else menuitems = ["Public","Ring!","CANCEL"];
            channel = (integer)llFrand(99999);
            listener = llListen(channel, "", owner, "");
            llDialog(owner, "Doorbell menu\n\nPublic/Private: Choose if you get the notifications in private, or said in local chat.\nRing: Ring the doorbell!", menuitems, channel);
            llSetTimerEvent(30.0);
        }
        
        listen (integer channel, string n, key i, string m)
        {
            if (m == "Public")
            {
                publicshout = TRUE;
                llOwnerSay("Doorbell ringer's name and key will be sent in public chat.");
                llSetTimerEvent(0.0);
                llListenRemove(listener);
                state default;
            }
        
            else if (m == "Private")
            {
                publicshout = FALSE;
                llOwnerSay("Doorbell ringer's name will be sent as private IM in chat.");
                llSetTimerEvent(0.0);
                llListenRemove(listener);
                state default;
            }
        
            else if (m == "Ring!")
            {
                ringing();
                llSetTimerEvent(0.0);
                llListenRemove(listener);
                state default;
            }
        
            else
            {
                llSetTimerEvent(0.0);
                llListenRemove(listener);
                state default;
            }
        }
        
        timer()
        {
            llSetTimerEvent(0.0);
            llListenRemove(listener);
            state default;
        }
    }

    Bitte Anmelden oder Registrieren um der Konversation beizutreten.

    Ladezeit der Seite: 0.099 Sekunden
    Powered by Kunena Forum

    • Was ist OpenSim ? +

      OpenSimulator ist eine Plattform für das Betreiben einer virtuellen Welt und es unterstützt mehrere unabhängige Regionen, die sich mit einem zentralen Grid verbinden können. Es ähnelt stark dem Netz, in dem jeder seinen eigenen Webserver betreiben kann, die über das Internet miteinander verbunden sind. Es kann auch zur Erstellung eines privaten Grids verwendet werden, analog zum privatem Intranet.
    • Was ist eine Region ? +

      Eine Region ist das, was sich Ihnen zeigt, wenn Sie sich in OpenSimulator einloggen. Sie ist der physische Ort (nun gut, der virtuelle physische Raum) in dem sich Avatare bewegen und interagieren. Sie ist ein quadratischer Flecken Erde, der eine Insel enthalten kann, Berge, eine Ebene, Gebäude, etc., oder auch nur ein Meer.
    • Was ist das Grid ? +

      Das Grid ist die Ebene, welche die Regionen und ihre Positionen in der Welt organisiert. Es wickelt die Dinge ab, die regionsübergreifend gebraucht werden, wie z.B. das Benutzerinventar. Sie können es sich als eine Weltkarte vorstellen.
    • 1

    Features

      Interface

      Eigenes User Interface
      Zugriff auf volle OS-Konsole SIM Neustart (Hardreset) individuelle Backups machen

      Backups

      inbegriffen
      Tägliche lokale Backups Wöchentliche Remote Backups 3 Individuelle Backups

      FTP Server

      Zugriff auf Deine Daten
      Backups herunterladen IAR und OAR hochladen via. Konsole auf deine Sim speichern
  • 1
  • Preise

      Standard Region

      1 Sim (256 * 256) Laufzeit mind. 1 Monat monatlich kündbar
      15 € / Monat 15000 Prims Eigenes Estate Volle Regionsrechte

      Zusätzliche Region

      weitere Regionen zur Grundregion pro Sim (256 *256) Gleicher Eigentümer Gleiche Datenbank
      5€ / Monat 15000 Prims

      VAR Regionen

      15 € Grundgebühr plus 1€ pro Sim
      Beispiel
      2x2 VAR: 15 € + 3 x 1€ =18€
      4x4 VAR: 15 € + 15 x 1€ =30€
  • 1

  • Aktuell sind 762 Gäste und keine Mitglieder online


    Willkommen im Swissgrid.
    Du hast Fragen Wünsche oder Anregungen.
    Dann teil Dich doch einfach mit. Es ist ganz einfach.

    5 + 1 =

    swissgrid.opensim.ch

    © Swissgrid 2018-2022 Impressum:
     Admin: Night Raven    Sili Gal
         CH-8952 Schlieren/ZH