Jump to content

How do I create a menu that merges all scripts into one?


Izzy Stipe
 Share

You are about to reply to a thread that has been inactive for 2825 days.

Please take a moment to consider if this thread is worth bumping.

Recommended Posts

My object currently uses 3 scripts. One to change the texture of a face, another to change the textures on numerous faces, and a script that rezzes different objects. What I've done is create a prim for each of these scripts, add the scripts to their own respective prim, and linked those prims to the main object.

I'd like to have all three options available on a single click on a single prim. Is there a script on sale that allows me to build a main menu easily?

Link to comment
Share on other sites

No.  You're describing a custom application, so you'll need to write a script that handles those specific options.  It shouldn't be very difficult, though, even if it involves totally rewriting the code bits that manage each of the three operations.  You need to construct a main menu and then three submenus, in the form

touch_start (integer num){    gAv = llDetectedKey(0);    llListenRemove(gLsn);    gLsn = llListen(gChan,"","","");    llDialog(gAv, " \n", ["One Face", "Many Faces","Rez New"],gChan);}listen(integer channel, string name, key id, string message){    integer idx1 = llListFindList(gListOne,[message]);    integer idx2 = llListFindList(gListTwo,[message]);    integer idx3 = llListFindList(gListThree,[message]);    if (message == "One Face")    {        llDialog(gAv," \n Do whatever the one face texture options are",gListOne,gChan);    }    else if (message == "Many Faces")    {        llDialog(gAv," \n Do whatever the many face texture options are",gListTwo,gChan);    }    else if (message == "Rez New")    {        llDialog(gAv," \n Do whatever the rez objects options are",gListThree,gChan);    }    else if (~idx1)    {        // Do the stuff that your one face texture menu does now    }    else if (~idx2)    {        // Do the stuff that your multiface texture menu does now    }    else if (~idx3)    {        // Do the stuff that your rezzing menu does now    }}

Making allowance for possible typos, that's the general approach you'd use for building three submenus under a single main menu.  The three lists (gListOne, gListTwo and gListThree) are the dialog menu options for your current menus and the "stuff" in each case is the llDialog that accesses them.  Add the responses from each of those dialogs and the job is done.

 

 

   

 

           

  • Like 1
Link to comment
Share on other sites

You are about to reply to a thread that has been inactive for 2825 days.

Please take a moment to consider if this thread is worth bumping.

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
 Share

×
×
  • Create New...