Gummo

Gummo

Joined
Aug 31, 2007
Occupation
Hobo
Location
Australia
Website
Interests
Food, Money, Shelter

Activity Stream

Gummo commented on a Page, Hostmask/nick database and watcher  -  Oct 24, 2011

The easiest way to allow any wildcard host matching is a hash table.

 Respond  
Gummo commented on a Page, Rainbow Colors  -  Aug 11, 2011

Even without updating, you still have $regsub.

 Respond  
Gummo commented on a Page, Money System/RPG Basis  -  May 24, 2011

Lucius did mention that, but at the same time ini files are slower. Generally in this situation a hash table is suggested, but for this type of script performance isn't normally an issue anyway.

 Respond  
Gummo commented on a Page, Oper Help Script For Torn  -  Apr 11, 2011

Some of the text in this script suggests that it's created and/or used by someone who is a little abusive while thinking they're only being funny, to be honest.
Also, most networks running Anope should at least have alias commands like /NickServ
You should use those if possible since they only work when the services are online, which is much more secure for things like identifying with a password. :)

 Respond  
Gummo commented on a Page, Chronometer  -  Apr 09, 2011

Yes, doing it once instead of twice would make sense.

 Respond  
Gummo commented on a Page, Auto Op  -  Apr 07, 2011

Sorry, Jethro_, the reason I said you might as well check $nick == NickHere is because the code you suggested was no more secure than that. If you are comparing the current address of the person triggering the event (nick!ident@host) against, for example, $address(NickHere,2), the script will be comparing the triggered address with the address of whoever is currently using NickHere.
With that being the case, anyone using NickHere would validate correctly as the desired person.

 Respond  
Gummo commented on a Page, Chronometer  -  Apr 07, 2011

No, since a timer is not called from within the script you have no way of knowing whether the dialog is still open.

 Respond  
Gummo commented on a Page, Auto Op  -  Apr 07, 2011

Jethro_, if you are going to use that first method you might as well check for $nick == NickHere.
The second method is the same deal but it looks at the current address of the nickname compared to the address of the person in the event.
Also, you don't need the iswm operator if you have no wildcard comparison, which is the case when you compare one full address to another full address.

AndroidKnight, use this.

