propagate() { // Sends out a copy of itself to every prim in the object
integer f = llGetNumberOfPrims(); if(f <=1){
llOwnerSay("There's only one prim in this object"); return; }
llOwnerSay("Propagating this script throughout object..."); // Link numbers begin with 1 do{ if(f != llGetLinkNumber()){
llGiveInventory(llGetLinkKey(f), llGetScriptName());
llOwnerSay("Given to "+ prim_name(f)); } }while(--f >0);
llOwnerSay("Done. You will now have to recompile all of the check scripts in this object before they " +"can be used - either take the object into inventory, re-rez and select 'Set all scripts to running in " +"selection' from Tools menu, or manually re-save each script."); }
help() {
llOwnerSay("Say commands on channel "+(string)CHANNEL +"\nhelp - this help message\n" +"send - send out copies of self to all prims in object\ncheck - check" +" inventory permissions in object against desired perms\ncheckall - complete list of all permissions" +"for all inventory contents\nmod - set or remove mod perm desired\ncopy - set or remove copy " +"perm desired\ntrans - set or remove trans perm desired\nkillall - remove all other check scripts " +"from object (including this one)\nhighlight - go through all of the prims highlighting each one, to " +"show permission (will spoil manual alpha adjustments!)");
llOwnerSay("Current desired permissions - "+ perm_string(gDesiredPerms)); }
kill_all_scripts() { // Send out die message and remove this script too
llOwnerSay("Sending message for other scripts to die...");
llMessageLinked(LINK_SET, LINK_N,"die", NULL_KEY); die(); }
toggle_flag(integer perm) {
gDesiredPerms = gDesiredPerms ^ perm; if(llGetLinkNumber()<=1) llOwnerSay("Desired permissions are now "+ perm_string(gDesiredPerms)); }
highlight_prims() {
integer f = llGetNumberOfPrims(); if(f <=1){
llOwnerSay("There's only one prim in this object, what's the point?"); return; }
llOwnerSay("Beginning prim highlighting");
llSetLinkAlpha(LINK_SET,0.1, ALL_SIDES); // Link numbers begin with 1 do{
llSetLinkAlpha(f,1.0, ALL_SIDES);
llOwnerSay("Highlight "+ prim_name(f));
llSleep(3.0);
llSetLinkAlpha(f,0.1, ALL_SIDES); }while(--f >0);
llSetLinkAlpha(LINK_SET,1.0, ALL_SIDES);
llOwnerSay("Done"); }