mIRC Home    About    Download    Register    News    Help

Print Thread
#217287 07/01/10 08:35 AM
Joined: Nov 2007
Posts: 117
T
Vogon poet
OP Offline
Vogon poet
T
Joined: Nov 2007
Posts: 117
on 1:input:*: {
if ($left($1-,1) != /) { say 4,0$+| $+ $1-  | halt }
}

i want erase the space between ,any idea , thnx so much

TheWarlock #217288 07/01/10 09:10 AM
Joined: Jun 2007
Posts: 933
5
Hoopy frood
Offline
Hoopy frood
5
Joined: Jun 2007
Posts: 933
Code:
on 1:INPUT:*:if ($left($1,1) != /) && (!$ctrlenter) { say 4,0 $+ $1- $+  | halt }

Like that?

TheWarlock #217291 07/01/10 09:34 AM
Joined: Jan 2007
Posts: 1,156
D
Hoopy frood
Offline
Hoopy frood
D
Joined: Jan 2007
Posts: 1,156
space between what?

DJ_Sol #217294 07/01/10 01:52 PM
Joined: Oct 2004
Posts: 8,330
Hoopy frood
Offline
Hoopy frood
Joined: Oct 2004
Posts: 8,330
Looks like he was getting a space before the | he was inserting because he didn't put a space between the color code and the $+ as shown in the first reply.


Invision Support
#Invision on irc.irchighway.net
DJ_Sol #217299 07/01/10 06:41 PM
Joined: Nov 2007
Posts: 117
T
Vogon poet
OP Offline
Vogon poet
T
Joined: Nov 2007
Posts: 117
<Daniel> Avatar esta buena tu peli
this space between > and avatar i want take it

thnx

TheWarlock #217300 07/01/10 07:09 PM
Joined: Jul 2007
Posts: 1,129
T
Hoopy frood
Offline
Hoopy frood
T
Joined: Jul 2007
Posts: 1,129
If you mean you want a space between < yournick > then you can do this:
Code:
on *:INPUT:#: {
  if ($left($1,1) != /) && (!$ctrlenter) {
    echo -t # $+(<,$chr(32),$nick(#,$me).pnick,$chr(32),>) 4,0 $+ $1-
    .msg # $1- | halt
  }
}

Tomao #217301 07/01/10 08:53 PM
Joined: Oct 2004
Posts: 8,330
Hoopy frood
Offline
Hoopy frood
Joined: Oct 2004
Posts: 8,330
No, he wants:

<nick> hello

to be:

<nick>hello


Invision Support
#Invision on irc.irchighway.net
Riamus2 #217303 07/01/10 09:52 PM
Joined: Jul 2007
Posts: 1,129
T
Hoopy frood
Offline
Hoopy frood
T
Joined: Jul 2007
Posts: 1,129
Ok I suppose that's an easy fix:
Code:
on *:INPUT:#: {
  if ($left($1,1) != /) && (!$ctrlenter) {
    echo -t # $+(<,$nick(#,$me).pnick,>,$(4,0),$1-)
    .msg # $1- | halt
  }
}

Riamus2 #217304 07/01/10 09:57 PM
Joined: Jan 2007
Posts: 1,156
D
Hoopy frood
Offline
Hoopy frood
D
Joined: Jan 2007
Posts: 1,156
Tomao you cannot put the font code inside $+() because it thinks the , is a delimiting token. Either replace the comma with $chr(44) or do it the other way.

Code:
echo -i7t # $+(<,$chr(160),$nick(#,$me).pnick,$chr(160),>) $+ 4,0 $+ $1-
    .msg # $1-
haltdef

DJ_Sol #217306 07/01/10 10:20 PM
Joined: Jul 2007
Posts: 1,129
T
Hoopy frood
Offline
Hoopy frood
T
Joined: Jul 2007
Posts: 1,129
My bad. This is it:
Code:
on *:INPUT:#: {
  if ($left($1,1) != /) && (!$ctrlenter) {
    echo -t # $+(<,$nick(#,$me).pnick,>) $+ 4,0 $+ $1-
    .msg # $1- | halt
  }
}

DJ_Sol #217307 07/01/10 10:25 PM
Joined: Jul 2007
Posts: 1,129
T
Hoopy frood
Offline
Hoopy frood
T
Joined: Jul 2007
Posts: 1,129
Question, why $chr(160)?

DJ_Sol #217309 08/01/10 12:10 AM
Joined: Oct 2003
Posts: 3,918
A
Hoopy frood
Offline
Hoopy frood
A
Joined: Oct 2003
Posts: 3,918
Seriously? If you want a space, just don't use $+.

Code:
< $nick(#,$me).pnick >


- argv[0] on EFnet #mIRC
- "Life is a pointer to an integer without a cast"
Tomao #217319 08/01/10 07:08 AM
Joined: Jan 2007
Posts: 1,156
D
Hoopy frood
Offline
Hoopy frood
D
Joined: Jan 2007
Posts: 1,156
Because he had $chr(32) and in my experience $chr(32) doesn't give you a blank space in an echo.

DJ_Sol #217328 08/01/10 01:23 PM
Joined: Oct 2004
Posts: 8,330
Hoopy frood
Offline
Hoopy frood
Joined: Oct 2004
Posts: 8,330
$chr(32) *does* give a blank space... but only 1 in a row. $chr(160) lets you do multiple spaces in a row, but not all fonts show it as a space, so it's not necessarily a good method to you if you're distributing the script.

argv0, the OP wasn't trying to add spaces, but to remove one.


Invision Support
#Invision on irc.irchighway.net
Riamus2 #217329 08/01/10 01:58 PM
Joined: Jan 2007
Posts: 1,156
D
Hoopy frood
Offline
Hoopy frood
D
Joined: Jan 2007
Posts: 1,156
nah I got boxes from $chr(32). You know the ones you get when your font doesn't support a character. Maybe it works better now. I noticed Vista handles fonts a lot better than windows ever has.

DJ_Sol #217330 08/01/10 03:11 PM
Joined: Nov 2009
Posts: 117
Vogon poet
Offline
Vogon poet
Joined: Nov 2009
Posts: 117
How can any font not support $chr(32) ?
If you need more than one space you can like
cheat by adding double bolds inbetween.
Usually when I need a space as example:
$replace($duration(600),min,$chr(32) minute))
Note: No need for a $+ between $chr and minute.

DJ_Sol #217359 09/01/10 05:41 AM
Joined: Jul 2008
Posts: 236
S
Fjord artisan
Offline
Fjord artisan
S
Joined: Jul 2008
Posts: 236
boxes from $chr(32)? highly unlikely. that's ascii for space... maybe you're emulating mIRC on a box that uses ebcid? in that case, expect everything to be weird wink


Link Copied to Clipboard