Just a simple snippet that reverses the text, and then outputs it.
The command:
/rev This is some example text.
Outputs this text:
.txet elpmaxe emos si sihT
alias rev {
var %i = 1
while (%i <= $len($1-)) {
set -u0 %bwOut $mid($1-,%i,1) $+ %bwOut
inc %i
}
msg $chan %bwOut
}
mountaindew: Good call! Another suggestion I would make is to turn this into an identifier that returns the statement within any fashion, not just a message to a channel. ie: $rev(). Here is an example:
alias rev {
var %i = 1, %bwOut
while (%i <= $len($1-)) {
%bwOut = $mid($1-,%i,1) $+ %bwOut
inc %i
}
return %bwOut
}