strings, mirc-Eu
- Posted by Kat <KSMiTH at PELL.NET> Dec 28, 1999
- 546 views
Ok, i sent a zip to RDS, included are: 1) the mirc script to talk to Eu 2) the strtok library for Eu (formerly named mirctok, renamed for copyright reasons) 3) String_9 , a backwards step from String.e 4) robobot3 , where you handle protocols, it that handles Srvsckip 5) Srvsckip , which handles 6) Win32lib 7) EuBot_5 an example in Eu 8) a readme file 1) The mirc script runs only in mIRC, it's not Eu code, and it's easy enough to learn and modify to do what you need. I have trapped and sent to Eu almost everything than can happen on irc, if it's useful for irc bots. It shows advanced mirc scripting and what can be done to connect mirc to other servers besides irc. My first http server and browser i wrote in mirc, it can also do email and telnet, after all, it's just code... 2) This is the asked-for strings library, aka mirctoks . It lets you relate to sequences at a "higher" level, to the words of strings, and to what separates the words if you like. It's easier, to me, to deal with strings as collections of words, rather than bytes in a sequence, altho the sequences used in strtok are real Eu sequences, so you can still byte them. Gabriel had the foresight to make parse(), which is now global. I added getxml() for parsing <tags>..</tags> in databases, you can easily change it to use [tags]..[/tags] if you wish. Lucius is prolly still working on speeding this up,, not sure. I may add some more xml processing code any day now. With strtok you can count words, specify words, locate them, delete them, change them, add them, retrieve specific words, etc. Email me suggestions. 3) More string routines, required for useful bot workings, most noteable is strippunct() and strip(), removing punctuation and excess spaces and color codes,, again, for dealing with words in a sentence. In NLP it is often best to have punctuation removed initially, and no one uses any part of English (or other languages) properly on irc anyhow... 4) Robobot is the place to do different protocols, this version handles what we set up for EuBot.ew or Bot.e files and the mirc code included in the zip file. It handles the init, handshaking, sock open/close/block, and processes the header for the mirc code, you'll change this if you do an http interface, or telnet, email, etc.,, otherwise it's a stable version,, right, Greg? 5) an enhanced Srvsckip, but i didn't look to see what was enhanced, all i know is that it works now, and faster. Greg may be still working and editing it. 6) Win32lib ,, what else can one say? I included this because i know the other zip files works with this edition. /me bows to David Cuny. 7) an example of what can be done to the data coming from mirc, and how mirc can tell Eu what to do, and how Eu can tell mirc what to do. We did this to connect mirc to Eu and build frames to do other things. 8) the readme,, just some setup stuff from me, but if you don't read it, don't blame me if it doesn't run! One point that can be made is that Eu doesn't know it's connection is to mIRC, it could be another Eu or Pirch or Perl (barf) or C code. And same for mIRC, it could be connected to another mirc, etc. Also, i/we all used 127.0.0.1/localhost as the ip to connect to, so the code as it is will look for handshakes on only your machine, to change it to another puter on an intra/internet, change the ip. Enjoy. Kat