Message 13: Registering charred for 'Rainbow Gravitation.ash'...
[COLOR="#008000"]Success! charred is now registered as a user of your 'Rainbow Gravitation.ash' script.[/COLOR]
Message 14: Registering OrochiDP for 'CounterChecker.ash'...
[B][COLOR="#ff0000"]Query strings aren't toys, you know.[/COLOR][/B]
Message 15: Registering Gneurotic for 'Universal_recovery.ash'...
[COLOR="#808000"]Gneurotic was already successfully registered for this script.[/COLOR]
Use ZLib's process_kmail() for ridiculously fantastic justice. Also, allow unlimited commands in any order per kmail.
string new_mess(kmessage m) {
string oneItem() {
foreach it in m.items return " ("+it+")";
return "";
}
int gothodge() {
foreach it in m.items
if(it == $item[stuffed Hodgman]) return m.items[$item[stuffed Hodgman]];
return 0;
}
boolean brick() {
foreach it in m.items
if(it == $item[brick]) return true;
return false;
}
string kBaySummary() {
if(m.message.contains_text("cashout")) return " saying you need to cashout to receive items/meat when "+(in_hardcore()? "hardcore": "ronin")+" is over.";
if(m.message.contains_text("The winner of the auction is")) return " sending you "+m.meat+" meat.";
foreach s in $strings[You have successfully listed a new auction, Here is everything that I owe you,
I will return your items to you]
if(m.message.contains_text(s)) return " saying, \""+s+"\"";
return "";
}
if(m.fromname == "Your Pen Pal" || m.fromname == "Subject 37")
return m.fromname + oneItem();
if(m.fromname == "kBay") return m.fromname + kBaySummary();
if(count(m.items) > 0) {
int hodgies = gothodge();
if(hodgies > 0)
return m.fromname + " -- Sending you " + (hodgies == 1? "a stuffed Hodgman.":(hodgies+" stuffed Hodgmen."));
if(brick())
return m.fromname + " hitting you with a brick.";
return m.fromname + " -- sending you a gift.";
}
return m.fromname;
}
So, different versions are in some ways different scripts.stannius_spaaace_0.6.ash said:// note to self: make sure to update the version number in all relevant places
script "stannius_spaaace_0.6.ash";
notify stannius;
import "zlib.ash";
check_version("stannius_spaaace", "stannius_spaaace", "0.6", 6969);
It is generally considered a good idea to leave off the version number if you're using this script. Otherwise it will become annoying later to have separate entries for each version. I'd personally just use script "spaaace"; since that is all the author needs to know. Seriously, you don't need to be reminded what your own name is and nobody else is going to get the kMail containing your script's name.
If you're interested in check_version(), that's a different thread and a completely different problem.
Doesn't hurt anyone at all since nobody will see it unless they look you up here.
Everything happens to the incorrectly named "The Sea" script, not the correctly named "TheSea.ash" script. I can't set url, registrer users, anything... at this point, do I just accept that the name will be wrong? I can register and unregister on the right name, I just can't set the URL or have people actually registered to it.> registry
Registering URL for 'TheSea.ash'...
URL for 'TheSea.ash' successfully modified.
Deleting processed mail...
1 message deleted.
Printing report...
Script Registry report for Theraze: 2 scripts, 9 users.
Script Registered URL? Users
The Sea 1/14/12 yes 9
TheSea.ash 1/17/12 no 0
Mafia will only send a message the first time someone runs the script and I used notify on my script once before so those people aren't sending me new messages, but fortunately I'd saved those mails in a text file in case I was ever curious about them. It wasn't too hard to modify your script to read in the old messages using file_to_map so I was able to get those old registrations into your database.
So? Modify the script to read from messages.php?box=Saved if you want to get them. It'll be a bit harder to modify this version of the script for that than the original pre- api.php version, but it's still doable. The question is how much you want to rescue those registrations from obscurity.