================================]-[ydrobomb===============================
                             a script for mIRC
                             this version: 2.2
===============================DOCUMENTATION==============================

Thanks for downloading ]-[ydrobomb.

Here's a list of what you should have found when you unzipped the
HYDRO22.ZIP file, and the descriptions of each file:

HYDRO.INI    - user level information, Recognize database
HYDROHLP.TXT - this file
HYDROSAY.TXT - list of sayings associated with the /HYDRO command
HYDROVER.TXT - similar to mIRC's VERSIONS.TXT, shows what changes have
               been made since the last version
PAGE.WAV     - used with pager, sound of a phone ringing
HYDALI.INI   - Aliases file
HYDCTCP.INI  - CTCP commands script
HYDEVENT.INI - Event handler script
HYDRAW.INI   - Raw event handler script
HYDVARS.INI  - Variables file
HYDPOP.INI   - Popups file
HYDMIRC.INI  - Main initialization file
EINPGP.ASC   - Einstein's ASCII armored PGP public key (version 2.6.2)

You must provide the file SERVERS.INI. This file is a list of IRC servers
with descriptions. I purposely left it out of my distribution of ]-[ydrobomb,
since each user probably has his/her own personalized file.
To include SERVERS.INI, copy your existing SERVERS.INI file into the
directory into which you unzipped HYDRO22.ZIP.

If you didn't get all of these files, your copy of ]-[ydrobomb may not
work correctly. Try downloading from another site or go to
http://cust2.iamerica.net/sdl/hydro/ for a guaranteed complete copy.

--------------------------------SETUP-------------------------------------

You can create a shortcut file that will allow you to run ]-[ydrobomb
when you want it. To do this:

1. Unzip HYDRO22.ZIP into your main mIRC directory.

(for Win95 users)
2. Right click on the Start button, click on Open. Go to the Start menu
group where you want the shortcut for ]-[ydrobomb to be.
3. Click File...New...Shortcut. Win95's Shortcut Wizard will appear.
4. In the blank marked "Command Line," type
"c:\mirc\mirc32.exe -i hydmirc.ini".
Replace c:\mirc\ with your mIRC directory if necessary. If for some reason
you're running 16-bit mIRC, replace mirc32.exe with mirc.exe.
5. Click Next >.
6. As a name for the shortcut, type "]-[ydrobomb" or some other text that
reminds you that this shortcut runs ]-[ydrobomb.
7. Click Finish. You can now run ]-[ydrobomb-enabled mIRC from the place
in the Start menu where you created the shortcut.

(For Win 3.1x users)
2. In Program Manager, go to the Program Group where you want the
]-[ydrobomb icon to appear. Click File...New. Select "Program Item"
and click OK.
3. In the "Command Line" blank, type "c:\mirc\mirc.exe -i mirchyd.ini".
If your mIRC directory is different, change it to reflect this.
If you're running 32-bit mIRC, change mirc.exe to mirc32.exe.
Type as a name, "]-[ydrobomb" or some other text string which reflects
that this icon runs a ]-[ydrobomb-enabled mirc.
4. Click OK. The icon created will allow you to launch mIRC with ]-[ydrobomb
running.

Either way, you can use the icon you created to run ]-[ydrobomb-assisted
mIRC at any time. Your usual mIRC icon will NOT launch ]-[ydrobomb
if you followed these procedures exactly. It is possible to edit this icon
so that it does. To make your usual mIRC icon run ]-[ydrobomb, add

-i hydmirc.ini

to the command string. If there already is a -i and an argument, replace it
with -i hydmirc.ini.

That's it! ]-[ydrobomb has been installed into your mIRC. Note that the
Command menu has changed into the ]-[ydrobomb menu.

--------------------------------AUTHOR-------------------------------------
Contact me:
On Undernet - Einstein, Einstein_ or Einstein^ (/whois me, look for
              iamerica.net)
via E-mail - sdl@iamerica.net

If you'd like to contact me privately, I accept PGP-encoded messages.
My public key is included in this and all subsequent distributions of
]-[ydrobomb as EINPGP.ASC.

Special thanks to:

Khaled    - For mIRC.
Mardam-Bey

LoKi128 -   This script could not be what it is without his help.
            He invented the port scanner, accurate pinging, and the titlebar
            and was instrumental in helping me script them.

Old_Major - For the faith in the script and all those really annoying
            messages informing me of the bugs I had yet to fix.

iAmerica  - For the webspace and the PPP connect. If you live in Texas,
            Louisiana, Arkansas, or Mississippi, check them out.

mIRC scripting  - For your reveiws, your encouragement, your criticism,
sites             and the great service that you do for the scripting
                  community. Thanks especially to Hawkee, {pll}, and
                  Hiro101 and his team. Keep the faith, guys. We need you.

===============================OPERATION===================================

This section tries to explain how to use each feature of ]-[ydrobomb.
I have tried to go in a logical order to help users find what they need.

---------------------------]-[ydrobomb menu--------------------------------

About
	Displays a screen-long piece of information about the program.

Documentation

	Launches this file.

Channel Flood Protect

	This attempts to protect against users who "flood" or "scroll"
	channels by rapidly dumping messages into them. When ]-[ydrobomb
	detects that a user has sent too many messages in too little time,
	and you have ops in the channel in question, the flooding user
	will be automatically /kick'ed.

Default: OFF

CTCP Protect (Same IP)

	CTCP Protect adds an extra layer of protection to mIRC's admirable
	built-in flood protect. When it detects a CTCP from a user, it
	ignores everyone using that person's IP address for a time you
	specify (the "ignore factor").

Default: ON

CTCP Protect (All IP's)

	This feature is a blanket flood protect which works well against
	floods coming from multiple IP adresses. It works in a similar
	fashion to the above feature.

Default: ON

Warn on Channel CTCP

	This simple script enables you to see when a user has sent a CTCP
	query to the entire channel. It will /echo the warning into the
	active window.

Default: ON

CTCP wall

	This script, now fixed for ]-[ydrobomb 2.2, locks out all
	CTCP queries.

Default: OFF

DCC CHAT flood protect

	This script protects you from users who open a DCC CHAT to you,
	then dump lots of characters into the chat in an attempt to lock
	up your mIRC. If 100 lines are detected in 60 seconds or less,
	the chat is closed.

Default: ON

Automatic pinging on "Ping Me"

	When a user says "Ping me," ]-[ydro will send a CTCP PING query
	to that user. This is default to off because a malicious user
	can repeatedly say "Ping me" and get you to send too many pings,
	flooding you off. However, if you feel that this feature would
	be convenient for you, activate it.

Default: OFF

Automatic Ping Time Notice

	This rather complex script analyzes a user's CTCP PING reply
	and reports the result to them via /notice. It also echoes
	the result into the active window so you can see it more	
	easily. This script converts ping times from the seconds format
	to minutes and seconds if the ping time is more than 60 seconds.

Default: ON

Show /WHOIS data in active window

	]-[ydrobomb reads /WHOIS data from the server using RAW and displays
	it in a pleasing table-like format. If this feature is active,
	the data will be displayed in the active window.

Default: ON

Show DNS data in active window

	mIRC's /DNS command allows a user to lookup the IP address from
	a nick's user@host. With this feature active, DNS data will be
	shown in the active window.

Default: ON

Self Ban Protection

	When this feature is on, ]-[ydrobomb analyzes bans (mode +b)
	to see if the mask matches yours. If so, the banner is deopped
	immediately and you automatically unban yourself.
	This helps at times, but sometimes a user will kick you first,
	then ban, or ban and then kick so quickly that the script has
	no time to react.
	This _MAY_ deop your friends who place a ban accidentally or
	otherwise.

Default: ON

WAV/MID support

	mIRC provides a powerful sound file playing/trading medium.
	There is something of an unofficial standard that details what
	a user should do in order to play/send/get sound files.
	I designed ]-[ydrobomb to adhere to that standard.
	
	Directory

		Allows you to set the name of the directory where
		your WAV/MID files are kept. Please note that you have to
		set this in two places, under the ]-[ydrobomb menu and
		under File...Options...Sounds. It should be possible
		for a script to access the wav directory name, but it's
		not.

	Default: none

	AutoLoad when played

		This script attempts to download EVERY wave file that is
		played in a channel. I defaulted this to off since, in
		addition to being a major security risk, this can fill
		up your hard drive with sound files you may not want.
		Please do not use this feature while you're away from
		the computer.

	Default: OFF

	AutoSend on !nick

		The unofficial sound playing standards provides for a means
		for users to download wavefiles from each other
		automatically. With this on, you will send a file from
		your waves directory when someone types
		!yournick filename.wav
		This does allow users to have a small amount of access to
		your system, but I have left it once since most waveplaying
		channels consider it very rude not to have this feature.

	Default: ON

Age/Sex

	This, one of the oldest mIRC scripts in recorded history, listens
	for common queries about age and/or sex and automatically responds
	to them. You have to set information when you turn this on
	so ]-[ydro will know what to say.
	I defaulted this to off since many users want to protect their
	privacy on this issue. Many channel operators consider age/sex
	queries to be offensive/annoying and you could get kicked.

Default: OFF

Away...Automatic Away

	If you'd like ]-[ydrobomb to automatically set you away after 10
	minutes of idleness, set this feature to on.

Default: ON

Away...Pager

	This works with ]-[ydrobomb's away feature (see below) and allows
	users to get your attention while you're away. It announces that
	a user is paging you and plays PAGE.WAV, a file that came with
	]-[ydrobomb. If you want to, you can create your own custom file
	to be played when you're paged. Simply delete or rename PAGE.WAV
	and create a new one.

Default: ON

Away...Auto Announce Return

	This will send an announcement of your return to all channels
	that you're on whenever you un-away.

Default: OFF

Detectors

	IP Mismatch

		mIRC sometimes "misplaces" your IP address. When your IP is
		incorrect in mIRC's registers, none of the DCC functions
		work correctly. IP Mismatch checks your actual IP against
		the one mIRC believes you have. If they don't match, you
		can have it display a warning. You can also set it to
		display a notice if it has checked out the IPs and they
		are the same.

	Defaults:
	Warn on mismatch: ON
	Notify on match:  OFF

	Netsplit

		This script listens to server notices for signs of a
		netsplit. When one is detected, it flashes a message to you
		informing you of the split (or rejoin). Note that in all
		messages, the first server is the one that is or was on
		"your" side of the net. The second is the one that is
		split off.

	Default: ON

	Perv Detect
	
		This is possibly the most complex feature in ]-[ydrobomb. When a
		user joins a channel, ]-[ydrobomb does a /whois in the background
		on that person. When the results come in, they are analyzed to
		see if they meet certain criteria. If they do, a warning is
		displayed.
		When the warning shows up, you can press F5 to notice all the ops
		on a channel. If you have ops yourself, you can press F6 to kick,
		F7 to temporarily ban, and F8 to ban indefinitely. You have 15
		seconds from the time the warning displays to make up your mind;	
		after that time the buffer is reset. You can still kick/ban the
		user manually.
		A disclaimer: this is NOT an indication that I support Internet
		censorship. I provided this feature as a means for users of clean
		channels to keep out objectionable users. If you feel that Perv
		Detect infringes on users' rights, TURN IT OFF, don't email me
		with your complaint.

	Default: ON

	Show channels

		This sub-script of Perv Detect shows the channels that a user
		is in wether they meet the criteria or not.

	Default: ON
	Perv Detect must be ON for this to work.

	On Join Recognize
	
		]-[ydrobomb's Recognize feature keeps a list of users@host matched
		with nicks. It's handy to keep track of your friends that like to
		switch nicks a lot, and also to see when someone is impersonating
		someone by taking their nick.
		This feature, when on, causes every user's address to be checked
		against the database. If they're in the database, ]-[ydrobomb
		indicates either their normal nick or that they are using their
		usual nick.
		To manage the database, see the Nicks List menu.

	Default: ON

	On Join Clone Detect

		]-[ydrobomb can check a user's address against that of other people
		already in the channel to see if they are a "clone," or someone
		that has launched a second IRC client on the same computer and
		is in control of both. If a clone is detected, ]-[ydro displays
		a warning.
		This can tend to take up large amounts of processor time when
		you're in a large channel with a lot of joins. To combat this,
		I've deactivated this in channels with more than 70 users.

	Default: ON

Speech

	If you have monolog or Text Assist, this feature can be activated.
	When on, ]-[ydro will vocally inform you of Perv Detect and On Join
	Clone warnings and when you're paged. It also says "]-[ydrobomb 2.0
	initialized" on startup.

Default: OFF

-----------------------------Nick List Popup-------------------------------

Control...TempBan

	This feature allows you to kick and ban a user, but automatically
	unban them after a specified amount of time. This is useful to
	prevent people who have set the "auto rejoin on kick" option to on.
	If you ban someone and leave before they are automatically unbanned,
	they will be banned indefinitely. Keep this in mind.

Control...TopPro

	Used to manage the Topic Protection settings for this channel.
	You can protect the current topic, change the topic and protect
	the new one, or remove protection altogether.

Control...Filterkicks

	Controls filter kicks. "Kick all clones" kicks the selected user
	and, if applicable, any clones that are in the same channel.
	"Kick all with same ISP" kicks everyone in the channel that has
	the same second-level domain. Useful for removing an influx of
	AOLamers :)

CTCP...Room Ping

	This pings every user in the room. You can also do this by pressing
	F2.

CTCP...Stealth Ping

	This pings every user in the room as well, but in a way so that
	room CTCP detectors are not tripped.

CTCP...Fake CTCP Reply

	Sends a CTCP reply without being prompted. mIRC version 4.7 and
	over ignores CTCP PING replies that are not numerical.

CTCP...Other

	Allows you to input another CTCP command.

Clone Detect

	Checks the room for clones. This feature is not available in rooms
	larger than 70 users.

Channel Stats

	Does a /who on the channel, then displays statistics about that
	channel.

Recognize...On

	Turns the Recognize feature ON for this nick. If they do not change
	their ISP or userid, they will be in the Recognize database as
	this nick.
	This can also be used to change the recognized nick of someone
	that is already in the database.

Recognize...Check

	Scans the Recognize database for a user matching this nick's
	address.

Messaging...Behind the Back

	One of the first original scripts I ever made, this feature sends
	a /notice to all users in the channel EXCEPT THIS NICK.
	This is also accessible from the /behind command, syntax:
	/behind [nick] [message text]
	Note to ]-[ydrobomb beta users: this was a very buggy command,
	often sending messages to the behinded nick. I have completely
	fixed the command with this release and you can use it with
	confidence. I hope. :)

