I have repaired them for you. Here is the job one:
Code: Select all
def Initialize() {
$words = vector(
"Assistant", "Assnt",
"Captain", "Capt",
"Head of Personnel", "HoP",
"Bartender", "Bar",
"Chef", "Chef",
"Botanist", "Hydro",
"Quartermaster", "QM",
"Cargo Technician", "Cargo",
"Shaft Miner", "Miner",
"Clown", "Clown",
"Mime", "Mime",
"Janitor", "Jan-r",
"Librarian", "Lib-n",
"Lawyer", "Law",
"Chaplain", "Chapl",
"Chief Engineer", "CE",
"Station Engineer", "Engi",
"Atmospheric Technician", "Atmos",
"Chief Medical Officer", "CMO",
"Medical Doctor", "MD",
"Chemist", "Chem",
"Geneticist", "G-tic",
"Virologist", "Viro",
"Research Director", "RD",
"Scientist", "Sci",
"Roboticist", "Robo",
"Head of Security", "HoS",
"Warden", "Ward",
"Detective", "D-tiv",
"Security Officer", "Sec",
"AI", "AI",
"Cyborg", "Borg",
"Personal AI", "pAI",
);
$index = 1;
while($index <= length($words))
{
$key = at($words, $index);
$value = at($words, $index+1);
mem($key,$value);
$index += 2;
}
}
if(mem("initialized") != 1)
{
Initialize();
mem("initialized", 1);
}
$foo = "";
if(mem($job)) { $foo = mem($job); }
else { $foo = substr($job, 1, 6); }
if (!find($source, "Unknown") && $job != "No id" && !find($source, " (as ")) {
$source = $source + " (" + $foo + ")"; }
And here is the Cleaner Selective Mute one:
Code: Select all
//recursive implode function, takes a vector and
//combines each member into a string with a space to separate
//by perogi
def implode($vector)
{
$str = at($vector, 1);
remove($vector, $str);
if(length($vector) > 0)
{
$str += " ";
$str += implode($vector);
}
return $str;
}
//mute and unmute function
//use: type /mute or /unmute then the name of the person exactly as it is spelled
//by perogi
$exp = explode($content, " ");
if($source == "YOUR NAME HERE") //only the name in this line can use script
{
if(at($exp, 1) == "/mute")
{
remove($exp, "/mute");
$name = implode($exp);
$pass = 0;
mem($name,$name);
}
if(at($exp,1) == "/unmute")
{
$pass = 0;
remove($exp, "/unmute");
$muteremove = implode($exp);
mem($muteremove, 0);
}
}
//checks if source is muted
//possible to get around mute by taking off ID and being unknown, hence why unknowns are all blocked
if($source == mem($source) || $source == "Unknown")
{
$pass = 0;
}
I am not touching the Selective Mute one, as that thing is a beast, and we have a mute script already.