if (*!camron@jackdaniels.aint.got.shoot.on.me iswm $fulladdress) {
 Respond  
Gummo commented on a Page, Auto Op  -  Apr 07, 2011

Or you can use

if (Nick!*ident@host iswm $fulladdress) {

..Which is what they want.

 Respond  
Gummo commented on a Page, Chronometer  -  Apr 06, 2011

IllogicTC, should the dialog somehow manage to close without unsetting the timer due to some error, you would be flooded by errors at what should be once every millisecond, though it probably would be much less.
Even so, I'm fine with the check to make sure that the dialog is open within a command called by a timer.

 Respond  
Gummo commented on a Page, IP address functions  -  Apr 06, 2011

What is your basis for calling it invalid other than the fact that it's never used?
I looked at the IP standard as well as IP address allocation and nothing mentioned 0.0.0.0.
The only mention(s) of it were to say that an IP address is x.x.x.x where x is between 0 and 255.

 Respond  
Gummo commented on a Page, IP address functions  -  Apr 06, 2011

With 0.0.0.0 alone, you must decide whether your IP address check is based on whether the values are valid (all octets between 0 and 255) or whether the IP address is considered valid (since 0.0.0.0 is never used for anything).
I would personally only change that if 0.0.0.0 is considered invalid by the IP standard.

 Respond  
Gummo commented on a Page, IP address functions  -  Apr 06, 2011

Your regex is completely invalid.
It matches zero or more number characters (3 times), then zero or more number characters again.
It will be true if you supply a blank string or any reasonable amount of random numbers.

The regular expression for accurately matching an IP address is far more complex.

 Respond  
Gummo commented on a Page, IP address functions  -  Apr 06, 2011

No.. Why would it?

 Respond  
Gummo commented on a Page, IP address functions  -  Apr 05, 2011

Thanks napa. :)

 Respond  
Gummo created a Page  -  Apr 05, 2011

I decided to share three small functions I made for IP addresses the other day in a few minutes. Their use is as follows:

Gummo commented on a Page, RegEx Swear Kick  -  Apr 04, 2011

It seems my test for the \Q..\E was not correct to begin with. Thanks for making me look at it again, jaytea. :P

 Respond  
Gummo commented on a Page, RegEx Swear Kick  -  Apr 04, 2011

Yes, I understand the purpose of escaping the \E to prevent your \Q..\E from breaking. It can also still be broken by a backward slash preceding the \E.
Feel free to test a string "\E " against regex "\Q\E\E" and "\Q\\E\E" which are your options here.

 Respond  
Gummo commented on a Page, Text Colour Changer v4.6.2  -  Apr 04, 2011

I would consider that sort of thing to be a tacky addon if it were to be included within this script itself, considering the complexity difference.

 Respond  
Gummo commented on a Page, RegEx Swear Kick  -  Apr 04, 2011

Jethro_ appears to have a misleading regular expression here, but upon closer inspection it seems to be (for the most part) a readability issue.
There's no need to end an escaping \Q...\E, however, to escape something. \E would suffice instead of \E\E\Q.

 Respond  
Gummo commented on a Page, Mass Mode Popup (Via ChanServ)  -  Mar 28, 2011

A similar loop is this:

while ($0) { /cs op # $1 | tokenize 32 $2- }
 Respond  
Gummo commented on a Page, Runescape players  -  Mar 14, 2011

GET and POST are only methods of requesting/sending data. Your regex is used when receiving it.

 Respond  
Gummo commented on a Page, Switch Statement in msl  -  Feb 28, 2011

Jethro_, probably referring to the fact that you have to join each line together to form a pseudo-switch which is actually just a single command.

 Respond  
Gummo commented on a Page, Switch Statement in msl  -  Feb 28, 2011

Won't that fail if you use any non-word character as your case criteria? (\w+)

 Respond  
Gummo commented on a Page, Caps On 1st Letter  -  Jan 31, 2011

That explains the old programming style.

 Respond  
Gummo commented on a Page, $utf8 + upsidedown and octatext  -  Jan 31, 2011

Converting the text in the reverse order, you mean. Probably easier to understand that way.

 Respond  
Gummo commented on a Page, Easy Google Translator  -  Nov 29, 2010

/echo -q is an echo which doesn't show up if you put the . in front of your alias call.
/.msg hides the echo of your message.
If you created your own /noop alias which pointed to a silenced (e.g. /.noop2) alias then you could use echo -q but that'd be a pain anyway.
The other alternative, of course, is to just use a dud variable in its place.

 Respond  
Gummo commented on a Page, Trial reset  -  Nov 29, 2010

You don't even need to "negotiate" to $10 - there is a valid discount for $10 still, which has been around for years. For the amount of time I've used it, it's worth the $10.
http://www.mirc.co.uk/register.php?coupon=MIRC-SWV0-MNKL

 Respond  
Gummo commented on a Page, quote socket  -  Nov 25, 2010

i think someone should make a MSL program that makes the sockets for you, you type in the triggers and websites - Idea!
That's actually really easy up until the point where you decide how each website must be matched. All websites are arranged differently and sometimes the data comes through on more than one message, making that more difficult.
One solution which can't really fail is to always use a file and binvars, but that will make unnecessarily complicated scripts for most applications.

 Respond  
Gummo commented on a Page, Ban Finder  -  Nov 23, 2010

Jethro_ you /set %nicks once as well as /var %nicks twice. You should probably fix that up.

 Respond  
Are you sure you want to unfollow this person?
Are you sure you want to delete this?
Click "Unsubscribe" to stop receiving notices pertaining to this post.
Click "Subscribe" to resume notices pertaining to this post.