Messaging...to all Ops

	Also accessible from the /opnot command, this sends a /notice
	to every op on the channel, wether you have ops or not.

Messaging...to all Non-Ops

	This is the exact reverse of the /opnot command. It sends a
	/notice to all users who DO NOT have ops on the channel.
	You can use this command from the command line by typing:
	/noop [message]

Messaging...selected nicks

	This sends a notice to every user whose nick is highlighted.

Messaging...backwards

	.esrever ni lennahc eht ot egassem a sdnes sihT
	(This sends a message to the channel in reverse.)

Waves/MIDIs...get WAV file

	Uses the standard WAV playing standard of !nick filename.wav
	to ask for a wavefile. Also un-ignores the person. This is
	important because if CTCP protect is on and the user played the
	file in the past 30 seconds, ]-[ydrobomb will ignore their DCC
	SEND command.

Waves/MIDIs...play to Channel

	Allows you to select a wavefile or MIDI file to play to the channel.
	Important note: if you're going to use this feature, you should
	have Autosend on !nick on so users can receive your wavefile if they
	don't already have it.

Waves/MIDIs...play to Self

	Pulls up the same dialog box, but you will be the only one to hear
	the file.

Waves/MIDIs...play to Person

	Same dialog box. This time, the only person to hear the wave
	is the selected nick (assuming they have the wav).

Waves/MIDIs...Delete wavefile

	Allows you to /remove one of your wavefiles.

----------------------------Query/DCC Chat popups---------------------------

Direct Ping

	For Win95 users only - accesses the ping.exe program and sends
	an ICMP ping directly to the user's address. A separate window
	will pop up and allow you to see the ping times, which should
	be in the range of about 300-600 milliseconds.
	IMPORTANT NOTE: The ICMP pings sent by this ping are NOT massive
	enough to be used for flooding. This feature can't be used
	to flood users off. If you want a flood script, find it somewhere
	else.

Trace Route

	Again for Win95 users, this accesses another Win95 utility
	which shows the path by which TCP/IP packets travel from you
	to the selected nick.

All options in CTCP, DCC, Recognize, and Waves/MIDIs are the same as in the
Nick List popup, except for obvious reasons there is no "play to channel"
option under Waves/MIDIs.

----------------------------Status Window popup-----------------------------

The only thing you'll find different here is the Faked Quits menu at the
bottom, which allows you to simulate several different types of accidental
disconnects. The last one, SERVER OP, simulates your falling for an old
newbie trick: telling a user to type /raw server op and see what happens.
If you type this, you're disconnected with the message "Need more
parameters."

--------------------------------Aliases-------------------------------------

/autoexec	Automatic alias which sets some vital timers, variables,
		etc. You should have this alias in your Perform section.

/idlecheck	Automatic alias, checks your idle time to determine
		wether you should be set away.

/top		Sets the topic in the current channel. If you use this
		with no parameters, the topic is set to blank.

/opnot		Sends a notice to all ops on the channel.

/noop		Sends a notice to all non-ops on the channel.

/behind		Use: /behind [nick] [message]
		Sends a notice to all users on the channel except the
		indicated nick.

/fakectcp	Sends a false CTCP reply to a user.

/pcheck		Automatic alias, part of Perv Detect. Do not activate
		this alias manually.

/about		Displays a screen-long information list about ]-[ydrobomb.

/recadd		Same as Recognize...On, adds a user to the recognize list.

/rectake	Removes a user from the recognize list.

/recognize	Checks a user's address against the recognize list.

/goaway		Sets you away with a message you specify. If used with no
		parameters, sets you un-away and announces it to all
		your channels.

/banlist	Checks the banlist for the current channel. You can specify
		a channel, but many IRC networks do not allow users outside
		the channel to see ban lists. A major exception is DALnet.

/clone		Scans for clones in the current channel.

/clonedet	With this, you may specify a channel and that channel will
		be scanned for clones. You must be in the specified channel
		to use this alias.

/onjoinclone	Automatic alias, scans for clones when a user joins the
		channel.

/hydro		Announces to the current channel that you are using
		]-[ydrobomb. Use this often :)

