mIRC Home    About    Download    Register    News    Help

Print Thread
Alligned theme #84508 29/05/04 12:54 PM
Joined: Mar 2003
Posts: 160
Marantz Offline OP
Vogon poet
OP Offline
Vogon poet
Joined: Mar 2003
Posts: 160
Ok, been a while but i decided to start scripting again.
Problem i have..

on text and on input
i want the allignment to look like this

[@/Marantz ] hi
[./Marantz ] hi
[+/Marantz ] hi
[!/Marantz ] hi
[~/Marantz ] hi
[&/Marantz ] hi
[%/Marantz ] hi

obviously that's not straight lol
with a maximum nick length of 10 chars
and for it to stay alligned if a user has more than 1 mode prefix and to cover all possible mode prefixes
ie; + and @ or + and .
and for when a user has no modes at all
i just can't remember how to do anything anymore

thanks in advance if anyone can help.

Re: Alligned theme #84509 29/05/04 01:01 PM
Joined: Nov 2003
Posts: 2,327
tidy_trax Offline
Hoopy frood
Hoopy frood
Joined: Nov 2003
Posts: 2,327
alias align {
 var %str = $str($chr(160),$calc($2 - $len($3)))
 echo $1 %str $3-

/align window alignment text

//align -s 30 part: $me

-s - where to echo to (could be $chan, $nick, etc)

30 - how many spaces to align the theme by, in the above example, there will be 25 spaces because the length of part: (5) is deducted from 30

part: $me whatever you want to echo.

New username: hixxy