|
Joined: Jul 2003
Posts: 14
Pikka bird
|
OP
Pikka bird
Joined: Jul 2003
Posts: 14 |
help me on this please? anyone? when a user typed a long text, i doesnt seems to wrap it but instead cut off.
on ^*:TEXT:*:#:{
var %a = 1,%b $wrap($1-,ProFontWindows,9,$calc($window($active).dw - 10),0)
echo -mlbfri $chan $times(EVENT) $nick($chan,$nick).pnick says: $wrap($1-,ProFontWindows,9,$calc($window($active).dw - 10),1)
while (2 <= $wrap($1-,ProFontWindows,9,$calc($window($active).dw - 10),0)) {
echo -mlbfri $chan $times(EVENT) $nick($chan,$nick).pnick says: $wrap($1-,ProFontWindows,9,$calc($window($active).dw - 10),%a)
inc %a
}
haltdef
}
Best regards, Ken
|
|
|
|
Joined: Sep 2003
Posts: 4,230
Hoopy frood
|
Hoopy frood
Joined: Sep 2003
Posts: 4,230 |
you sure that doesnt lock your mirc up altogether? I dont see an exit to the while loop, i think it should be looking like this...
on ^*:TEXT:*:#:{
var %a = 1
var %b = $wrap($1-,ProFontWindows,9,$calc($window($active).dw - 10),0)
while (%a <= %b) {
echo -mlbfri $chan $times(EVENT) $nick($chan,$nick).pnick says: $wrap($1-,ProFontWindows,9,$calc($window($active).dw - 10),%a)
inc %a
}
haltdef
}
|
|
|
|
Joined: Jan 2003
Posts: 1,063
Hoopy frood
|
Hoopy frood
Joined: Jan 2003
Posts: 1,063 |
I see you using echo -i
when wrapping text you need to add an N to that: echo -iN
for example: echo -i3
If it ain't broken, don't fix it!
|
|
|
|
Joined: Sep 2003
Posts: 4,230
Hoopy frood
|
Hoopy frood
Joined: Sep 2003
Posts: 4,230 |
-i is all u need, there is no need to have a value following it, it defaults to 2
|
|
|
|
Joined: Jul 2003
Posts: 14
Pikka bird
|
OP
Pikka bird
Joined: Jul 2003
Posts: 14 |
ok lets make this clear, echo -i[N] only allow to 25. I want my effect to be align like this below:
09:05a regatria says: I want my long text to be wrap to the
: next line like this. ok lets make this
: clear, echo -i[N] only allow to 25.
: I want my effect to be align like this
09:06a : below:
Best regards, Ken
|
|
|
|
Joined: Jul 2003
Posts: 14
Pikka bird
|
OP
Pikka bird
Joined: Jul 2003
Posts: 14 |
erm,
on ^*:TEXT:*:#:{
var %a = 2
var %b = $wrap($1-,ProFontWindows,9,$calc($window($active).dw),0)
echo -mlbfr $chan $times(EVENT) $nick($chan,$nick).pnick says: $wrap($1-,ProFontWindows,9,$calc($window($active).dw),1)
while (%a <= %b) {
echo -mlbfr $chan $times(EVENT) $str($chr(160),$calc($len($nick($chan,$nick).pnick) +4)) : $wrap($1-,ProFontWindows,9,$calc($window($active).dw),%a)
inc %a
}
haltdef
}
this works. but when i paste my codes which is also. it doesnt wrap anymore.. any ideas?
Best regards, Ken
|
|
|
|
Joined: Jul 2003
Posts: 14
Pikka bird
|
OP
Pikka bird
Joined: Jul 2003
Posts: 14 |
Best regards, Ken
|
|
|
|
|