IRC Scripting Basics: Part 1
By Richard “GameGuru” Grant
Aliases
mIRC scripting works on the basis of 5 areas. The first being Aliases, which are explained in this Tutorial, Popups, Remote, Users and Variables.
Aliases form a very simple part of scripting. Aliases, are used primarily as a shortcut to performing long or tedious commands, or as a way of performing multiple commands in one go. Loading your aliases file in mIRC (Tools -> Scripts Editor on the Toolbar or pressing Alt + R, and then going to the Aliases tab) You will find some aliases already created for you.
/op /mode # +ooo $$1 $2 $3
Many of you who frequently use mIRC will be aware of the Operator status and giving it to other people. Many of you will use /op <nickname> to give ops to people. However, this would not work if you did not have /op defined as an alias. The standard protocol for IRC is to use /mode # (thats is the current active channel window) +o (give the user ops) $$1 (this is an identifier meaning the first parameter you specify, and is required in order for the alias to work) $2 $3 (these are also identifiers refering to parameter 2 and 3, however are optional parameters.) To create any alias, you must first declare the alias (in the above example it was /op) then you must declare the commands associated with that alias. If you want to create an action alias that automatically allows you to slap someone with a specified object then you could create an alias like this:
/slap /me slaps $$1 with a $$2
This would mean when you type “/slap Paul spade” you would actually do “/me slaps Paul with a spade”
This concludes part 1 of the scripting basics. Part two will explain how to create Popups and use them in the same way as Aliases.
As a way of practice try creating an alias that allows you to ban and then kick a user. You will need to use /mode +b and /kick in your alias, as well as { } to encase the alias commands.