/dping		Uses a Win95 utility to directly ping a user.

/tracert	Uses another Win95 utility to trace the route to a user.

/srvping	Sends a direct ICMP ping to your server. The same general
		result can be accomplished by typing /raw ping [yournick].

/sload		]-[ydrobomb's addon support alias. This alias follows the
		addon standards proposed by [x|x] and webba.

/portscan	Scans a server's TCP ports to find the one with the least
		traffic. Thanks to LoKi128 for the concept on this one.

/rev		Speaks what you specify backwards.

/accping	Sends an Accurate Ping to a user.  Accurate Pings use a
		different method to process and give a ping reply to
		the millisecond.  This alias is called by all ping methods
		except /ctcp nick PING, which sends a normal ping.

/accpingread	Used to interpret the results of an Accurate Ping.
		Automatic.

/titlebarupdate	Automatic alias, updates the titlebar with the latest
		information. The Titlebar feature is new to ]-[ydro 2.0.
		It shows your current server lag (to the millisecond),
		your idle time, and the time.
		A note about the titlebar: If you quit mIRC while still
		connected to the server, when you start it back again
		the titlebar will read what it was reading when you quit.

$stdtime	Returns the current time in AM/PM format. Used by the
(custom		titlebar and some other features.
identifier)

/inititbar	Automatic alias, initializes the titlebar update routine.

/onlinecheck	Automatic alias, checks to see if you've been disconnected.
		If so, updates the titlebar to show that.

/chanstat	Usage: /chanstat [channel] Channel Statistics for a
		particular channel. Returns total number of channel users,
		number of ops, non-ops, number of away, and percentage
		breakdowns for each. Also returns the "Average number of
		hops," a number that indicates the average server-to-server
		hop distance from you. A user on your server is 0 hops away,
		someone on a server connected to your server is 1 hop away,
		someone on a server connected to that server is 2 hops away,
		etc. etc. etc.

/stat		Returns channel statistics for the current channel.

/fkick		Usage: /fkick [nick] [mask number]
		Kicks all users whose addresses match the mask you specify.
		Useful mask numbers:
		2 - kicks all clones
		4 - kicks all with same ISP

$percent	Custom identifier. Usage: $percent(x,y)
		Returns what percent of y x is.
		For instance, $percent(50,100) returns 50.

/rwhois		Performs a Remote Whois on the specified nick.
		Remote whois works in a 2 step process:
		1. Perform a local /whois to find their server
		2. Perform a /whois on the remote server.

$ticsec		Custom identifier. Divides the specified number by 1000
		and returns a decimal result. Useful for converting
		processor ticks to seconds.

/toppro		Topic Protect alias.
		Usage:
		/toppro (no parameters) - protects current topic
		/toppro [topic] - changes topic, protects new topic
		/toppro off - turns Topic Protect off for current channel.

-------------------------------Function Keys--------------------------------

------
| F1 |		Left as-is, brings up help.
------

------
| F2 |		Sends a ping to the channel.
------

---------   ------
| SHIFT | + | F2 |	Sends a ping to the channel in such a way that
---------   ------      channel CTCP detectors are not tripped.

------
| F3 |		Emergency remote off - use this if a user is maliciously
------		taking advantage of your automatic functions.

------
| F4 |		Turns the remote back on.
------

------
| F5 |		Notices the ops about a perv in the channel.
------

------
| F6 |		Kicks a perv.
------

------
| F7 |		Kicks and temporarily bans a perv.
------

------
| F8 |		Kicks and bans a perv.
------

------
| F9 |		Scans for clones in the current channel.
------

-------		The "mommy button." When parental authority is present,
| F10 |		you can push this button and the buffer will be cleared.
-------		It will look like you've just joined a channel.

-------
| F11 |		Runs a PortScan.
-------

-------
| F12 |		Moves to the port that the PortScan has determined
-------		is the best.

===========================================================================

ABOUT

=========================
| ]-[ydrobomb
| a script for mIRC 4.7
|---------------------
| Current Version: 2.0
|---------------------
|  Einstein, 1996
| <sdl@iamerica.net>
| Find the latest news about ]-[ydro @ http://cust2.iamerica.net/sdl/hydro
=========================
----License----
You may distribute ]-[ydrobomb to anyone, on any terms you wish. It's
"freeware." My only requirement is that you don't modify, change, "fix,"
etc.etc.etc., the original ZIP file. If you discover a bug, please don't
try to correct it and then distribute your changes. Once you unzip it, you
can change whatever you want, but don't pass out the modified version.
Also, do not disable the VERSION reply.

NOTE TO mIRC SCRIPT PAGE OWNERS: If you put ]-[ydrobomb on your site,
please e-mail me about it and I'll put a link to your page.

Send all bug reports, suggestions, complaints, requests, and flames to the
email address above.

============================================================================
My feelings on script ripping:

The odd thing about script ripping is that it is both the most eloquent
compliment a scripter can receive. It shows that the ripper, although
misguided, truly respects the scripting work he or she is copying.
That's why I permit it, IF you ask. I will give, and have given, permission
to use parts of my script in other people's projects. Just send me an
e-mail or find me on the Undernet and ask me. Tell me what part of the
script you wish to copy, what it will be used for, and what alterations
you'll make to it, if any. I'll be happy to let you use it.

============================================================================
Happy chatting,
Einstein