mIRC Homepage
Posted By: Bullseye play text - 07/11/05 06:11 AM
Hi
I have this bot witch on command .help plays some text from a file.
The problem is it show the text like this:

.command1 .command2 .command3
.command4 .command5 .command6

It doesn't show the spaces or the text I want bold.
I wanted 10 spaces in between the commands.
Please help

Greetzzz
Posted By: SladeKraven Re: play text - 07/11/05 06:22 AM
Code:
On *:Text:.help:?: {
  play $nick cmd.txt 1000
}


//write cmd.txt .Command1 $str($chr(160),5) .Command2 $str($chr(160),5) .Command3

But $chr(160) isn't preferred as it wont work on all fonts.

-Andy
Posted By: nycdiesel Re: play text - 07/11/05 06:25 AM
Well I can't promise the spacing display output on whom evers side issues the command, .help. The way the spacing will appear on the users side, is all up to what font they are using. Anyways, try this code:


Code:
msg # $replace(<TEXT>,$chr(32),$str($chr(160),10))


The $chr(160) will appear on any users side who are using Fixedsys font (probably more) as a space. I use terminal, therefore it'll display as รก.
Posted By: Riamus2 Re: play text - 07/11/05 02:22 PM
Personally, I prefer using Ctrl-B $+ $chr(32) $+ Ctrl-B to replace $chr(32). This works on all fonts. $chr(160) does not.
Posted By: MikeChat Re: play text - 07/11/05 04:37 PM
If you are playing a plain text file there is no need to reformat spaces
/play filename speed

if you have put a /command that you want to trigger on each line
such as /say using /play -c
/say .command .command2 .command3

then mIRC will truncate the spaces, but from what you have shown you should be able to use /play with no modifier (like -c)
© mIRC Discussion Forums